A few more fixes to support multiple themes.

This commit is contained in:
Aparajita Fishman
2011-06-04 10:46:29 -07:00
parent fe69142567
commit bd9a6ea150
2 changed files with 7 additions and 3 deletions
+6 -2
View File
@@ -1292,8 +1292,12 @@ var _CPAppBootstrapperActions = nil,
+ (void)blendDidFinishLoading:(CPThemeBlend)aThemeBlend
{
[[CPApplication sharedApplication] setThemeBlend:aThemeBlend];
[CPTheme setDefaultTheme:[CPTheme themeNamed:[CPApplication defaultThemeName]]];
var themeBlends = [CPApp themeBlends];
[themeBlends addObject:aThemeBlend];
if ([themeBlends count] === 1)
[CPTheme setDefaultTheme:[CPTheme themeNamed:[CPApplication defaultThemeName]]];
if (_CPAppThemeURLsToLoad.length === 0)
[self performActions];
+1 -1
View File
@@ -2695,7 +2695,7 @@ var CPViewAutoresizingMaskKey = @"CPViewAutoresizingMask",
[self setupViewFlags];
_theme = [CPTheme defaultTheme];
_theme = [CPTheme themeForView:self];
_themeClass = [aCoder decodeObjectForKey:CPViewThemeClassKey];
_themeState = CPThemeState([aCoder decodeIntForKey:CPViewThemeStateKey]);
_themeAttributes = {};