D24353: Add actions for switching to a specific tab
Alex Miranda
noreply at phabricator.kde.org
Thu Oct 3 14:02:33 BST 2019
alexmi added inline comments.
INLINE COMMENTS
> meven wrote in dolphinmainwindow.cpp:1512
> Simplier written with one check instead of two (i is < MaxActivateTabShortcuts) :
>
> int numberForShortcut;
> if (i == 9) {
> // tenth
> numberForShortcut = 0;
> } else {
> numberForShortcut = i + 1;
> }
The issue with doing that is that if MaxActivateTabShortcuts ever gets changed to anything higher than 10, then there would be extra calls to try to set shortcuts like Alt + 11.
I would say it's unlikely it ever gets changed to something higher than 10 but still.
Even when changing that `else` to an `else if`, you would still have to add another check somehow to make sure you're not calling `setDefaultShortcut` when i > 10.
REPOSITORY
R318 Dolphin
BRANCH
feature-tab-shortcuts (branched from master)
REVISION DETAIL
https://phabricator.kde.org/D24353
To: alexmi, #vdg, #dolphin, ngraham
Cc: meven, ngraham, elvisangelaccio, kfm-devel, iasensio, fprice, MrPepe, fbampaloukas, alexde, Codezela, feverfew, spoorun, navarromorales, firef, andrebarros, emmanuelp, mikesomov
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://mail.kde.org/mailman/private/kfm-devel/attachments/20191003/0e203654/attachment.htm>
More information about the kfm-devel
mailing list