Add theme for CPLevelIndicator

This commit is contained in:
Antoine Mercadal
2013-01-08 17:05:58 -08:00
parent b82225e279
commit 911df72aeb
16 changed files with 55 additions and 0 deletions
Binary file not shown.

After

Width:  |  Height:  |  Size: 75 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 106 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 108 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 143 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 172 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 194 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 108 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 126 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 131 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 146 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 173 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 195 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 147 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 172 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 189 B

+55
View File
@@ -1717,6 +1717,61 @@ var themedButtonValues = nil,
return box;
}
+ (CPLevelIndicator)themedLevelIndicator
{
var levelIndicator = [[CPLevelIndicator alloc] initWithFrame:CGRectMake(0,0,100,100)],
bezelColor = PatternColor(
[
[@"level-indicator-bezel-left.png", 3.0, 18.0],
[@"level-indicator-bezel-center.png", 1.0, 18.0],
[@"level-indicator-bezel-right.png", 3.0, 18.0]
]),
emptyColor = PatternColor(
[
[@"level-indicator-segment-empty-left.png", 3.0, 17.0],
[@"level-indicator-segment-empty-center.png", 1.0, 17.0],
[@"level-indicator-segment-empty-right.png", 3.0, 17.0]
]),
normalColor = PatternColor(
[
[@"level-indicator-segment-normal-left.png", 3.0, 17.0],
[@"level-indicator-segment-normal-center.png", 1.0, 17.0],
[@"level-indicator-segment-normal-right.png", 3.0, 17.0]
]),
warningColor = PatternColor(
[
[@"level-indicator-segment-warning-left.png", 3.0, 17.0],
[@"level-indicator-segment-warning-center.png", 1.0, 17.0],
[@"level-indicator-segment-warning-right.png", 3.0, 17.0]
]),
criticalColor = PatternColor(
[
[@"level-indicator-segment-critical-left.png", 3.0, 17.0],
[@"level-indicator-segment-critical-center.png", 1.0, 17.0],
[@"level-indicator-segment-critical-right.png", 3.0, 17.0]
]);
themeValues =
[
[@"bezel-color", bezelColor],
[@"color-empty", emptyColor],
[@"color-normal", normalColor],
[@"color-warning", warningColor],
[@"color-critical", criticalColor],
[@"spacing", 1.0]
];
[self registerThemeValues:themeValues forView:levelIndicator];
return levelIndicator;
}
+ (_CPHUDWindowView)themedHUDWindowView
{