diff options
author | Paul Davis <paul@linuxaudiosystems.com> | 2005-11-27 21:17:41 +0000 |
---|---|---|
committer | Paul Davis <paul@linuxaudiosystems.com> | 2005-11-27 21:17:41 +0000 |
commit | 1f16781c75205b43ac193596d1449de343693a6f (patch) | |
tree | 68f8f9ddd2b7dbe57b0ac2e2caa6fe6e8b9ba96c /gtk2_ardour/ardour_message.cc | |
parent | aaa44a37aaf585b9bcd9268a9551a005e6269bdb (diff) |
slowly fixing up ArdourDialog nonsense
git-svn-id: svn://localhost/trunk/ardour2@132 d708f5d6-7413-0410-9779-e7cbd77b26cf
Diffstat (limited to 'gtk2_ardour/ardour_message.cc')
-rw-r--r-- | gtk2_ardour/ardour_message.cc | 27 |
1 files changed, 8 insertions, 19 deletions
diff --git a/gtk2_ardour/ardour_message.cc b/gtk2_ardour/ardour_message.cc index f79defdf8a..48cfa80caf 100644 --- a/gtk2_ardour/ardour_message.cc +++ b/gtk2_ardour/ardour_message.cc @@ -19,7 +19,7 @@ */ -#include <gtkmm2ext/utils.h> +#include <gtkmm/stock.h> #include "ardour_message.h" #include "i18n.h" @@ -27,37 +27,26 @@ using namespace std; using namespace Gtk; - ArdourMessage::ArdourMessage (Gtk::Window* parent, string name, string msg, bool grab_focus, bool auto_run) - : ArdourDialog (name), - ok_button (_("OK")) + : ArdourDialog (name) { - set_keyboard_input (true); - label.set_text (msg); label.set_alignment (0.5, 0.5); label.set_name (X_("PrompterLabel")); - - ok_button.set_name ("EditorGTKButton"); - ok_button.signal_clicked().connect (bind (mem_fun(*this, &ArdourDialog::stop), 1)); - - packer.set_spacing (10); - packer.set_border_width (10); - packer.pack_start (label); - packer.pack_start (ok_button); + + get_vbox()->pack_start (label); + + Button* ok_button = add_button (Stock::OK, RESPONSE_ACCEPT); set_name (X_("Prompter")); set_position (Gtk::WIN_POS_MOUSE); set_modal (true); - add (packer); - show_all (); - - signal_realize().connect (bind (sigc::ptr_fun (Gtkmm2ext::set_decoration), this, Gdk::WMDecoration (GDK_DECOR_BORDER|GDK_DECOR_RESIZEH))); + set_type_hint (Gdk::WINDOW_TYPE_HINT_MENU); if (grab_focus) { - ok_button.grab_focus (); + ok_button->grab_focus (); } if (parent) { |