]> cloud.milkyroute.net Git - dolphin.git/blobdiff - src/main.cpp
GIT_SILENT made messages (after extraction)
[dolphin.git] / src / main.cpp
index ef2905d776ade988e669f67dd134e78cce10f146..6e9ef0b2a6dce729aecb29f5a641618aa7f950c5 100644 (file)
@@ -37,7 +37,7 @@
 #endif
 #include <iostream>
 
-extern "C" Q_DECL_EXPORT int kdemain(int argc, char **argv)
+int main(int argc, char **argv)
 {
 #ifndef Q_OS_WIN
     // Prohibit using sudo or kdesu (but allow using the root user directly)
@@ -202,12 +202,12 @@ extern "C" Q_DECL_EXPORT int kdemain(int argc, char **argv)
                 // If the user passed any URLs to Dolphin, open those in the
                 // window after session-restoring it
                 if (startedWithURLs) {
-                    mainWindow->openDirectories(urls, splitView);
+                    if (openFiles) {
+                        mainWindow->openFiles(urls, splitView);
+                    } else {
+                        mainWindow->openDirectories(urls, splitView);
+                    }
                 }
-
-                // Now handle invalid locations in the set of active views to
-                // avoid issues like https://bugs.kde.org/show_bug.cgi?id=427619
-                mainWindow->setViewsWithInvalidPathsToHome();
             } else {
                 qCWarning(DolphinDebug) << "Unknown class " << className << " in session saved data!";
             }