Fixed bug with hud style

This commit is contained in:
Alexandre Wilhelm committed 2013-01-24 11:51:06 -08:00
1 parent 3eca24ed58
commit 58d069ed7d
1 file changed
+5 -3
+5 -3
View File
@@ -288,6 +288,8 @@ var CPProgressIndicatorSpinningStyleColors = nil;
_style = aStyle;
[self setTheme:(_style === CPProgressIndicatorHUDBarStyle) ? [CPTheme defaultHudTheme] : [CPTheme defaultTheme]];
[self updateBackgroundColor];
}
@@ -404,16 +406,16 @@ var CPProgressIndicatorSpinningStyleColors = nil;
else
{
// TODO: HUD theme
[self setBackgroundColor:[self valueForThemeAttribute:@"bezel-color"]];
[self setBackgroundColor:[self currentValueForThemeAttribute:@"bezel-color"]];
var barView = [self layoutEphemeralSubviewNamed:"bar-view"
positioned:CPWindowBelow
relativeToEphemeralSubviewNamed:nil];
if (_isIndeterminate)
[barView setBackgroundColor:[self valueForThemeAttribute:@"inderterminate-bar-color"]];
[barView setBackgroundColor:[self currentValueForThemeAttribute:@"inderterminate-bar-color"]];
else
[barView setBackgroundColor:[self valueForThemeAttribute:@"bar-color"]];
[barView setBackgroundColor:[self currentValueForThemeAttribute:@"bar-color"]];
}
}