SUMMARY The context menu opened in an empty directory does not have the "Open with..." entry, which could be used e.g. to open an application like VSCode in it. STEPS TO REPRODUCE 1. Create an empty directory 2. Open it in Dolphin so that the view is blank 3. Right-click the blank Dolphin view OBSERVED RESULT There is no "Open with..." entry in the context menu. EXPECTED RESULT I would expect an "Open with..." entry to be present so that I can open the empty directory in an application like VSCode to start creating new content in the directory. SOFTWARE/OS VERSIONS Linux/KDE Plasma: Manjaro Linux testing KDE Plasma Version: 5.19.5 KDE Frameworks Version: 5.74.0 Qt Version: 5.15.1 ADDITIONAL INFORMATION When an empty directory is right-clicked "from the outside", i.e. its icon in the view of its parent directory, the context menu does contain an "Open with..." entry.
This is currently intentional. We got complaints about showing the menu item for empty folders in the past so we changed it in https://invent.kde.org/system/dolphin/-/commit/14f0cd52f61de7539e2d9c751966594708ed0281. Elvis, what do you think? Should we revert that, or close this as INTENTIONAL?
" Any app that registers itself as able to open directories generally can't do anything useful with an empty directory. So, don't show the {nav Open With} menu items for them " looks like above reasoning mentioned in the commit is proved false according to OP's use case. Reverting the commit would be recommended IMO
Yeah we should probably revert it, since there is a valid use case that is prevented from that commit.
All right, will do.
Git commit b343fdffc52ff42d83afa02f6eaf1f5a359a49a9 by Nate Graham. Committed on 13/10/2020 at 00:16. Pushed by ngraham into branch 'master'. Show "Open With" menu items even for empty dirs We found some legitimate use cases for this after all! :) This reverts 14f0cd52f61de7539e2d9c751966594708ed0281 FIXED-IN: 5.12 M +3 -5 src/dolphincontextmenu.cpp https://invent.kde.org/system/dolphin/commit/b343fdffc52ff42d83afa02f6eaf1f5a359a49a9