Logo Search packages:      
Sourcecode: ardour version File versions

void TimeAxisViewItem::set_frame_color (  )  [protected, virtual]

Sets the frame color depending on whether this item is selected

Definition at line 762 of file time_axis_view_item.cc.

References should_show_selection.

Referenced by set_colors(), set_selected(), and set_should_show_selection().

{
      if (frame) {
            uint32_t r,g,b,a;
            
            if (_selected && should_show_selection) {
                  UINT_TO_RGBA(ARDOUR_UI::config()->canvasvar_SelectedFrameBase.get(), &r, &g, &b, &a); 
                  frame->property_fill_color_rgba() = RGBA_TO_UINT(r, g, b, fill_opacity ? fill_opacity : a);// Lets still use the theme's opacity value if Opaque is not set
            } else {
                  if (_recregion) {
                        UINT_TO_RGBA(ARDOUR_UI::config()->canvasvar_RecordingRect.get(), &r, &g, &b, &a);
                        frame->property_fill_color_rgba() = RGBA_TO_UINT(r, g, b, a);
                  } else {
                        UINT_TO_RGBA(ARDOUR_UI::config()->canvasvar_FrameBase.get(), &r, &g, &b, &a);
                        frame->property_fill_color_rgba() = RGBA_TO_UINT(r, g, b, fill_opacity ? fill_opacity : a);
                  }
            }
      }
}


Generated by  Doxygen 1.6.0   Back to index