summaryrefslogtreecommitdiff
path: root/gtk2_ardour/route_time_axis.cc
diff options
context:
space:
mode:
Diffstat (limited to 'gtk2_ardour/route_time_axis.cc')
-rw-r--r--gtk2_ardour/route_time_axis.cc25
1 files changed, 11 insertions, 14 deletions
diff --git a/gtk2_ardour/route_time_axis.cc b/gtk2_ardour/route_time_axis.cc
index dd75113f68..237a39bba3 100644
--- a/gtk2_ardour/route_time_axis.cc
+++ b/gtk2_ardour/route_time_axis.cc
@@ -193,7 +193,7 @@ RouteTimeAxisView::RouteTimeAxisView (PublicEditor& ed, Session& sess, boost::sh
}
editor.ZoomChanged.connect (mem_fun(*this, &RouteTimeAxisView::reset_samples_per_unit));
- ColorChanged.connect (mem_fun (*this, &RouteTimeAxisView::color_handler));
+ ColorsChanged.connect (mem_fun (*this, &RouteTimeAxisView::color_handler));
}
RouteTimeAxisView::~RouteTimeAxisView ()
@@ -594,8 +594,8 @@ RouteTimeAxisView::show_timestretch (nframes_t start, nframes_t end)
timestretch_rect->property_y1() = 0.0;
timestretch_rect->property_x2() = 0.0;
timestretch_rect->property_y2() = 0.0;
- timestretch_rect->property_fill_color_rgba() = color_map[cTimeStretchFill];
- timestretch_rect->property_outline_color_rgba() = color_map[cTimeStretchOutline];
+ timestretch_rect->property_fill_color_rgba() = ARDOUR_UI::config()->canvasvar_TimeStretchFill.get();
+ timestretch_rect->property_outline_color_rgba() = ARDOUR_UI::config()->canvasvar_TimeStretchOutline.get();
}
timestretch_rect->show ();
@@ -1359,17 +1359,14 @@ RouteTimeAxisView::map_frozen ()
}
void
-RouteTimeAxisView::color_handler (ColorID id, uint32_t val)
+RouteTimeAxisView::color_handler ()
{
- switch (id) {
- case cTimeStretchOutline:
- timestretch_rect->property_outline_color_rgba() = val;
- break;
- case cTimeStretchFill:
- timestretch_rect->property_fill_color_rgba() = val;
- break;
- default:
- break;
+ if (timestretch_rect) {
+ timestretch_rect->property_outline_color_rgba() = ARDOUR_UI::config()->canvasvar_TimeStretchOutline.get();
+ }
+
+ if (timestretch_rect) {
+ timestretch_rect->property_fill_color_rgba() = ARDOUR_UI::config()->canvasvar_TimeStretchFill.get();
}
}
@@ -1541,7 +1538,7 @@ RouteTimeAxisView::add_redirect_automation_curve (boost::shared_ptr<Redirect> re
*redirect, what, _session, *ran->view,
*ran->view->canvas_display, redirect->automation_list (what));
- ral->set_line_color (color_map[cRedirectAutomationLine]);
+ ral->set_line_color (ARDOUR_UI::config()->canvasvar_RedirectAutomationLine.get());
ral->queue_reset ();
ran->view->add_line (*ral);