summaryrefslogtreecommitdiff
path: root/libs
diff options
context:
space:
mode:
authorCarl Hetherington <carl@carlh.net>2011-01-03 03:11:31 +0000
committerCarl Hetherington <carl@carlh.net>2011-01-03 03:11:31 +0000
commit5b8472314e0471eb19244b6e949bde0ce90cc3e8 (patch)
tree776fadc13962358b5891813c335ec2587a3e53a4 /libs
parentcf45b07f73c9b2c8d19365d27b4f8f5004822095 (diff)
Add option to show or hide zoom toolbar.
git-svn-id: svn://localhost/ardour2/branches/3.0@8413 d708f5d6-7413-0410-9779-e7cbd77b26cf
Diffstat (limited to 'libs')
-rw-r--r--libs/ardour/ardour/rc_configuration_vars.h3
-rw-r--r--libs/gtkmm2ext/gtkmm2ext/tearoff.h2
-rw-r--r--libs/gtkmm2ext/tearoff.cc4
3 files changed, 6 insertions, 3 deletions
diff --git a/libs/ardour/ardour/rc_configuration_vars.h b/libs/ardour/ardour/rc_configuration_vars.h
index d06edac230..f8bdab0a82 100644
--- a/libs/ardour/ardour/rc_configuration_vars.h
+++ b/libs/ardour/ardour/rc_configuration_vars.h
@@ -157,3 +157,6 @@ CONFIG_VARIABLE (int32_t, processor_usage, "processor-usage", -1)
CONFIG_VARIABLE (bool, denormal_protection, "denormal-protection", false)
CONFIG_VARIABLE (DenormalModel, denormal_model, "denormal-model", DenormalNone)
+/* visibility of toolbar components */
+
+CONFIG_VARIABLE (bool, show_zoom_tools, "show-zoom-tools", true)
diff --git a/libs/gtkmm2ext/gtkmm2ext/tearoff.h b/libs/gtkmm2ext/gtkmm2ext/tearoff.h
index 051217aedb..38cc3d2a1a 100644
--- a/libs/gtkmm2ext/gtkmm2ext/tearoff.h
+++ b/libs/gtkmm2ext/gtkmm2ext/tearoff.h
@@ -35,7 +35,7 @@ class TearOff : public Gtk::HBox
TearOff (Gtk::Widget& contents, bool allow_resize = false);
virtual ~TearOff ();
- void set_visible (bool yn);
+ void set_visible (bool yn, bool force = false);
void set_can_be_torn_off (bool);
bool can_be_torn_off () const { return _can_be_torn_off; }
diff --git a/libs/gtkmm2ext/tearoff.cc b/libs/gtkmm2ext/tearoff.cc
index bc8829d94f..0f214dda95 100644
--- a/libs/gtkmm2ext/tearoff.cc
+++ b/libs/gtkmm2ext/tearoff.cc
@@ -112,7 +112,7 @@ TearOff::set_can_be_torn_off (bool yn)
}
void
-TearOff::set_visible (bool yn)
+TearOff::set_visible (bool yn, bool force)
{
/* don't change visibility if torn off */
@@ -120,7 +120,7 @@ TearOff::set_visible (bool yn)
return;
}
- if (_visible != yn) {
+ if (_visible != yn || force) {
_visible = yn;
if (yn) {
show_all();