If the parent view color is B_TRANSPARENT_COLOR,
fallback to ui_color(B_PANEL_BACKGROUND_COLOR) in AttachedToWindow(). Most controls don't paint their background and rely on the app_server painting it. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@26510 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
parent
552580cd28
commit
5fe54dee09
@ -145,6 +145,8 @@ BControl::AttachedToWindow()
|
||||
if (Parent()) {
|
||||
// inherit the color from parent
|
||||
rgb_color color = Parent()->ViewColor();
|
||||
if (color == B_TRANSPARENT_COLOR)
|
||||
color = ui_color(B_PANEL_BACKGROUND_COLOR);
|
||||
|
||||
SetViewColor(color);
|
||||
SetLowColor(color);
|
||||
|
Loading…
Reference in New Issue
Block a user