13
0

Consistently put ruler toggle code in the same order

Just reordering.
This commit is contained in:
Mads Kiilerich 2022-10-03 20:52:50 +02:00 committed by Robin Gareus
parent c010871d54
commit 34527525be
Signed by: rgareus
GPG Key ID: A090BCE02CF57F04
3 changed files with 25 additions and 26 deletions

View File

@ -954,16 +954,16 @@ private:
ArdourCanvas::Rectangle* _canvas_drop_zone;
bool canvas_drop_zone_event (GdkEvent* event);
Glib::RefPtr<Gtk::ToggleAction> ruler_timecode_action;
Glib::RefPtr<Gtk::ToggleAction> ruler_bbt_action;
Glib::RefPtr<Gtk::ToggleAction> ruler_samples_action;
Glib::RefPtr<Gtk::ToggleAction> ruler_minsec_action;
Glib::RefPtr<Gtk::ToggleAction> ruler_tempo_action;
Glib::RefPtr<Gtk::ToggleAction> ruler_timecode_action;
Glib::RefPtr<Gtk::ToggleAction> ruler_samples_action;
Glib::RefPtr<Gtk::ToggleAction> ruler_bbt_action;
Glib::RefPtr<Gtk::ToggleAction> ruler_meter_action;
Glib::RefPtr<Gtk::ToggleAction> ruler_marker_action;
Glib::RefPtr<Gtk::ToggleAction> ruler_tempo_action;
Glib::RefPtr<Gtk::ToggleAction> ruler_range_action;
Glib::RefPtr<Gtk::ToggleAction> ruler_loop_punch_action;
Glib::RefPtr<Gtk::ToggleAction> ruler_cd_marker_action;
Glib::RefPtr<Gtk::ToggleAction> ruler_marker_action;
Glib::RefPtr<Gtk::ToggleAction> ruler_cue_marker_action;
bool no_ruler_shown_update;

View File

@ -700,17 +700,17 @@ Editor::register_actions ()
/* RULERS */
Glib::RefPtr<ActionGroup> ruler_actions = ActionManager::create_action_group (bindings, X_("Rulers"));
ruler_tempo_action = Glib::RefPtr<ToggleAction>::cast_static (ActionManager::register_toggle_action (ruler_actions, X_("toggle-tempo-ruler"), _("Tempo"), sigc::mem_fun(*this, &Editor::toggle_ruler_visibility)));
ruler_meter_action = Glib::RefPtr<ToggleAction>::cast_static (ActionManager::register_toggle_action (ruler_actions, X_("toggle-meter-ruler"), _("Time Signature"), sigc::mem_fun(*this, &Editor::toggle_ruler_visibility)));
ruler_range_action = Glib::RefPtr<ToggleAction>::cast_static (ActionManager::register_toggle_action (ruler_actions, X_("toggle-range-ruler"), _("Range Markers"), sigc::mem_fun(*this, &Editor::toggle_ruler_visibility)));
ruler_marker_action = Glib::RefPtr<ToggleAction>::cast_static (ActionManager::register_toggle_action (ruler_actions, X_("toggle-marker-ruler"), _("Location Markers"), sigc::mem_fun(*this, &Editor::toggle_ruler_visibility)));
ruler_cd_marker_action = Glib::RefPtr<ToggleAction>::cast_static (ActionManager::register_toggle_action (ruler_actions, X_("toggle-cd-marker-ruler"), _("CD Markers"), sigc::mem_fun(*this, &Editor::toggle_ruler_visibility)));
ruler_cue_marker_action = Glib::RefPtr<ToggleAction>::cast_static (ActionManager::register_toggle_action (ruler_actions, X_("toggle-cue-marker-ruler"), _("Cue Markers"), sigc::mem_fun(*this, &Editor::toggle_ruler_visibility)));
ruler_loop_punch_action = Glib::RefPtr<ToggleAction>::cast_static (ActionManager::register_toggle_action (ruler_actions, X_("toggle-loop-punch-ruler"), _("Loop/Punch Ranges"), sigc::mem_fun(*this, &Editor::toggle_ruler_visibility)));
ruler_bbt_action = Glib::RefPtr<ToggleAction>::cast_static (ActionManager::register_toggle_action (ruler_actions, X_("toggle-bbt-ruler"), _("Bars:Beats"), sigc::mem_fun(*this, &Editor::toggle_ruler_visibility)));
ruler_samples_action = Glib::RefPtr<ToggleAction>::cast_static (ActionManager::register_toggle_action (ruler_actions, X_("toggle-samples-ruler"), _("Samples"), sigc::mem_fun(*this, &Editor::toggle_ruler_visibility)));
ruler_timecode_action = Glib::RefPtr<ToggleAction>::cast_static (ActionManager::register_toggle_action (ruler_actions, X_("toggle-timecode-ruler"), _("Timecode"), sigc::mem_fun(*this, &Editor::toggle_ruler_visibility)));
ruler_minsec_action = Glib::RefPtr<ToggleAction>::cast_static (ActionManager::register_toggle_action (ruler_actions, X_("toggle-minsec-ruler"), _("Mins:Secs"), sigc::mem_fun(*this, &Editor::toggle_ruler_visibility)));
ruler_timecode_action = Glib::RefPtr<ToggleAction>::cast_static (ActionManager::register_toggle_action (ruler_actions, X_("toggle-timecode-ruler"), _("Timecode"), sigc::mem_fun(*this, &Editor::toggle_ruler_visibility)));
ruler_samples_action = Glib::RefPtr<ToggleAction>::cast_static (ActionManager::register_toggle_action (ruler_actions, X_("toggle-samples-ruler"), _("Samples"), sigc::mem_fun(*this, &Editor::toggle_ruler_visibility)));
ruler_bbt_action = Glib::RefPtr<ToggleAction>::cast_static (ActionManager::register_toggle_action (ruler_actions, X_("toggle-bbt-ruler"), _("Bars:Beats"), sigc::mem_fun(*this, &Editor::toggle_ruler_visibility)));
ruler_meter_action = Glib::RefPtr<ToggleAction>::cast_static (ActionManager::register_toggle_action (ruler_actions, X_("toggle-meter-ruler"), _("Time Signature"), sigc::mem_fun(*this, &Editor::toggle_ruler_visibility)));
ruler_tempo_action = Glib::RefPtr<ToggleAction>::cast_static (ActionManager::register_toggle_action (ruler_actions, X_("toggle-tempo-ruler"), _("Tempo"), sigc::mem_fun(*this, &Editor::toggle_ruler_visibility)));
ruler_range_action = Glib::RefPtr<ToggleAction>::cast_static (ActionManager::register_toggle_action (ruler_actions, X_("toggle-range-ruler"), _("Range Markers"), sigc::mem_fun(*this, &Editor::toggle_ruler_visibility)));
ruler_loop_punch_action = Glib::RefPtr<ToggleAction>::cast_static (ActionManager::register_toggle_action (ruler_actions, X_("toggle-loop-punch-ruler"), _("Loop/Punch Ranges"), sigc::mem_fun(*this, &Editor::toggle_ruler_visibility)));
ruler_cd_marker_action = Glib::RefPtr<ToggleAction>::cast_static (ActionManager::register_toggle_action (ruler_actions, X_("toggle-cd-marker-ruler"), _("CD Markers"), sigc::mem_fun(*this, &Editor::toggle_ruler_visibility)));
ruler_marker_action = Glib::RefPtr<ToggleAction>::cast_static (ActionManager::register_toggle_action (ruler_actions, X_("toggle-marker-ruler"), _("Location Markers"), sigc::mem_fun(*this, &Editor::toggle_ruler_visibility)));
ruler_cue_marker_action = Glib::RefPtr<ToggleAction>::cast_static (ActionManager::register_toggle_action (ruler_actions, X_("toggle-cue-marker-ruler"), _("Cue Markers"), sigc::mem_fun(*this, &Editor::toggle_ruler_visibility)));
ActionManager::register_action (editor_menu_actions, X_("VideoMonitorMenu"), _("Video Monitor"));
@ -729,17 +729,17 @@ Editor::register_actions ()
no_ruler_shown_update = true;
ruler_marker_action->set_active (true);
ruler_minsec_action->set_active (false);
ruler_timecode_action->set_active (true);
ruler_samples_action->set_active (false);
ruler_bbt_action->set_active (true);
ruler_meter_action->set_active (true);
ruler_tempo_action->set_active (true);
ruler_range_action->set_active (true);
ruler_loop_punch_action->set_active (true);
ruler_loop_punch_action->set_active (true);
ruler_bbt_action->set_active (true);
ruler_cd_marker_action->set_active (true);
ruler_marker_action->set_active (true);
ruler_cue_marker_action->set_active (true);
ruler_timecode_action->set_active (true);
ruler_minsec_action->set_active (false);
ruler_video_action->set_active (false);
xjadeo_proc_action->set_active (false);
@ -758,7 +758,6 @@ Editor::register_actions ()
xjadeo_letterbox_action->set_sensitive (false);
xjadeo_zoom_100->set_sensitive (false);
ruler_samples_action->set_active (false);
no_ruler_shown_update = false;
/* REGION LIST */

View File

@ -322,16 +322,16 @@ Editor::store_ruler_visibility ()
{
XMLNode* node = new XMLNode(X_("RulerVisibility"));
node->set_property (X_("timecode"), ruler_timecode_action->get_active());
node->set_property (X_("bbt"), ruler_bbt_action->get_active());
node->set_property (X_("samples"), ruler_samples_action->get_active());
node->set_property (X_("minsec"), ruler_minsec_action->get_active());
node->set_property (X_("tempo"), ruler_tempo_action->get_active());
node->set_property (X_("timecode"), ruler_timecode_action->get_active());
node->set_property (X_("samples"), ruler_samples_action->get_active());
node->set_property (X_("bbt"), ruler_bbt_action->get_active());
node->set_property (X_("meter"), ruler_meter_action->get_active());
node->set_property (X_("marker"), ruler_marker_action->get_active());
node->set_property (X_("tempo"), ruler_tempo_action->get_active());
node->set_property (X_("rangemarker"), ruler_range_action->get_active());
node->set_property (X_("transportmarker"), ruler_loop_punch_action->get_active());
node->set_property (X_("cdmarker"), ruler_cd_marker_action->get_active());
node->set_property (X_("marker"), ruler_marker_action->get_active());
node->set_property (X_("cuemarker"), ruler_cue_marker_action->get_active());
node->set_property (X_("videotl"), ruler_video_action->get_active());