more fixes for drag/lock/copy logic

git-svn-id: svn://localhost/ardour2/branches/2.0-ongoing@3174 d708f5d6-7413-0410-9779-e7cbd77b26cf
This commit is contained in:
Paul Davis 2008-03-24 18:01:31 +00:00
parent ad0fded50d
commit 03260435c9
3 changed files with 13 additions and 8 deletions

View file

@ -1056,13 +1056,11 @@ ARDOUR_UI::parameter_changed (const char* parameter_name)
} else if (PARAM_IS ("send-mtc")) {
ActionManager::map_some_state ("options", "SendMTC", &Configuration::get_send_mtc);
cerr << "Send MMC = " << Config->get_send_mmc() << endl;
} else if (PARAM_IS ("send-mmc")) {
ActionManager::map_some_state ("options", "SendMMC", &Configuration::get_send_mmc);
cerr << "Send MMC = " << Config->get_send_mmc() << endl;
} else if (PARAM_IS ("use-osc")) {
@ -1078,7 +1076,6 @@ ARDOUR_UI::parameter_changed (const char* parameter_name)
} else if (PARAM_IS ("mmc-control")) {
ActionManager::map_some_state ("options", "UseMMC", &Configuration::get_mmc_control);
cerr << "Use MMC = " << Config->get_mmc_control() << endl;
} else if (PARAM_IS ("midi-feedback")) {
ActionManager::map_some_state ("options", "SendMIDIfeedback", &Configuration::get_midi_feedback);

View file

@ -3400,10 +3400,19 @@ Editor::region_drag_motion_callback (ArdourCanvas::Item* item, GdkEvent* event)
}
// printf ("3: pending_region_position= %lu %lu\n", pending_region_position, drag_info.last_frame_position );
bool x_move_allowed = ((drag_info.copy && !drag_info.x_constrained) ||
(!drag_info.x_constrained && (Config->get_edit_mode() != Lock)) ||
(drag_info.x_constrained && (Config->get_edit_mode() == Lock)));
bool x_move_allowed;
if (Config->get_edit_mode() == Lock) {
if (drag_info.copy) {
x_move_allowed = !drag_info.x_constrained;
} else {
/* in locked edit mode, reverse the usual meaning of x_constrained */
x_move_allowed = drag_info.x_constrained;
}
} else {
x_move_allowed = !drag_info.x_constrained;
}
if ( pending_region_position != drag_info.last_frame_position && x_move_allowed ) {

View file

@ -687,7 +687,6 @@ Editor::update_ruler_visibility ()
range_marker_group->move (0.0, tbpos - old_unit_pos);
}
range_marker_group->show();
cerr << "range_marker_group now at " << range_marker_group->property_y() << endl;
tbpos += timebar_height;
visible_timebars++;
} else {