diff options
Diffstat (limited to 'libs')
-rw-r--r-- | libs/ardour/ardour/region.h | 2 | ||||
-rw-r--r-- | libs/ardour/region.cc | 2 | ||||
-rw-r--r-- | libs/gtkmm2ext/gtk_ui.cc | 11 | ||||
-rw-r--r-- | libs/gtkmm2ext/gtkmm2ext/gtk_ui.h | 6 |
4 files changed, 14 insertions, 7 deletions
diff --git a/libs/ardour/ardour/region.h b/libs/ardour/ardour/region.h index 8ab99fa151..0002356f41 100644 --- a/libs/ardour/ardour/region.h +++ b/libs/ardour/ardour/region.h @@ -156,7 +156,7 @@ class Region : public PBD::StatefulDestructible, public boost::enable_shared_fro void clear_sync_position (); void set_hidden (bool yn); void set_muted (bool yn); - void set_opaque (bool yn); + void set_opaque (bool yn); void set_locked (bool yn); virtual uint32_t read_data_count() const { return _read_data_count; } diff --git a/libs/ardour/region.cc b/libs/ardour/region.cc index 2b11bcc3df..7e131eab51 100644 --- a/libs/ardour/region.cc +++ b/libs/ardour/region.cc @@ -586,7 +586,7 @@ Region::set_opaque (bool yn) } else { _flags = Flag (_flags & ~Opaque); } - send_change (OpacityChanged); + send_change (OpacityChanged); } } diff --git a/libs/gtkmm2ext/gtk_ui.cc b/libs/gtkmm2ext/gtk_ui.cc index 903f56ba6f..be415acba2 100644 --- a/libs/gtkmm2ext/gtk_ui.cc +++ b/libs/gtkmm2ext/gtk_ui.cc @@ -61,7 +61,7 @@ BaseUI::RequestType Gtkmm2ext::AddTimeout = BaseUI::new_request_type(); #include <pbd/abstract_ui.cc> /* instantiate the template */ -UI::UI (string namestr, int *argc, char ***argv, string rcfile) +UI::UI (string namestr, int *argc, char ***argv) : AbstractUI<UIRequest> (namestr, true) { theMain = new Main (argc, argv); @@ -99,7 +99,6 @@ UI::UI (string namestr, int *argc, char ***argv, string rcfile) register_thread (pthread_self(), X_("GUI")); - load_rcfile (rcfile); } UI::~UI () @@ -114,7 +113,7 @@ UI::caller_is_ui_thread () } int -UI::load_rcfile (string path) +UI::load_rcfile (string path, bool themechange) { if (path.length() == 0) { return -1; @@ -129,6 +128,12 @@ UI::load_rcfile (string path) } RC rc (path.c_str()); + RC::reset_styles(Gtk::Settings::get_default()); + theme_changed.emit(); + + if (themechange) { + return 0; //Don't continue on every time there is a theme change + } /* have to pack widgets into a toplevel window so that styles will stick */ diff --git a/libs/gtkmm2ext/gtkmm2ext/gtk_ui.h b/libs/gtkmm2ext/gtkmm2ext/gtk_ui.h index b6a52c6c0c..0c2ff0d798 100644 --- a/libs/gtkmm2ext/gtkmm2ext/gtk_ui.h +++ b/libs/gtkmm2ext/gtkmm2ext/gtk_ui.h @@ -87,7 +87,7 @@ struct UIRequest : public BaseUI::BaseRequestObject { class UI : public Receiver, public AbstractUI<UIRequest> { public: - UI (string name, int *argc, char **argv[], string rcfile); + UI (string name, int *argc, char **argv[]); virtual ~UI (); static UI *instance() { return theGtkUI; } @@ -107,7 +107,7 @@ class UI : public Receiver, public AbstractUI<UIRequest> bool running (); void quit (); void kill (); - int load_rcfile (string); + int load_rcfile (string, bool themechange = false); void run (Receiver &old_receiver); void set_state (Gtk::Widget *w, Gtk::StateType state); @@ -132,6 +132,8 @@ class UI : public Receiver, public AbstractUI<UIRequest> sigc::signal<void> starting; sigc::signal<void> stopping; + sigc::signal<void> theme_changed; + static bool just_hide_it (GdkEventAny *, Gtk::Window *); static pthread_t the_gui_thread() { return gui_thread; } |