X-Git-Url: https://git.quassel-irc.org/?a=blobdiff_plain;f=src%2Fqtui%2Fmainwin.cpp;h=00f8372536a14dddaf397f89e8aed1dd51c5ad4d;hb=a888a2886dc1466eb0b1bb3591f43350623c6330;hp=49c3d3d4ba14fd9987c6a313b6d4cc7b7c28a529;hpb=68ba16b2340ed20508bb7789c51b700b562f2392;p=quassel.git diff --git a/src/qtui/mainwin.cpp b/src/qtui/mainwin.cpp index 49c3d3d4..00f83725 100644 --- a/src/qtui/mainwin.cpp +++ b/src/qtui/mainwin.cpp @@ -299,11 +299,7 @@ void MainWin::init() // restore locked state of docks QtUi::actionCollection("General")->action("LockLayout")->setChecked(s.value("LockLayout", false).toBool()); - CoreConnection *conn = Client::coreConnection(); - if (!conn->connectToCore()) { - // No autoconnect selected (or no accounts) - showCoreConnectionDlg(); - } + QTimer::singleShot(0, this, SLOT(doAutoConnect())); } @@ -460,7 +456,7 @@ void MainWin::setupActions() coll->addAction("ConfigureQuassel", configureQuasselAct); // Help - QAction *aboutQuasselAct = new Action(QIcon(":/icons/quassel.png"), tr("&About Quassel"), coll, + QAction *aboutQuasselAct = new Action(QIcon::fromTheme("quassel"), tr("&About Quassel"), coll, this, SLOT(showAboutDlg())); aboutQuasselAct->setMenuRole(QAction::AboutRole); coll->addAction("AboutQuassel", aboutQuasselAct); @@ -1149,7 +1145,6 @@ void MainWin::setupSystray() #else _systemTray = new SystemTray(this); // dummy #endif - _systemTray->init(); } @@ -1218,6 +1213,15 @@ void MainWin::saveMainToolBarStatus(bool enabled) } +void MainWin::doAutoConnect() +{ + if (!Client::coreConnection()->connectToCore()) { + // No autoconnect selected (or no accounts) + showCoreConnectionDlg(); + } +} + + void MainWin::connectedToCore() { Q_CHECK_PTR(Client::bufferViewManager());