Currently in non-tab mode of dolphin, shortcut assigned to "close tab" (default: ctrl+w) event wont quit the last tab and close the window. The last tab on the window would only close on "quit" (default: ctrl+q) event. Please consider making this act more like firefox/chrome where ctrl+w also closes the window too with last tab. Or, at least provide a setting where such behaviour could be enabled.
Seems reasonable, will discuss with others whether this should be the standard behavior or if we need an option for this.
+1, I agree. One wrinkle is that it should only quit Dolphin when there's only one tab visible (i.e. when the tab bar isn't visible). I support adding this behavior to all KDE apps that use tabs, but as far as I can tell, it would need to be done for each app individually. So let's keep this for Dolphin.
Currently trying to add this feature. Seems to me that specifically ctrl-w is not emitting a call to close the tab when there is only one of them. However if you don't hide the tab bar, you can close the window (if you call quit() within it) by pressing the close tab button as the closeTab function is called but I ctrl-w doesn't do anything specifically when there is only one tab. But I can't seem to figure out why that is. Might possibly be related to how shortcuts are done in KStandardAction.
There's a patch: https://phabricator.kde.org/D15278
Git commit ac118ae1c236bee756593dea91efda6cde6fa634 by Elvis Angelaccio, on behalf of Alexander Saoutkin. Committed on 27/10/2018 at 09:24. Pushed by elvisangelaccio into branch 'master'. Close Dolphin if last tab closed Summary: Allows closing of last tab via shortcut or menubar (File->Close Tab), which then results in closing dolphin. Test Plan: [Manual] Check closing tab closes dolphin via shortcut and menubar. Reviewers: #dolphin, ngraham, #vdg, elvisangelaccio Reviewed By: #dolphin, ngraham, #vdg, elvisangelaccio Subscribers: thsurrel, svenmauch, abetts, elvisangelaccio, ngraham, #dolphin, kfm-devel Tags: #dolphin Differential Revision: https://phabricator.kde.org/D15278 M +0 -2 src/dolphinmainwindow.cpp M +2 -1 src/dolphintabwidget.cpp https://commits.kde.org/dolphin/ac118ae1c236bee756593dea91efda6cde6fa634