summaryrefslogtreecommitdiff
path: root/gtk2_ardour/visual_time_axis.cc
diff options
context:
space:
mode:
authorPaul Davis <paul@linuxaudiosystems.com>2006-03-21 21:08:24 +0000
committerPaul Davis <paul@linuxaudiosystems.com>2006-03-21 21:08:24 +0000
commit004a49b0c7051a4d0f8972b0aff0ef8fa9cab03d (patch)
tree714a876b19460d82f5793f68bc4c3bfefb480d32 /gtk2_ardour/visual_time_axis.cc
parentd63c0fa328429ff0d7917fe3f4458c97063ba450 (diff)
Gtkmm2ext::Choice now inherits from Gtk::Dialog; embed/import rate mismatch dialog no longer hangs in recursive Main::run() call
git-svn-id: svn://localhost/trunk/ardour2@414 d708f5d6-7413-0410-9779-e7cbd77b26cf
Diffstat (limited to 'gtk2_ardour/visual_time_axis.cc')
-rw-r--r--gtk2_ardour/visual_time_axis.cc20
1 files changed, 8 insertions, 12 deletions
diff --git a/gtk2_ardour/visual_time_axis.cc b/gtk2_ardour/visual_time_axis.cc
index 2b9a55bb5c..23af21aaca 100644
--- a/gtk2_ardour/visual_time_axis.cc
+++ b/gtk2_ardour/visual_time_axis.cc
@@ -279,18 +279,14 @@ VisualTimeAxis::remove_this_time_axis(void* src)
Gtkmm2ext::Choice prompter (prompt, choices);
- prompter.chosen.connect(sigc::ptr_fun(Gtk::Main::quit));
- prompter.show_all ();
-
- Gtk::Main::run ();
-
- if (prompter.get_choice() == 0)
- {
- /*
- defer to idle loop, otherwise we'll delete this object
- while we're still inside this function ...
- */
- Glib::signal_idle().connect(bind(sigc::ptr_fun(&VisualTimeAxis::idle_remove_this_time_axis), this, src));
+ if (prompter.run () == RESPONSE_ACCEPT) {
+ if (prompter.get_choice() == 0) {
+ /*
+ defer to idle loop, otherwise we'll delete this object
+ while we're still inside this function ...
+ */
+ Glib::signal_idle().connect(bind(sigc::ptr_fun(&VisualTimeAxis::idle_remove_this_time_axis), this, src));
+ }
}
}