diff options
Diffstat (limited to 'libs')
-rw-r--r-- | libs/gtkmm2ext/gtk_ui.cc | 10 | ||||
-rw-r--r-- | libs/gtkmm2ext/gtkmm2ext/gtk_ui.h | 3 |
2 files changed, 7 insertions, 6 deletions
diff --git a/libs/gtkmm2ext/gtk_ui.cc b/libs/gtkmm2ext/gtk_ui.cc index 6e466f5c9f..d9e4c871a6 100644 --- a/libs/gtkmm2ext/gtk_ui.cc +++ b/libs/gtkmm2ext/gtk_ui.cc @@ -120,9 +120,9 @@ UI::UI (string namestr, int *argc, char ***argv) UI::~UI () { + _receiver.hangup (); } - bool UI::caller_is_ui_thread () { @@ -265,12 +265,14 @@ UI::run (Receiver &old_receiver) Glib::signal_idle().connect (bind_return (mem_fun (old_receiver, &Receiver::hangup), false)); - starting (); + if (starting ()) { + return; + } + _active = true; theMain->run (); _active = false; - stopping (); - _receiver.hangup (); + return; } diff --git a/libs/gtkmm2ext/gtkmm2ext/gtk_ui.h b/libs/gtkmm2ext/gtkmm2ext/gtk_ui.h index 64176232f0..232e7682ed 100644 --- a/libs/gtkmm2ext/gtkmm2ext/gtk_ui.h +++ b/libs/gtkmm2ext/gtkmm2ext/gtk_ui.h @@ -152,8 +152,7 @@ class UI : public AbstractUI<UIRequest> stopping just after we return from it (at the top level) */ - sigc::signal<void> starting; - sigc::signal<void> stopping; + virtual int starting() = 0; sigc::signal<void> theme_changed; |