diff options
author | Ken Moore <ken@pcbsd.org> | 2014-10-08 16:36:18 -0400 |
---|---|---|
committer | Ken Moore <ken@pcbsd.org> | 2014-10-08 16:36:18 -0400 |
commit | be1748142882470d6a9f9876a590981b37ba7d6d (patch) | |
tree | e83cc873bb337534b410e50d6f9b6ac43850eab8 /lumina-open | |
parent | Oops, fix a typo in the lumina-open usage: Missed removing a couple of the QS... (diff) | |
download | lumina-be1748142882470d6a9f9876a590981b37ba7d6d.tar.gz lumina-be1748142882470d6a9f9876a590981b37ba7d6d.tar.bz2 lumina-be1748142882470d6a9f9876a590981b37ba7d6d.zip |
Make sure the directory catch for running lumina-fm happens at the end (in case of an invalid default that was set).
Diffstat (limited to 'lumina-open')
-rw-r--r-- | lumina-open/main.cpp | 8 |
1 files changed, 3 insertions, 5 deletions
diff --git a/lumina-open/main.cpp b/lumina-open/main.cpp index 1b8d0446..c0e7be0f 100644 --- a/lumina-open/main.cpp +++ b/lumina-open/main.cpp @@ -76,10 +76,7 @@ void showOSD(int argc, char **argv, QString message){ QString cmdFromUser(int argc, char **argv, QString inFile, QString extension, QString& path, bool showDLG=false){ //First check to see if there is a default for this extension QString defApp = LFileDialog::getDefaultApp(extension); - if(extension=="directory" && defApp.isEmpty() && !showDLG){ - //Just use the Lumina File Manager - return "lumina-fm"; - }else if( !defApp.isEmpty() && !showDLG ){ + if( !defApp.isEmpty() && !showDLG ){ bool ok = false; if(defApp.endsWith(".desktop")){ XDGDesktop DF = LXDG::loadDesktopFile(defApp, ok); @@ -101,7 +98,8 @@ QString cmdFromUser(int argc, char **argv, QString inFile, QString extension, QS //invalid default - reset it and continue on LFileDialog::setDefaultApp(extension, ""); } - + //Final catch: directory given - no valid default found - use lumina-fm + if(extension=="directory" && !showDLG){ return "lumina-fm"; } //No default set -- Start up the application selection dialog QApplication App(argc, argv); QTranslator translator; |