Fixed: issue when initialize with contentRect in CPPlatformWindow

This commit is contained in:
Alexandre Wilhelm committed 2014-10-30 18:04:20 -07:00
1 parent d065a0cbc4
commit be9f5ad951
2 files changed
+2 -2

No files matched your search

+1 -1
View File
@@ -569,7 +569,7 @@ CPTexturedBackgroundWindowMask
var fullPlatformWindowViewClass = [[self class] _windowViewClassForFullPlatformWindowStyleMask:_styleMask],
windowView = [[fullPlatformWindowViewClass alloc] initWithFrame:CGRectMakeZero() styleMask:_styleMask];
if (_platformWindow != [CPPlatformWindow primaryPlatformWindow])
if (_platformWindow != [CPPlatformWindow primaryPlatformWindow] && _platformWindow._hasInitializeInstanceWithWindow)
[_platformWindow setContentRect:[self frame]];
[self _setWindowView:windowView];
+1 -1
View File
@@ -122,9 +122,9 @@ var PrimaryPlatformWindow = NULL;
{
self = [self initWithContentRect:CGRectMakeCopy([aWindow frame])];
_hasInitializeInstanceWithWindow = YES;
[aWindow setPlatformWindow:self];
[aWindow setFullPlatformWindow:YES];
_hasInitializeInstanceWithWindow = YES;
return self;
}