From 8b9b4308e0d25bf72f1e9fd28e91e3453b46518c Mon Sep 17 00:00:00 2001 From: Carl Hetherington Date: Tue, 1 Dec 2009 23:31:02 +0000 Subject: [PATCH] Clean up some confusion about zoom focus and the edit point. git-svn-id: svn://localhost/ardour2/branches/3.0@6261 d708f5d6-7413-0410-9779-e7cbd77b26cf --- gtk2_ardour/ardour.menus.in | 2 +- gtk2_ardour/editor.cc | 34 +++++----------------------------- gtk2_ardour/editor_actions.cc | 2 +- 3 files changed, 7 insertions(+), 31 deletions(-) diff --git a/gtk2_ardour/ardour.menus.in b/gtk2_ardour/ardour.menus.in index afb6647f12..f4995411e7 100644 --- a/gtk2_ardour/ardour.menus.in +++ b/gtk2_ardour/ardour.menus.in @@ -304,8 +304,8 @@ - + diff --git a/gtk2_ardour/editor.cc b/gtk2_ardour/editor.cc index 81e7974eb4..445044f65c 100644 --- a/gtk2_ardour/editor.cc +++ b/gtk2_ardour/editor.cc @@ -171,7 +171,7 @@ static const gchar *_zoom_focus_strings[] = { N_("Center"), N_("Playhead"), N_("Mouse"), - N_("Active Mark"), + N_("Edit point"), 0 }; @@ -2162,26 +2162,6 @@ Editor::set_edit_point_preference (EditPoint ep, bool force) return; } - switch (zoom_focus) { - case ZoomFocusMouse: - case ZoomFocusPlayhead: - case ZoomFocusEdit: - switch (_edit_point) { - case EditAtMouse: - set_zoom_focus (ZoomFocusMouse); - break; - case EditAtPlayhead: - set_zoom_focus (ZoomFocusPlayhead); - break; - case EditAtSelectedMarker: - set_zoom_focus (ZoomFocusEdit); - break; - } - break; - default: - break; - } - const char* action=NULL; switch (_edit_point) { @@ -3548,16 +3528,12 @@ Editor::zoom_focus_selection_done () focus_type = ZoomFocusRight; } else if (choice == _("Center")) { focus_type = ZoomFocusCenter; - } else if (choice == _("Play")) { + } else if (choice == _("Playhead")) { focus_type = ZoomFocusPlayhead; - } else if (choice == _("Edit")) { - focus_type = ZoomFocusEdit; - } else if (choice == _("Active Mark")) { - focus_type = ZoomFocusEdit; - } else if (choice == _("Active Mark")) { - focus_type = ZoomFocusEdit; - } else { + } else if (choice == _("Mouse")) { focus_type = ZoomFocusMouse; + } else if (choice == _("Edit point")) { + focus_type = ZoomFocusEdit; } RefPtr ract = zoom_focus_action (focus_type); diff --git a/gtk2_ardour/editor_actions.cc b/gtk2_ardour/editor_actions.cc index 898edf6041..0ee1de0751 100644 --- a/gtk2_ardour/editor_actions.cc +++ b/gtk2_ardour/editor_actions.cc @@ -655,7 +655,7 @@ Editor::register_actions () ActionManager::session_sensitive_actions.push_back (act); ActionManager::register_radio_action (zoom_actions, zoom_group, "zoom-focus-mouse", _("Zoom Focus Mouse"), bind (mem_fun(*this, &Editor::zoom_focus_chosen), Editing::ZoomFocusMouse)); ActionManager::session_sensitive_actions.push_back (act); - ActionManager::register_radio_action (zoom_actions, zoom_group, "zoom-focus-edit", _("Zoom Focus Edit"), bind (mem_fun(*this, &Editor::zoom_focus_chosen), Editing::ZoomFocusEdit)); + ActionManager::register_radio_action (zoom_actions, zoom_group, "zoom-focus-edit", _("Zoom Focus Edit Point"), bind (mem_fun(*this, &Editor::zoom_focus_chosen), Editing::ZoomFocusEdit)); ActionManager::session_sensitive_actions.push_back (act); Glib::RefPtr mouse_mode_actions = ActionGroup::create (X_("MouseMode"));