Changed the attribute theme background selected menu bar to _CPMenuView

This commit is contained in:
Alexandre Wilhelm
2013-01-11 17:13:58 -08:00
parent d331de6683
commit 181f7acbb8
4 changed files with 9 additions and 12 deletions
+2 -1
View File
@@ -413,7 +413,7 @@ var STICKY_TIME_INTERVAL = 500;
+ (id)themeAttributes
{
return [CPDictionary dictionaryWithObjects:[ [CPNull null], [CPNull null], [CPNull null], [CPNull null], CGInsetMake(5.0, 1.0, 1.0, 5.0), 16.0,
[CPNull null], [CPNull null], 30.0, 10.0, 10.0, 10.0,
[CPNull null], [CPNull null], [CPNull null], 30.0, 10.0, 10.0, 10.0,
[CPNull null], [CPNull null], [CPNull null], [CPNull null], [CPNull null], [CPNull null], [CPNull null], 28.0, [CPNull null], 1.0,
[CPNull null], [CPNull null], [CPNull null]]
forKeys:[ @"menu-window-more-above-image",
@@ -424,6 +424,7 @@ var STICKY_TIME_INTERVAL = 500;
@"menu-window-scroll-indicator-height",
@"menu-bar-window-background-color",
@"menu-bar-window-background-selected-color",
@"menu-bar-window-font",
@"menu-bar-window-height",
@"menu-bar-window-margin",
+3 -4
View File
@@ -21,9 +21,8 @@
+ (id)themeAttributes
{
return [CPDictionary dictionaryWithObjects:[[CPNull null], [CPNull null], [CPNull null], [CPNull null], 8.0, 3.0, 4.0]
forKeys:[ @"selection-color",
@"submenu-indicator-color",
return [CPDictionary dictionaryWithObjects:[[CPNull null], [CPNull null], [CPNull null], 8.0, 3.0, 4.0]
forKeys:[ @"submenu-indicator-color",
@"menu-item-selection-color",
@"menu-item-text-shadow-color",
@"horizontal-margin",
@@ -142,7 +141,7 @@
if (shouldHighlight)
{
if (![_menuItem _isMenuBarButton])
[self setBackgroundColor:[self valueForThemeAttribute:@"selection-color"]];
[self setBackgroundColor:[[CPTheme defaultTheme] valueForAttributeWithName:@"menu-bar-window-background-selected-color" forClass:_CPMenuView]];
[_imageAndTextView setImage:[_menuItem alternateImage] || [_menuItem image]];
[_imageAndTextView setTextColor:[CPColor whiteColor]];
+2 -3
View File
@@ -2494,11 +2494,8 @@ var themedButtonValues = nil,
{
var menuItemMenuBarView = [[_CPMenuItemMenuBarView alloc] initWithFrame:CGRectMake(0.0, 0.0, 16.0, 16.0)],
selectionColor = PatternColor(@"menu-bar-window-background-selected.png", 1.0, 28.0),
themeValues =
[
[@"selection-color", selectionColor],
[@"submenu-indicator-color", [CPColor grayColor]],
[@"menu-item-selection-color", [CPColor colorWithHexString:@"5C85D8"]],
[@"menu-item-text-shadow-color", [CPColor colorWithCalibratedRed:26.0 / 255.0 green: 73.0 / 255.0 blue:109.0 / 255.0 alpha:1.0]],
@@ -2586,6 +2583,7 @@ var themedButtonValues = nil,
),
menuBarWindowBackgroundColor = PatternColor(@"menu-bar-window-background.png", 1.0, 28.0),
menuBarWindowBackgroundSelectedColor = PatternColor(@"menu-bar-window-background-selected.png", 1.0, 28.0),
themeValues =
[
@@ -2597,6 +2595,7 @@ var themedButtonValues = nil,
[@"menu-window-scroll-indicator-height", 16.0],
[@"menu-bar-window-background-color", menuBarWindowBackgroundColor],
[@"menu-bar-window-background-selected-color", menuBarWindowBackgroundSelectedColor],
[@"menu-bar-window-font", [CPFont boldSystemFontOfSize:[CPFont systemFontSize]]],
[@"menu-bar-window-height", 28.0],
[@"menu-bar-window-margin", 10.0],
+2 -4
View File
@@ -2226,11 +2226,8 @@ var themedButtonValues = nil,
{
var menuItemMenuBarView = [[_CPMenuItemMenuBarView alloc] initWithFrame:CGRectMake(0.0, 0.0, 16.0, 16.0)],
selectionColor = PatternColor(@"menu-bar-window-background-selected.png", 1.0, 28.0),
themeValues =
[
[@"selection-color", selectionColor],
[@"submenu-indicator-color", [CPColor grayColor]],
[@"menu-item-selection-color", [CPColor colorWithHexString:@"5C85D8"]],
[@"menu-item-text-shadow-color", [CPColor colorWithCalibratedRed:26.0 / 255.0 green: 73.0 / 255.0 blue:109.0 / 255.0 alpha:1.0]],
@@ -2279,7 +2276,6 @@ var themedButtonValues = nil,
{
var menuView = [[_CPMenuView alloc] initWithFrame:CGRectMake(0.0, 0.0, 200.0, 100.0)],
menuWindowMoreAboveImage = PatternImage(@"menu-window-more-above.png", 38.0, 18.0),
menuWindowMoreBelowImage = PatternImage(@"menu-window-more-below.png", 38.0, 18.0),
generalIconNew = PatternImage(@"menu-general-icon-new.png", 16.0, 16.0),
@@ -2318,6 +2314,7 @@ var themedButtonValues = nil,
),
menuBarWindowBackgroundColor = PatternColor(@"menu-bar-window-background.png", 1.0, 30.0),
menuBarWindowBackgroundSelectedColor = PatternColor(@"menu-bar-window-background-selected.png", 1.0, 30.0),
themeValues =
[
@@ -2329,6 +2326,7 @@ var themedButtonValues = nil,
[@"menu-window-scroll-indicator-height", 16.0],
[@"menu-bar-window-background-color", menuBarWindowBackgroundColor],
[@"menu-bar-window-background-selected-color", menuBarWindowBackgroundSelectedColor],
[@"menu-bar-window-font", [CPFont boldSystemFontOfSize:[CPFont systemFontSize]]],
[@"menu-bar-window-height", 30.0],
[@"menu-bar-window-margin", 10.0],