Automation selection fixes.
- display selected comtrol points in region gain lines - display selected points in internal edit mode - allow dragging of region gain lines in MouseContent mode
This commit is contained in:
parent
aa1cdd26ca
commit
63269b3063
@ -41,6 +41,7 @@
|
||||
#include "tape_region_view.h"
|
||||
#include "audio_time_axis.h"
|
||||
#include "region_selection.h"
|
||||
#include "region_gain_line.h"
|
||||
#include "selection.h"
|
||||
#include "public_editor.h"
|
||||
#include "ardour_ui.h"
|
||||
@ -471,3 +472,14 @@ AudioStreamView::color_handler ()
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
void
|
||||
AudioStreamView::set_selected_points (PointSelection& points)
|
||||
{
|
||||
for (list<RegionView *>::iterator i = region_views.begin(); i != region_views.end(); ++i) {
|
||||
AudioRegionView* const arv = dynamic_cast<AudioRegionView*>(*i);
|
||||
if (arv && arv->get_gain_line ()) {
|
||||
arv->get_gain_line ()->set_selected_points (points);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -26,6 +26,7 @@
|
||||
#include <boost/weak_ptr.hpp>
|
||||
|
||||
#include "ardour/location.h"
|
||||
#include "point_selection.h"
|
||||
#include "editing.h"
|
||||
#include "streamview.h"
|
||||
|
||||
@ -61,6 +62,7 @@ class AudioStreamView : public StreamView
|
||||
std::pair<std::list<AudioRegionView*>, std::list<AudioRegionView*> > hide_xfades_with (boost::shared_ptr<ARDOUR::AudioRegion> ar);
|
||||
|
||||
RegionView* create_region_view (boost::shared_ptr<ARDOUR::Region>, bool, bool);
|
||||
void set_selected_points (PointSelection&);
|
||||
|
||||
private:
|
||||
void setup_rec_box ();
|
||||
|
@ -948,7 +948,8 @@ AutomationLine::set_selected_points (PointSelection const & points)
|
||||
set_colors ();
|
||||
}
|
||||
|
||||
void AutomationLine::set_colors ()
|
||||
void
|
||||
AutomationLine::set_colors ()
|
||||
{
|
||||
set_line_color (ARDOUR_UI::config()->color ("automation line"));
|
||||
for (vector<ControlPoint*>::iterator i = control_points.begin(); i != control_points.end(); ++i) {
|
||||
|
@ -446,7 +446,8 @@ Editor::button_selection (ArdourCanvas::Item* /*item*/, GdkEvent* event, ItemTyp
|
||||
if (((mouse_mode != MouseObject) &&
|
||||
(mouse_mode != MouseAudition || item_type != RegionItem) &&
|
||||
(mouse_mode != MouseTimeFX || item_type != RegionItem) &&
|
||||
(mouse_mode != MouseDraw)) ||
|
||||
(mouse_mode != MouseDraw) &&
|
||||
(mouse_mode != MouseContent || item_type == RegionItem)) ||
|
||||
((event->type != GDK_BUTTON_PRESS && event->type != GDK_BUTTON_RELEASE) || event->button.button > 3)) {
|
||||
return;
|
||||
}
|
||||
@ -762,6 +763,11 @@ Editor::button_press_handler_1 (ArdourCanvas::Item* item, GdkEvent* event, ItemT
|
||||
}
|
||||
return true;
|
||||
|
||||
case GainLineItem:
|
||||
_drags->set (new LineDrag (this, item), event);
|
||||
return true;
|
||||
break;
|
||||
|
||||
case ControlPointItem:
|
||||
_drags->set (new ControlPointDrag (this, item), event);
|
||||
return true;
|
||||
|
@ -59,6 +59,7 @@
|
||||
|
||||
#include "ardour_ui.h"
|
||||
#include "ardour_button.h"
|
||||
#include "audio_streamview.h"
|
||||
#include "debug.h"
|
||||
#include "global_signals.h"
|
||||
#include "route_time_axis.h"
|
||||
@ -1342,6 +1343,10 @@ RouteTimeAxisView::set_selected_points (PointSelection& points)
|
||||
for (Children::iterator i = children.begin(); i != children.end(); ++i) {
|
||||
(*i)->set_selected_points (points);
|
||||
}
|
||||
AudioStreamView* asv = dynamic_cast<AudioStreamView*>(_view);
|
||||
if (asv) {
|
||||
asv->set_selected_points (points);
|
||||
}
|
||||
}
|
||||
|
||||
void
|
||||
|
Loading…
Reference in New Issue
Block a user