Skip to content
Commit 8a6a4ea6 authored by Peter Mühlenpfordt's avatar Peter Mühlenpfordt
Browse files

Fix issues with clicking directories in tree view

Summary:
Selecting another directory in tree while showing an image in view mode,
opens the first image from the selected directory in view mode. If the
folder contains subfolders, gwenview selects the first one and switches
to browse mode.
This patch changes selection of first **item** back to first **image**
(introduced in D8934) to fix this and toggles between browse/view mode
only after clicking the already selected directory in tree.
Additionally a trailing slash is stripped from the current dir url in
context manager to fix a failing compare to initially stored dir url.

BUG: 306835

Test Plan:
1. Open image in view mode
2. Click on another directory in tree view
-> Should view the first image in new directory

1. Open image in view mode
2. Click multiple times on the same directory in tree view
-> Should toggle browse/view mode

Reviewers: rkflx

Reviewed By: rkflx

Subscribers: ngraham, rkflx

Differential Revision: https://phabricator.kde.org/D9886
parent 5bcb8cc9
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment