summaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
authorStanislaw Halik <sthalik@misaki.pl>2016-08-10 18:14:39 +0200
committerStanislaw Halik <sthalik@misaki.pl>2016-08-10 18:14:39 +0200
commit85dd83ca6918b8ad94a301237b7912e7e556a6e8 (patch)
tree15ff84ac7c9295a114958e104b62b3dc6b07a3de
parente4c22ada2f508a39976fa6333dbf79dffccb5666 (diff)
gui/main: display exit messages to debug what destructor is called where
-rw-r--r--gui/main.cpp27
1 files changed, 19 insertions, 8 deletions
diff --git a/gui/main.cpp b/gui/main.cpp
index 7adb7a7d..f2688302 100644
--- a/gui/main.cpp
+++ b/gui/main.cpp
@@ -16,6 +16,7 @@ using namespace options;
#include <QStyleFactory>
#include <QStringList>
#include <QMessageBox>
+#include <QDebug>
#include <memory>
#include <cstring>
@@ -130,16 +131,26 @@ int main(int argc, char** argv)
MainWindow::set_working_directory();
- mem<MainWindow> w = std::make_shared<MainWindow>();
-
- if (!w->is_tray_enabled())
- w->show();
- else
{
- w->setVisible(false);
- w->setHidden(true);
+ mem<MainWindow> w = std::make_shared<MainWindow>();
+
+ if (!w->is_tray_enabled())
+ {
+ w->setHidden(false);
+ w->show();
+ }
+ else
+ {
+ w->setVisible(false);
+ w->setHidden(true);
+ }
+
+ app.exec();
+
+ qDebug() << "exit: now deleting main control";
}
- app.exec();
+
+ qDebug() << "exit: main() now exits";
return 0;
}