Clean up hamburger menu and viewport and single-folder context menus
ClosedPublic

Authored by ngraham on Fri, Sep 6, 4:10 PM.

Details

Summary

Dolphin's hamburger and context menus have grown organically over time,
becoming a bit messy and somewhat visually overwhelming. This makes them
harder to parse and more intimidating to use.

This patch cleans up the hamburger menu and viewport and single-folder context
menus to group items more logically, and remove items that aren't actually relevant
to the context.

The hamburger menu part of the patch is fairly significant, and draws from the
principle of only showing actions with a global scope that are not already accessible
from another visible method (e.g. via the default toolbar). In the end, it manages to be
shorter than the current hamburger menu with expose actions that are more relevant.

A visible method to display context-specific actions should be explored separately
(see https://bugs.kde.org/show_bug.cgi?id=411500).

Depends on D23945

Test Plan

Before, hamburger menu:


After, hamburger menu:

Before, viewport:


After, viewport:

Before, one folder selected:


After, one folder selected:

No change for the context menus shown when selecting a single item, multiple items, or multiple folders

Diff Detail

Repository
R318 Dolphin
Lint
Automatic diff as part of commit; lint not applicable.
Unit
Automatic diff as part of commit; unit tests not applicable.
There are a very large number of changes, so older changes are hidden. Show Older Changes
ngraham planned changes to this revision.Mon, Sep 9, 4:59 PM
  • A user may wish to duplicate the current view in a new tab or window

Oh jeez, now I see that these features are not available in the hamburger menu. Sigh. Will fix that too.

  • A user may wish to create a file inside of a folder while at the level of a higher folder in tree/details view. In case that's hard to visualize:

Yeah, I guess you're right. I'll add it back.

ngraham updated this revision to Diff 65694.Mon, Sep 9, 5:18 PM

Re-add "Create New" to single-item context menu, and add "New Tab" and "New Window" actions to hamburger menu

This revision is now accepted and ready to land.Mon, Sep 9, 5:18 PM
ngraham retitled this revision from Clean up viewport and single-folder context menus to Clean up viewport and single-folder context menus and hamburger menu.Mon, Sep 9, 5:20 PM
ngraham edited the summary of this revision. (Show Details)
ngraham edited the test plan for this revision. (Show Details)
ndavis added a comment.Mon, Sep 9, 5:33 PM

Why is it that sometimes Create New is in its own section and sometimes it's grouped with Open With or New Tab/Window?

As for Add to Places, perhaps it should just be in its own section above the services section? It doesn't really go with anything else and I was never bothered by it being in its own section.

Why is it that sometimes Create New is in its own section and sometimes it's grouped with Open With or New Tab/Window?

As for Add to Places, perhaps it should just be in its own section above the services section? It doesn't really go with anything else and I was never bothered by it being in its own section.

One of the reasons why I wanted to do this patch is because I think single-item sections are ugly and make the menu feel cramped and overwhelming, and the goal was to get rid of them as much as possible.

ndavis added a comment.Mon, Sep 9, 7:21 PM

Why is it that sometimes Create New is in its own section and sometimes it's grouped with Open With or New Tab/Window?

As for Add to Places, perhaps it should just be in its own section above the services section? It doesn't really go with anything else and I was never bothered by it being in its own section.

One of the reasons why I wanted to do this patch is because I think single-item sections are ugly and make the menu feel cramped and overwhelming, and the goal was to get rid of them as much as possible.

Regardless of the location or what it's grouped with, it needs to be consistent in both ways. It almost doesn't even matter exactly where it is or what its grouped with as long as it doesn't change places for no discernible reason.

How about grouping Open With, Create New and Add to Places? Open in New Tab and Open in New Window can be in their own section.

While I agree that New Tab/New Window shouldn't be reachable only from the context menu, I'm a bit worried about the height of the control menu. With this patch applied, it is taking almost all the available height on my 1366x768 laptop screen.

Is there maybe some action that we could remove from the control menu? Maybe "Redisplay" ?

While I agree that New Tab/New Window shouldn't be reachable only from the context menu, I'm a bit worried about the height of the control menu. With this patch applied, it is taking almost all the available height on my 1366x768 laptop screen.

Is there maybe some action that we could remove from the control menu? Maybe "Redisplay" ?

I agree with you and I'm all ears regarding things we could remove. Redisplay is definitely a prime candidate IMO.

I noticed recently in the ElementaryOS file manager that the refresh button is integrated into the URL navigator, on the right side. I wonder if we could do that too. That would make it still reachable (more so, in fact) despite not being in the default toolbar or the hamburger menu.

ndavis added a comment.EditedTue, Sep 10, 12:24 AM

Why not just keep New Tab/Window in the Context menu? The hamburger is already a bit overfull, even if we remove Redisplay. The context menu isn't that long by comparison and it wouldn't be any longer than it is with a folder selected.

Why not just keep New Tab/Window in the Context menu? The hamburger is already a bit overfull, even if we remove Redisplay. The context menu isn't that long by comparison and it wouldn't be any longer than it is with a folder selected.

It's a HIG violation to have functionality available only via invisible UI (context menu and keyboard shortcuts), which is the case for the New Tab and New Window actions when the menubar isn't shown.

https://hig.kde.org/components/navigation/contextmenu.html#is-this-the-right-control

Fair enough.

elvisangelaccio added a comment.EditedTue, Sep 10, 10:03 AM

And btw D22444 is going to add yet another action in the menu :D

While I agree that New Tab/New Window shouldn't be reachable only from the context menu, I'm a bit worried about the height of the control menu. With this patch applied, it is taking almost all the available height on my 1366x768 laptop screen.

Is there maybe some action that we could remove from the control menu? Maybe "Redisplay" ?

I agree with you and I'm all ears regarding things we could remove. Redisplay is definitely a prime candidate IMO.

I noticed recently in the ElementaryOS file manager that the refresh button is integrated into the URL navigator, on the right side. I wonder if we could do that too. That would make it still reachable (more so, in fact) despite not being in the default toolbar or the hamburger menu.

Yeah. Also "Redisplay" only makes sense on remote URLs or systems where we can't rely on inotify.

ngraham planned changes to this revision.Wed, Sep 11, 4:12 PM

Will clean up the hamburger menu too and turn this into a more general "clean up menus" patch.

ngraham updated this revision to Diff 65858.Wed, Sep 11, 4:32 PM

Mostly update the hamburger menu

This revision is now accepted and ready to land.Wed, Sep 11, 4:32 PM
ngraham retitled this revision from Clean up viewport and single-folder context menus and hamburger menu to Clean up hamburger menu and viewport and single-folder context menus.Wed, Sep 11, 4:38 PM
ngraham edited the summary of this revision. (Show Details)
ngraham edited the test plan for this revision. (Show Details)

Please rebase, thanks!

ngraham updated this revision to Diff 66014.Fri, Sep 13, 9:06 PM

Bump dolphinui.rc version again

What about removing the "select all" & "invert selection" from the hamburger menu?
Advanced users may know the shortcuts already and normal users maybe would not have to work with such big amounts of files that they could not do it manually?

GB_2 added a subscriber: GB_2.Sat, Sep 14, 7:49 AM

What about removing the "select all" & "invert selection" from the hamburger menu?
Advanced users may know the shortcuts already and normal users maybe would not have to work with such big amounts of files that they could not do it manually?

If it is not visible in another menu (it is not) we'll need to keep it so it is discoverable and people can learn it.

elvisangelaccio requested changes to this revision.Sat, Sep 14, 1:45 PM
elvisangelaccio added inline comments.
src/dolphinui.rc
43 ↗(On Diff #66014)

Missing closing " character which makes dolphin crash on start.

This revision now requires changes to proceed.Sat, Sep 14, 1:45 PM
ngraham updated this revision to Diff 66046.Sat, Sep 14, 1:49 PM
  • Fix Error
  • Move "Show Panels" menu out of the view-specific section and into to the section with other global settings
ngraham edited the test plan for this revision. (Show Details)Sat, Sep 14, 1:51 PM
ngraham marked an inline comment as done.Sat, Sep 14, 1:54 PM

Could you please move the renaming of labels (e.g. "Hidden Files" to "Show Hidden Files") and the addition of icons to different commits? That would make this patch much easier to review.

src/dolphincontextmenu.cpp
227

Leftover?

src/dolphinmainwindow.cpp
1033

I'm not sure about this one, since it will be disabled most of the time. If you want to compare 2 files you have to select both of them and then you will probably use the right-click.

I'd actually keep the "Tools" menu, while I agree with the removal of the "Go" menu (since you can use most of its actions from the toolbar).

1044–1049

Hmm, I don't really see what we gain by shuffling "Help" and "Show Menubar" and removing the separator...

ngraham updated this revision to Diff 66052.Sat, Sep 14, 2:32 PM
ngraham marked an inline comment as done.

Don't show Compare Files

src/dolphinmainwindow.cpp
1033

My thinking was that it would make sense not to show yet another submenu, especially since it would become a single-item group, with separators above and below it, which looks a bit ugly. The Hamburger menu is already a "curated" assortment of items.

1044–1049

There's no logical grouping of "Help" and "Show Menubar", so I didn't think it made sense to put them in a section together.

Also, removing the separator generally alleviates the "separator overload" effect that currently contributes to the the menu being too tall and visually overwhelming.

ngraham marked 4 inline comments as done.Sat, Sep 14, 2:35 PM
ngraham updated this revision to Diff 66054.Sat, Sep 14, 2:43 PM

Revert icon and text changes (now done in a separate patch)

ngraham updated this revision to Diff 66056.Sat, Sep 14, 2:44 PM

Undo unintentional change

ngraham updated this revision to Diff 66057.Sat, Sep 14, 2:45 PM

Undo another unintentional change

ngraham edited the summary of this revision. (Show Details)Sat, Sep 14, 2:46 PM
ngraham edited the test plan for this revision. (Show Details)Sat, Sep 14, 2:56 PM
GB_2 added a comment.EditedSat, Sep 14, 3:51 PM

Would be nice if you could also made a KIO patch that changes the icon for "Open With" to system-run and the icon for "Actions" to view-more-symbolic.

GB_2 accepted this revision.Sat, Sep 14, 3:59 PM

Looks great!

src/dolphinmainwindow.cpp
1002

...and also 'Recently Closed Tabs'

Or just "Add tabs-related entries"

Or just remove the comment :-)

1024

Why remove sort?

1044–1049

Fair enough :)

1057

Ah, I didn't think about Bookmarks. I guess it can go...

ngraham added inline comments.Sat, Sep 14, 4:32 PM
src/dolphinmainwindow.cpp
1024

Same reason to remove the view mode chooser: Because it's in the default toolbar and the viewport context menu.

1057

Yeah I think its overkill for the simplified UI presentation in the hamburger menu.

ngraham updated this revision to Diff 66082.Sat, Sep 14, 7:16 PM
ngraham marked 5 inline comments as done.

Remove uninformative, self-evident comments

elvisangelaccio accepted this revision.Sun, Sep 15, 10:10 AM
This revision is now accepted and ready to land.Sun, Sep 15, 10:10 AM
This revision was automatically updated to reflect the committed changes.
In D23757#531196, @GB_2 wrote:

Would be nice if you could also made a KIO patch that changes the icon for "Open With" to system-run and the icon for "Actions" to view-more-symbolic.

Your wish is my command: D23972: Add icons for "Open With" and "Actions" menus