Fader image update for more tactile "track" feel.
[ardour.git] / gtk2_ardour / ardour_message.cc
index 52b7ab567c0583a01f7b61c9ea5b6596c81f3a96..2948559f1485ef82de6ca2c2eaec8e07fdc922d8 100644 (file)
 
 */
 
+#include <gtkmm/stock.h>
+
 #include "ardour_message.h"
 #include "i18n.h"
 
 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"))
+         label (msg)
 {
-       set_keyboard_input (true);
-
-       label.set_text (msg);
-       label.set_alignment (0.5, 0.5);
        label.set_name (X_("PrompterLabel"));
+       label.set_justify (JUSTIFY_CENTER);
+       label.show ();
+
+       get_vbox()->pack_start (label);
        
-       ok_button.set_name ("EditorGTKButton"); 
-       ok_button.clicked.connect (bind (slot (*this, &ArdourDialog::stop), 1));
-       
-       packer.set_spacing (10);
-       packer.set_border_width (10);
-       packer.pack_start (label);
-       packer.pack_start (ok_button);
+       Button* ok_button = add_button (Stock::OK, RESPONSE_ACCEPT);
        
        set_name (X_("Prompter"));
-       set_position (GTK_WIN_POS_MOUSE);
+       set_position (Gtk::WIN_POS_MOUSE);
        set_modal (true);
-       add (packer);
-       show_all ();
-       
-       realize();
-       get_window().set_decorations (GdkWMDecoration (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) {