From 51a9de94671f1f7ee1cf2a57ef5dfde94b4a802b Mon Sep 17 00:00:00 2001 From: John Smith Date: Sun, 30 Sep 2012 14:01:21 +0900 Subject: Fix for 1058470 : Trace Bitmap Live Preview (bzr r11716) --- src/ui/widget/panel.cpp | 14 +++++++++----- 1 file changed, 9 insertions(+), 5 deletions(-) (limited to 'src/ui/widget/panel.cpp') diff --git a/src/ui/widget/panel.cpp b/src/ui/widget/panel.cpp index 1f945ada6..42435f298 100644 --- a/src/ui/widget/panel.cpp +++ b/src/ui/widget/panel.cpp @@ -572,21 +572,21 @@ void Panel::_apply() g_warning("Apply button clicked for panel [Panel::_apply()]"); } -Gtk::Button *Panel::addResponseButton(const Glib::ustring &button_text, int response_id) +Gtk::Button *Panel::addResponseButton(const Glib::ustring &button_text, int response_id, bool pack_start) { Gtk::Button *button = new Gtk::Button(button_text); - _addResponseButton(button, response_id); + _addResponseButton(button, response_id, pack_start); return button; } -Gtk::Button *Panel::addResponseButton(const Gtk::StockID &stock_id, int response_id) +Gtk::Button *Panel::addResponseButton(const Gtk::StockID &stock_id, int response_id, bool pack_start) { Gtk::Button *button = new Gtk::Button(stock_id); - _addResponseButton(button, response_id); + _addResponseButton(button, response_id, pack_start); return button; } -void Panel::_addResponseButton(Gtk::Button *button, int response_id) +void Panel::_addResponseButton(Gtk::Button *button, int response_id, bool pack_start) { // Create a button box for the response buttons if it's the first button to be added if (!_action_area) { @@ -597,6 +597,10 @@ void Panel::_addResponseButton(Gtk::Button *button, int response_id) _action_area->pack_end(*button); + if (pack_start) { + _action_area->set_child_secondary( *button , true); + } + if (response_id != 0) { // Re-emit clicked signals as response signals button->signal_clicked().connect(sigc::bind(_signal_response.make_slot(), response_id)); -- cgit v1.2.3