Dolphin 'Find' button behavior
Closed, ResolvedPublic

Description

A feature request, from Bug 353227 - Make Dolphin's Find... button into a toggle, so it mimics the state of the search bar.

Once I sorted through the KToggleAction stuff, it was pretty straightforward to implement this. But there are underlying design issues that make it not as simple as it appears.

  • Using the red X button to close the search bar will throw the toggled button out of sync. There's probably a way to solve that, though, except for...
  • There can be two view panes, but there's only one Find button. If it's a toggle, then it will definitely go out of sync when switching between panes.

I'm at a crossroads. With just a single pane (and if we ignore the red x), it looks and works like the request asked - polished. But with multiple routes to throw things out of sync, I'm unsure how to proceed.

Thoughts?

sharvey created this task.Apr 9 2018, 7:51 PM


Screencast.

The patch is only a few lines (a KToggleAction and a new slot), but I figured it was just as easy to show the situation than expect everyone to bother patching and recompiling something that's up for discussion.

IMHO this should be in patch form, with [WIP] in the title. You can add the video to the Summary section of the revision.

It should probably be possible to have the state of the button get updated:

  • When the close button is clicked
  • When the split panel focus changes

Will do. I'll keep working on it. I thought it might be something worthy of discussion before submitting a [WIP] patch.

Let me try a little more tinkering.

Additionally, opening up a new tab could also cause more problems...
We would need to come up with a reliable way of detecting whether the search box is opened in a specific panel or not & update the state of the button respectively. I think we should still strive to implement this (even if this would be more complicated), as the feature itself is rather useful for the UX & we could also consider removing the [X] that currently looks a bit off.

We probably need to keep the close button because people can remove the Find button from the toolbar.

Okay, so the functionality we are discussing is already implemented with D10246, but this patch suffers from the same problem. The patch does not apply cleanly for me, so I wasn't able to fiddle around with it. But theoretically, if we could resolve the remaining problem (Ctrl + F also closes the search box), we could simply use D10246 and the wish from bug 353227 would be fulfilled.

Uploading here the old patch on reviewboard:

Since we have three patches that implement this (D10246, D12094, and D23232), I think it's time to make a decision. :)