Fix dragging window from non-retina to retina display.

This commit is contained in:
bruvzg 2018-03-22 18:24:09 +02:00
parent cc34406b5d
commit 14597dc2b2
No known key found for this signature in database
GPG Key ID: 89DD917D9CE4218D
1 changed files with 1 additions and 0 deletions

View File

@ -263,6 +263,7 @@ static Vector2 get_mouse_pos(NSEvent *event) {
NSWindow *window = (NSWindow *)[notification object]; NSWindow *window = (NSWindow *)[notification object];
CGFloat newBackingScaleFactor = [window backingScaleFactor]; CGFloat newBackingScaleFactor = [window backingScaleFactor];
CGFloat oldBackingScaleFactor = [[[notification userInfo] objectForKey:@"NSBackingPropertyOldScaleFactorKey"] doubleValue]; CGFloat oldBackingScaleFactor = [[[notification userInfo] objectForKey:@"NSBackingPropertyOldScaleFactorKey"] doubleValue];
[OS_OSX::singleton->window_view setWantsBestResolutionOpenGLSurface:YES];
if (newBackingScaleFactor != oldBackingScaleFactor) { if (newBackingScaleFactor != oldBackingScaleFactor) {
//Set new display scale and window size //Set new display scale and window size