update some calls to use new get_preferred_edit_position; needs testing

This commit is contained in:
Ben Loftis 2015-04-21 10:16:00 -05:00
parent e2afdb21c3
commit eafb66d001
5 changed files with 11 additions and 7 deletions

View File

@ -97,6 +97,7 @@
typedef uint64_t microseconds_t;
#include "about.h"
#include "editing.h"
#include "actions.h"
#include "add_route_dialog.h"
#include "ambiguous_file_dialog.h"
@ -152,6 +153,7 @@ using namespace PBD;
using namespace Gtkmm2ext;
using namespace Gtk;
using namespace std;
using namespace Editing;
ARDOUR_UI *ARDOUR_UI::theArdourUI = 0;
@ -2354,7 +2356,7 @@ ARDOUR_UI::update_clocks ()
if (!_session) return;
if (editor && !editor->dragging_playhead()) {
Clock (_session->audible_frame(), false, editor->get_preferred_edit_position (true)); /* EMIT_SIGNAL */
Clock (_session->audible_frame(), false, editor->get_preferred_edit_position (EDIT_IGNORE_PHEAD)); /* EMIT_SIGNAL */
}
}
@ -4405,13 +4407,13 @@ void
ARDOUR_UI::update_transport_clocks (framepos_t pos)
{
if (ui_config->get_primary_clock_delta_edit_cursor()) {
primary_clock->set (pos, false, editor->get_preferred_edit_position (true));
primary_clock->set (pos, false, editor->get_preferred_edit_position (EDIT_IGNORE_PHEAD));
} else {
primary_clock->set (pos);
}
if (ui_config->get_secondary_clock_delta_edit_cursor()) {
secondary_clock->set (pos, false, editor->get_preferred_edit_position (true));
secondary_clock->set (pos, false, editor->get_preferred_edit_position (EDIT_IGNORE_PHEAD));
} else {
secondary_clock->set (pos);
}

View File

@ -1751,10 +1751,10 @@ Editor::select_all_selectables_using_edit (bool after)
list<Selectable *> touched;
if (after) {
start = get_preferred_edit_position(false, true);
start = get_preferred_edit_position(EDIT_IGNORE_NONE, true);
end = _session->current_end_frame();
} else {
if ((end = get_preferred_edit_position(false, true)) > 1) {
if ((end = get_preferred_edit_position(EDIT_IGNORE_NONE, true)) > 1) {
start = 0;
end -= 1;
} else {

View File

@ -73,7 +73,7 @@ MainClock::absolute_time () const
{
if (get_is_duration ()) {
// delta to edit cursor
return current_time () + PublicEditor::instance().get_preferred_edit_position (true);
return current_time () + PublicEditor::instance().get_preferred_edit_position (Editing::EDIT_IGNORE_PHEAD);
} else {
return current_time ();
}

View File

@ -88,7 +88,7 @@ StepEditor::start_step_editing ()
void
StepEditor::resync_step_edit_position ()
{
step_edit_insert_position = _editor.get_preferred_edit_position (false, false, true);
step_edit_insert_position = _editor.get_preferred_edit_position (Editing::EDIT_IGNORE_NONE, false, true);
}
void

View File

@ -300,6 +300,8 @@ TempoDialog::tap_tempo_button_press (GdkEventButton *ev)
tapped = true;
}
last_tap = now;
return true;
}
bool