#include <KCrash>
#include <KDBusService>
#include <KLocalizedString>
-#include <KToolBar>
#include <Kdelibs4ConfigMigrator>
#include <KConfigGui>
#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)
mainWindow->show();
- KDBusService dolphinDBusService;
+ // Allow starting Dolphin on a system that is not running DBus:
+ KDBusService::StartupOptions serviceOptions = KDBusService::Multiple;
+ if (!QDBusConnection::sessionBus().isConnected()) {
+ serviceOptions |= KDBusService::NoExitOnFailure;
+ }
+ KDBusService dolphinDBusService(serviceOptions);
DBusInterface interface;
if (!app.isSessionRestored()) {
}
}
}
- Qt::ToolBarArea area = mainWindow->toolBarArea(mainWindow->toolBar());
- if (area != Qt::TopToolBarArea && area != Qt::BottomToolBarArea) {
- // Migrate users with disabled tool bar positions.
- // Remove this a few years from now (2020).
- mainWindow->addToolBar(Qt::TopToolBarArea, mainWindow->toolBar());
- }
#ifdef HAVE_KUSERFEEDBACK
auto feedbackProvider = DolphinFeedbackProvider::instance();