mirror of
https://github.com/Ardour/ardour.git
synced 2025-12-07 23:35:03 +01:00
refactor zoom focus handling so that all EditingContexts can use the same code
This commit is contained in:
parent
9b22e16bec
commit
0a40b50b86
8 changed files with 115 additions and 82 deletions
|
|
@ -10,7 +10,7 @@ CueEditor::CueEditor (std::string const & name)
|
|||
{
|
||||
_history.Changed.connect (history_connection, invalidator (*this), std::bind (&CueEditor::history_changed, this), gui_context());
|
||||
|
||||
set_zoom_focus (Editing::ZoomFocusMouse);
|
||||
set_zoom_focus (Editing::ZoomFocusLeft);
|
||||
}
|
||||
|
||||
CueEditor::~CueEditor ()
|
||||
|
|
@ -153,6 +153,12 @@ CueEditor::set_zoom_focus (Editing::ZoomFocus zf)
|
|||
return;
|
||||
}
|
||||
|
||||
std::string str = zoom_focus_strings[(int)zf];
|
||||
|
||||
if (str != zoom_focus_selector.get_text()) {
|
||||
zoom_focus_selector.set_text (str);
|
||||
}
|
||||
|
||||
if (_zoom_focus != zf) {
|
||||
_zoom_focus = zf;
|
||||
ZoomFocusChanged (); /* EMIT SIGNAL */
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue