forked from blue/squawk
connectivity, roster position size and state, expanded anccounts and groups restoration with the settings
This commit is contained in:
parent
0bcfd779b8
commit
3e594c7e13
5 changed files with 162 additions and 4 deletions
7
main.cpp
7
main.cpp
|
@ -39,7 +39,7 @@ int main(int argc, char *argv[])
|
|||
|
||||
QApplication::setApplicationName("squawk");
|
||||
QApplication::setApplicationDisplayName("Squawk");
|
||||
QApplication::setApplicationVersion("0.1.1");
|
||||
QApplication::setApplicationVersion("0.1.2");
|
||||
|
||||
QTranslator qtTranslator;
|
||||
qtTranslator.load("qt_" + QLocale::system().name(), QLibraryInfo::location(QLibraryInfo::TranslationsPath));
|
||||
|
@ -81,6 +81,7 @@ int main(int argc, char *argv[])
|
|||
|
||||
QObject::connect(coreThread, &QThread::started, squawk, &Core::Squawk::start);
|
||||
QObject::connect(&app, &QApplication::aboutToQuit, squawk, &Core::Squawk::stop);
|
||||
QObject::connect(&app, &QApplication::aboutToQuit, &w, &QMainWindow::close);
|
||||
QObject::connect(squawk, &Core::Squawk::quit, coreThread, &QThread::quit);
|
||||
QObject::connect(coreThread, &QThread::finished, squawk, &Core::Squawk::deleteLater);
|
||||
|
||||
|
@ -141,10 +142,14 @@ int main(int argc, char *argv[])
|
|||
QObject::connect(squawk, &Core::Squawk::responseVCard, &w, &Squawk::responseVCard);
|
||||
|
||||
coreThread->start();
|
||||
w.readSettings();
|
||||
|
||||
int result = app.exec();
|
||||
|
||||
w.writeSettings();
|
||||
coreThread->wait(500); //TODO hate doing that but settings for some reason don't get saved to the disk
|
||||
|
||||
|
||||
return result;
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue