D20532: Proof of Concept: Add double click actions to empty space in the folder view

George Florea Banus noreply at phabricator.kde.org
Sun Aug 4 18:13:45 BST 2019


fbg13 added a comment.


  In D20532#506470 <https://phabricator.kde.org/D20532#506470>, @ngraham wrote:
  
  > Finally, it feels quite slow. When I double-click, there's a noticeable delay before the action gets executed. Maybe this is because of all the scanning widgets to find the main window? That doesn't feel like the correct approach, just browsing the diff.
  
  
  For me there is no delay, but I also don't like the loop. The alternatives I found are:
  
    (DolphinMainWindow *)QApplication::activeWindow();
    (DolphinMainWindow *)QApplication::topLevelAt(QCursor::pos());
  
  Both work. Which should I use? If there's a better way let me know.
  
  > Oh and one last thing: every action seems to have an ampersand at the beginning of its name
  
  That is the text set for the action <https://github.com/KDE/kconfigwidgets/blob/master/src/kstandardaction.cpp#L167>. 
  I think Qt hides the & in widgets that support actions, but QComboBox doesn't support actions.
  Since I just take the action text when creating the QComboBox item that is what is shown, will fix.
  
  ----
  
  Also, since I'm at it, I think it will be good to add support for middle click too.
  So there will be an action for double click and one for middle click.
  What do you think?

REPOSITORY
  R318 Dolphin

REVISION DETAIL
  https://phabricator.kde.org/D20532

To: fbg13, #dolphin, elvisangelaccio, #vdg, ngraham
Cc: kneckermcknacksack, ngraham, kfm-devel, aprcela, vmarinescu, fprice, fbampaloukas, alexde, feverfew, meven, spoorun, navarromorales, firef, andrebarros, emmanuelp, mikesomov
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://mail.kde.org/mailman/private/kfm-devel/attachments/20190804/37620f40/attachment.htm>


More information about the kfm-devel mailing list