diff options
-rw-r--r-- | gtk2_ardour/led.cc | 27 | ||||
-rw-r--r-- | gtk2_ardour/route_ui.cc | 1 | ||||
-rw-r--r-- | libs/ardour/route.cc | 2 |
3 files changed, 17 insertions, 13 deletions
diff --git a/gtk2_ardour/led.cc b/gtk2_ardour/led.cc index e1a98da228..645b65e99b 100644 --- a/gtk2_ardour/led.cc +++ b/gtk2_ardour/led.cc @@ -52,21 +52,28 @@ LED::render (cairo_t* cr) //background - RefPtr<Style> style = get_style(); + Widget* parent; + RefPtr<Style> style; Color c; - - switch (_visual_state) { - case 0: - c = style->get_bg (STATE_NORMAL); - break; - default: - c = style->get_bg (STATE_ACTIVE); - break; + + parent = get_parent (); + + while (parent && !parent->get_has_window()) { + parent = parent->get_parent(); + } + + if (parent && parent->get_has_window()) { + style = parent->get_style (); + c = style->get_bg (parent->get_state()); + } else { + style = get_style (); + c = style->get_bg (get_state()); } + cairo_rectangle(cr, 0, 0, _width, _height); cairo_stroke_preserve(cr); - cairo_set_source_rgb(cr, c.get_green_p(), c.get_red_p(), c.get_blue_p()); + cairo_set_source_rgb(cr, c.get_red_p(), c.get_green_p(), c.get_blue_p()); cairo_fill(cr); cairo_translate(cr, _width/2, _height/2); diff --git a/gtk2_ardour/route_ui.cc b/gtk2_ardour/route_ui.cc index 70a87aebac..3bc36da091 100644 --- a/gtk2_ardour/route_ui.cc +++ b/gtk2_ardour/route_ui.cc @@ -818,7 +818,6 @@ RouteUI::update_solo_display () set_button_names (); if (solo_isolated_led) { - cerr << _route->name() << " reset iso vis = " << (_route->solo_isolated() ? 1 : 0) << endl; solo_isolated_led->set_visual_state (_route->solo_isolated() ? 1 : 0); } diff --git a/libs/ardour/route.cc b/libs/ardour/route.cc index 6a9f3c99f5..48eeae7774 100644 --- a/libs/ardour/route.cc +++ b/libs/ardour/route.cc @@ -696,8 +696,6 @@ Route::set_solo_isolated (bool yn, void *src) _route_group->apply (&Route::set_solo_isolated, yn, _route_group); return; } - - cerr << name() << " SET SOLO ISO " << yn << " cur = " << _solo_isolated << endl; /* forward propagate solo-isolate status to everything fed by this route, but not those via sends only */ |