more show() stuff, and replaced strip->show_all(); untill its actually finished
[ardour.git] / gtk2_ardour / audio_streamview.cc
index 573ed0cebaf19353b5b566691df113b7d33fae75..1e66b29321494a9f6e8e5ca289a111277b0e332d 100644 (file)
@@ -47,7 +47,6 @@
 #include "rgb_macros.h"
 #include "gui_thread.h"
 #include "utils.h"
-#include "color.h"
 
 #include "i18n.h"
 
@@ -64,12 +63,12 @@ AudioStreamView::AudioStreamView (AudioTimeAxisView& tv)
        _waveform_shape = Traditional;
        
        if (tv.is_track())
-               stream_base_color = color_map[cAudioTrackBase];
+               stream_base_color = ARDOUR_UI::config()->canvasvar_AudioTrackBase.get();
        else
-               stream_base_color = color_map[cAudioBusBase];
+               stream_base_color = ARDOUR_UI::config()->canvasvar_AudioBusBase.get();
        
        canvas_rect->property_fill_color_rgba() = stream_base_color;
-       canvas_rect->property_outline_color_rgba() = color_map[cAudioTrackOutline];
+       canvas_rect->property_outline_color_rgba() = RGBA_BLACK;
 
        _amplitude_above_axis = 1.0;
 
@@ -520,12 +519,12 @@ AudioStreamView::setup_rec_box ()
                        switch (_trackview.audio_track()->mode()) {
                        case Normal:
                                xend = xstart;
-                               fill_color = color_map[cRecordingRectFill];
+                               fill_color = ARDOUR_UI::config()->canvasvar_RecordingRect.get();
                                break;
 
                        case Destructive:
                                xend = xstart + 2;
-                               fill_color = color_map[cRecordingRectFill];
+                               fill_color = ARDOUR_UI::config()->canvasvar_RecordingRect.get();
                                /* make the recording rect translucent to allow
                                   the user to see the peak data coming in, etc.
                                */
@@ -538,7 +537,7 @@ AudioStreamView::setup_rec_box ()
                        rec_rect->property_y1() = 1.0;
                        rec_rect->property_x2() = xend;
                        rec_rect->property_y2() = (double) _trackview.height - 1;
-                       rec_rect->property_outline_color_rgba() = color_map[cRecordingRectOutline];
+                       rec_rect->property_outline_color_rgba() = ARDOUR_UI::config()->canvasvar_RecordingRect.get();
                        rec_rect->property_fill_color_rgba() = fill_color;
                        rec_rect->lower_to_bottom();
                        
@@ -761,26 +760,18 @@ AudioStreamView::reveal_xfades_involving (AudioRegionView& rv)
 }
 
 void
-AudioStreamView::color_handler (ColorID id, uint32_t val)
+AudioStreamView::color_handler ()
 {
-       switch (id) {
-       case cAudioTrackBase:
-               if (_trackview.is_track()) {
-                       canvas_rect->property_fill_color_rgba() = val;
-               } 
-               break;
-       case cAudioBusBase:
-               if (!_trackview.is_track()) {
-                       canvas_rect->property_fill_color_rgba() = val;
-               }
-               break;
-       case cAudioTrackOutline:
-               canvas_rect->property_outline_color_rgba() = val;
-               break;
+       //case cAudioTrackBase:
+       if (_trackview.is_track()) {
+               canvas_rect->property_fill_color_rgba() = ARDOUR_UI::config()->canvasvar_AudioTrackBase.get();
+       } 
 
-       default:
-               break;
+       //case cAudioBusBase:
+       if (!_trackview.is_track()) {
+               canvas_rect->property_fill_color_rgba() = ARDOUR_UI::config()->canvasvar_AudioBusBase.get();
        }
+
 }
 
 void