diff options
author | Doug McLain <doug@nostar.net> | 2007-06-15 22:08:27 +0000 |
---|---|---|
committer | Doug McLain <doug@nostar.net> | 2007-06-15 22:08:27 +0000 |
commit | 789cbb21810802adc478de3134fa42950c5e8569 (patch) | |
tree | 565760bb936fea79f18697f72126111169bebae1 /gtk2_ardour/time_axis_view.cc | |
parent | cd9fdb935f08966cc8c7170a39870e8adcae69d8 (diff) |
Major Theme Manager changes, see ardour-dev
git-svn-id: svn://localhost/ardour2/trunk@1987 d708f5d6-7413-0410-9779-e7cbd77b26cf
Diffstat (limited to 'gtk2_ardour/time_axis_view.cc')
-rw-r--r-- | gtk2_ardour/time_axis_view.cc | 54 |
1 files changed, 31 insertions, 23 deletions
diff --git a/gtk2_ardour/time_axis_view.cc b/gtk2_ardour/time_axis_view.cc index 63ff062268..b2121b26fb 100644 --- a/gtk2_ardour/time_axis_view.cc +++ b/gtk2_ardour/time_axis_view.cc @@ -152,7 +152,7 @@ TimeAxisView::TimeAxisView (ARDOUR::Session& sess, PublicEditor& ed, TimeAxisVie controls_frame.set_name ("TimeAxisViewControlsBaseUnselected"); controls_frame.set_shadow_type (Gtk::SHADOW_ETCHED_OUT); - ColorChanged.connect (mem_fun (*this, &TimeAxisView::color_handler)); + ColorsChanged.connect (mem_fun (*this, &TimeAxisView::color_handler)); } TimeAxisView::~TimeAxisView() @@ -787,20 +787,20 @@ TimeAxisView::get_selection_rect (uint32_t id) rect->rect->property_y1() = 0.0; rect->rect->property_x2() = 0.0; rect->rect->property_y2() = 0.0; - rect->rect->property_fill_color_rgba() = color_map[cSelectionRectFill]; - rect->rect->property_outline_color_rgba() = color_map[cSelectionRectOutline]; + rect->rect->property_fill_color_rgba() = Config->canvasvar_SelectionRect.get(); + rect->rect->property_outline_color_rgba() = Config->canvasvar_Selection.get(); rect->start_trim = new SimpleRect (*selection_group); rect->start_trim->property_x1() = 0.0; rect->start_trim->property_x2() = 0.0; - rect->start_trim->property_fill_color_rgba() = color_map[cSelectionStartFill]; - rect->start_trim->property_outline_color_rgba() = color_map[cSelectionStartOutline]; + rect->start_trim->property_fill_color_rgba() = Config->canvasvar_Selection.get(); + rect->start_trim->property_outline_color_rgba() = Config->canvasvar_Selection.get(); rect->end_trim = new SimpleRect (*selection_group); rect->end_trim->property_x1() = 0.0; rect->end_trim->property_x2() = 0.0; - rect->end_trim->property_fill_color_rgba() = color_map[cSelectionEndFill]; - rect->end_trim->property_outline_color_rgba() = color_map[cSelectionEndOutline]; + rect->end_trim->property_fill_color_rgba() = Config->canvasvar_Selection.get(); + rect->end_trim->property_outline_color_rgba() = Config->canvasvar_Selection.get(); free_selection_rects.push_front (rect); @@ -1056,23 +1056,31 @@ TimeAxisView::hide_name_entry () } void -TimeAxisView::color_handler (ColorID id, uint32_t val) +TimeAxisView::color_handler () { - switch (id) { - case cSelectionRectFill: - break; - case cSelectionRectOutline: - break; - case cSelectionStartFill: - break; - case cSelectionStartOutline: - break; - case cSelectionEndFill: - break; - case cSelectionEndOutline: - break; - default: - break; + + for (list<SelectionRect*>::iterator i = used_selection_rects.begin(); i != used_selection_rects.end(); ++i) { + + (*i)->rect->property_fill_color_rgba() = Config->canvasvar_SelectionRect.get(); + (*i)->rect->property_outline_color_rgba() = Config->canvasvar_Selection.get(); + + (*i)->start_trim->property_fill_color_rgba() = Config->canvasvar_Selection.get(); + (*i)->start_trim->property_outline_color_rgba() = Config->canvasvar_Selection.get(); + + (*i)->end_trim->property_fill_color_rgba() = Config->canvasvar_Selection.get(); + (*i)->end_trim->property_outline_color_rgba() = Config->canvasvar_Selection.get(); + } + + for (list<SelectionRect*>::iterator i = free_selection_rects.begin(); i != free_selection_rects.end(); ++i) { + + (*i)->rect->property_fill_color_rgba() = Config->canvasvar_SelectionRect.get(); + (*i)->rect->property_outline_color_rgba() = Config->canvasvar_Selection.get(); + + (*i)->start_trim->property_fill_color_rgba() = Config->canvasvar_Selection.get(); + (*i)->start_trim->property_outline_color_rgba() = Config->canvasvar_Selection.get(); + + (*i)->end_trim->property_fill_color_rgba() = Config->canvasvar_Selection.get(); + (*i)->end_trim->property_outline_color_rgba() = Config->canvasvar_Selection.get(); } } |