mirror of
https://github.com/aseprite/aseprite.git
synced 2025-03-29 19:20:09 +00:00
Fix window resize on Skia/OSX
This commit is contained in:
parent
0a1f492c24
commit
47f493df78
@ -34,8 +34,6 @@ public:
|
||||
OSXWindowImpl* m_impl;
|
||||
OSXWindowDelegate* m_delegate;
|
||||
int m_scale;
|
||||
gfx::Size m_clientSize;
|
||||
gfx::Size m_restoredSize;
|
||||
}
|
||||
- (OSXWindow*)initWithImpl:(OSXWindowImpl*)impl;
|
||||
- (OSXWindowImpl*)impl;
|
||||
|
@ -23,9 +23,6 @@
|
||||
m_scale = 1;
|
||||
|
||||
NSRect rect = NSMakeRect(0, 0, 640, 480);
|
||||
m_clientSize.w = m_restoredSize.w = rect.size.width;
|
||||
m_clientSize.h = m_restoredSize.h = rect.size.height;
|
||||
|
||||
self = [self initWithContentRect:rect
|
||||
styleMask:(NSTitledWindowMask | NSClosableWindowMask |
|
||||
NSMiniaturizableWindowMask | NSResizableWindowMask)
|
||||
@ -68,12 +65,13 @@
|
||||
|
||||
- (gfx::Size)clientSize
|
||||
{
|
||||
return m_clientSize;
|
||||
return gfx::Size([[self contentView] frame].size.width,
|
||||
[[self contentView] frame].size.height);
|
||||
}
|
||||
|
||||
- (gfx::Size)restoredSize
|
||||
{
|
||||
return m_restoredSize;
|
||||
return [self clientSize];
|
||||
}
|
||||
|
||||
@end
|
||||
|
Loading…
x
Reference in New Issue
Block a user