mirror of
https://github.com/Ardour/ardour.git
synced 2025-12-08 15:54:57 +01:00
Add option to hide the 2ndary clock
This commit is contained in:
parent
ef8187662a
commit
91321272b5
6 changed files with 44 additions and 3 deletions
|
|
@ -272,6 +272,7 @@ ARDOUR_UI::ARDOUR_UI (int *argcp, char **argvp[], const char* localedir)
|
||||||
, _mixer_on_top (false)
|
, _mixer_on_top (false)
|
||||||
, _initial_verbose_plugin_scan (false)
|
, _initial_verbose_plugin_scan (false)
|
||||||
, first_time_engine_run (true)
|
, first_time_engine_run (true)
|
||||||
|
, secondary_clock_spacer (0)
|
||||||
, roll_controllable (new TransportControllable ("transport roll", *this, TransportControllable::Roll))
|
, roll_controllable (new TransportControllable ("transport roll", *this, TransportControllable::Roll))
|
||||||
, stop_controllable (new TransportControllable ("transport stop", *this, TransportControllable::Stop))
|
, stop_controllable (new TransportControllable ("transport stop", *this, TransportControllable::Stop))
|
||||||
, goto_start_controllable (new TransportControllable ("transport goto start", *this, TransportControllable::GotoStart))
|
, goto_start_controllable (new TransportControllable ("transport goto start", *this, TransportControllable::GotoStart))
|
||||||
|
|
|
||||||
|
|
@ -101,6 +101,7 @@
|
||||||
class About;
|
class About;
|
||||||
class AddRouteDialog;
|
class AddRouteDialog;
|
||||||
class AddVideoDialog;
|
class AddVideoDialog;
|
||||||
|
class ArdourVSpacer;
|
||||||
class BigClockWindow;
|
class BigClockWindow;
|
||||||
class BundleManager;
|
class BundleManager;
|
||||||
class EngineControl;
|
class EngineControl;
|
||||||
|
|
@ -478,7 +479,9 @@ private:
|
||||||
Gtk::Frame transport_frame;
|
Gtk::Frame transport_frame;
|
||||||
Gtk::HBox transport_hbox;
|
Gtk::HBox transport_hbox;
|
||||||
|
|
||||||
|
ArdourVSpacer *secondary_clock_spacer;
|
||||||
void repack_transport_hbox ();
|
void repack_transport_hbox ();
|
||||||
|
void update_clock_visibility ();
|
||||||
|
|
||||||
struct TransportControllable : public PBD::Controllable {
|
struct TransportControllable : public PBD::Controllable {
|
||||||
enum ToggleType {
|
enum ToggleType {
|
||||||
|
|
|
||||||
|
|
@ -214,6 +214,25 @@ ARDOUR_UI::repack_transport_hbox ()
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void
|
||||||
|
ARDOUR_UI::update_clock_visibility ()
|
||||||
|
{
|
||||||
|
if (ARDOUR::Profile->get_small_screen()) {
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
if (UIConfiguration::instance().get_show_secondary_clock ()) {
|
||||||
|
secondary_clock->show();
|
||||||
|
secondary_clock->left_btn()->show();
|
||||||
|
secondary_clock->right_btn()->show();
|
||||||
|
secondary_clock_spacer->show();
|
||||||
|
} else {
|
||||||
|
secondary_clock->hide();
|
||||||
|
secondary_clock->left_btn()->hide();
|
||||||
|
secondary_clock->right_btn()->hide();
|
||||||
|
secondary_clock_spacer->hide();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
bool
|
bool
|
||||||
ARDOUR_UI::transport_expose (GdkEventExpose* ev)
|
ARDOUR_UI::transport_expose (GdkEventExpose* ev)
|
||||||
{
|
{
|
||||||
|
|
@ -543,11 +562,15 @@ ARDOUR_UI::setup_transport ()
|
||||||
transport_table.attach (*secondary_clock, col, col + 2, 0, 1 , FILL, SHRINK, 2, 0);
|
transport_table.attach (*secondary_clock, col, col + 2, 0, 1 , FILL, SHRINK, 2, 0);
|
||||||
transport_table.attach (*secondary_clock->left_btn(), col, col + 1, 1, 2 , FILL, SHRINK, 2, 0);
|
transport_table.attach (*secondary_clock->left_btn(), col, col + 1, 1, 2 , FILL, SHRINK, 2, 0);
|
||||||
transport_table.attach (*secondary_clock->right_btn(), col + 1, col + 2, 1, 2 , FILL, SHRINK, 2, 0);
|
transport_table.attach (*secondary_clock->right_btn(), col + 1, col + 2, 1, 2 , FILL, SHRINK, 2, 0);
|
||||||
|
secondary_clock->set_no_show_all (true);
|
||||||
|
secondary_clock->left_btn()->set_no_show_all (true);
|
||||||
|
secondary_clock->right_btn()->set_no_show_all (true);
|
||||||
col += 2;
|
col += 2;
|
||||||
}
|
|
||||||
|
|
||||||
transport_table.attach (*(manage (new ArdourVSpacer ())), TCOL, 0, 2 , SHRINK, EXPAND|FILL, 3, 0);
|
secondary_clock_spacer = manage (new ArdourVSpacer ());
|
||||||
|
transport_table.attach (*secondary_clock_spacer, TCOL, 0, 2 , SHRINK, EXPAND|FILL, 3, 0);
|
||||||
++col;
|
++col;
|
||||||
|
}
|
||||||
|
|
||||||
transport_table.attach (*alert_box, TCOL, 0, 2, SHRINK, EXPAND|FILL, 2, 0);
|
transport_table.attach (*alert_box, TCOL, 0, 2, SHRINK, EXPAND|FILL, 2, 0);
|
||||||
++col;
|
++col;
|
||||||
|
|
@ -569,6 +592,7 @@ ARDOUR_UI::setup_transport ()
|
||||||
++col;
|
++col;
|
||||||
|
|
||||||
repack_transport_hbox ();
|
repack_transport_hbox ();
|
||||||
|
update_clock_visibility ();
|
||||||
/* desensitize */
|
/* desensitize */
|
||||||
|
|
||||||
feedback_alert_button.set_sensitive (false);
|
feedback_alert_button.set_sensitive (false);
|
||||||
|
|
|
||||||
|
|
@ -409,6 +409,8 @@ ARDOUR_UI::parameter_changed (std::string p)
|
||||||
repack_transport_hbox ();
|
repack_transport_hbox ();
|
||||||
} else if (p == "show-editor-meter") {
|
} else if (p == "show-editor-meter") {
|
||||||
repack_transport_hbox ();
|
repack_transport_hbox ();
|
||||||
|
} else if (p == "show-secondary-clock") {
|
||||||
|
update_clock_visibility ();
|
||||||
} else if (p == "waveform-scale") {
|
} else if (p == "waveform-scale") {
|
||||||
ArdourCanvas::WaveView::set_global_logscaled (UIConfiguration::instance().get_waveform_scale() == Logarithmic);
|
ArdourCanvas::WaveView::set_global_logscaled (UIConfiguration::instance().get_waveform_scale() == Logarithmic);
|
||||||
} else if (p == "widget-prelight") {
|
} else if (p == "widget-prelight") {
|
||||||
|
|
|
||||||
|
|
@ -3489,6 +3489,16 @@ if (!ARDOUR::Profile->get_mixbus()) {
|
||||||
sigc::mem_fun (UIConfiguration::instance(), &UIConfiguration::set_show_toolbar_selclock)
|
sigc::mem_fun (UIConfiguration::instance(), &UIConfiguration::set_show_toolbar_selclock)
|
||||||
));
|
));
|
||||||
|
|
||||||
|
if (!ARDOUR::Profile->get_small_screen()) {
|
||||||
|
add_option (_("GUI/Toolbar"),
|
||||||
|
new BoolOption (
|
||||||
|
"show-secondary-clock",
|
||||||
|
_("Display Secondary Clock in the Toolbar"),
|
||||||
|
sigc::mem_fun (UIConfiguration::instance(), &UIConfiguration::get_show_secondary_clock),
|
||||||
|
sigc::mem_fun (UIConfiguration::instance(), &UIConfiguration::set_show_secondary_clock)
|
||||||
|
));
|
||||||
|
}
|
||||||
|
|
||||||
add_option (_("GUI/Toolbar"),
|
add_option (_("GUI/Toolbar"),
|
||||||
new BoolOption (
|
new BoolOption (
|
||||||
"show-mini-timeline",
|
"show-mini-timeline",
|
||||||
|
|
|
||||||
|
|
@ -74,6 +74,7 @@ UI_CONFIG_VARIABLE (bool, meter_style_led, "meter-style-led", false)
|
||||||
UI_CONFIG_VARIABLE (bool, show_editor_meter, "show-editor-meter", true)
|
UI_CONFIG_VARIABLE (bool, show_editor_meter, "show-editor-meter", true)
|
||||||
UI_CONFIG_VARIABLE (bool, show_toolbar_selclock, "show-toolbar-selclock", false)
|
UI_CONFIG_VARIABLE (bool, show_toolbar_selclock, "show-toolbar-selclock", false)
|
||||||
UI_CONFIG_VARIABLE (bool, show_mini_timeline, "show-mini-timeline", true)
|
UI_CONFIG_VARIABLE (bool, show_mini_timeline, "show-mini-timeline", true)
|
||||||
|
UI_CONFIG_VARIABLE (bool, show_secondary_clock, "show-secondary-clock", true)
|
||||||
UI_CONFIG_VARIABLE (double, waveform_clip_level, "waveform-clip-level", -0.0933967) /* units of dB */
|
UI_CONFIG_VARIABLE (double, waveform_clip_level, "waveform-clip-level", -0.0933967) /* units of dB */
|
||||||
UI_CONFIG_VARIABLE (bool, hiding_groups_deactivates_groups, "hiding-groups-deactivates-groups", true)
|
UI_CONFIG_VARIABLE (bool, hiding_groups_deactivates_groups, "hiding-groups-deactivates-groups", true)
|
||||||
UI_CONFIG_VARIABLE (bool, no_new_session_dialog, "no-new-session-dialog", false)
|
UI_CONFIG_VARIABLE (bool, no_new_session_dialog, "no-new-session-dialog", false)
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue