mirror of https://github.com/OpenTTD/OpenTTD
Codechange: [OSX] Remove old code that has no effect on current OSX versions.
parent
883e21dbb7
commit
37116a7575
|
@ -152,7 +152,6 @@ static bool _allowSoftware;
|
||||||
{
|
{
|
||||||
if (self = [ super initWithFrame:frameRect ]) {
|
if (self = [ super initWithFrame:frameRect ]) {
|
||||||
/* We manage our content updates ourselves. */
|
/* We manage our content updates ourselves. */
|
||||||
self.wantsBestResolutionOpenGLSurface = _allow_hidpi_window ? YES : NO;
|
|
||||||
self.layerContentsRedrawPolicy = NSViewLayerContentsRedrawOnSetNeedsDisplay;
|
self.layerContentsRedrawPolicy = NSViewLayerContentsRedrawOnSetNeedsDisplay;
|
||||||
|
|
||||||
/* Create backing layer. */
|
/* Create backing layer. */
|
||||||
|
|
|
@ -32,7 +32,6 @@ extern NSString *OTTDMainLaunchGameEngine;
|
||||||
@interface OTTD_CocoaWindow : NSWindow
|
@interface OTTD_CocoaWindow : NSWindow
|
||||||
- (instancetype)initWithContentRect:(NSRect)contentRect styleMask:(NSUInteger)styleMask backing:(NSBackingStoreType)backingType defer:(BOOL)flag driver:(VideoDriver_Cocoa *)drv;
|
- (instancetype)initWithContentRect:(NSRect)contentRect styleMask:(NSUInteger)styleMask backing:(NSBackingStoreType)backingType defer:(BOOL)flag driver:(VideoDriver_Cocoa *)drv;
|
||||||
|
|
||||||
- (void)display;
|
|
||||||
- (void)setFrame:(NSRect)frameRect display:(BOOL)flag;
|
- (void)setFrame:(NSRect)frameRect display:(BOOL)flag;
|
||||||
@end
|
@end
|
||||||
|
|
||||||
|
|
|
@ -405,23 +405,6 @@ void CocoaDialog(const char *title, const char *message, const char *buttonLabel
|
||||||
return self;
|
return self;
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
|
||||||
* This method fires just before the window deminaturizes from the Dock.
|
|
||||||
* We'll save the current visible surface, let the window manager redraw any
|
|
||||||
* UI elements, and restore the surface. This way, no expose event
|
|
||||||
* is required, and the deminiaturize works perfectly.
|
|
||||||
*/
|
|
||||||
- (void)display
|
|
||||||
{
|
|
||||||
/* save current visible surface */
|
|
||||||
[ self cacheImageInRect:[ driver->cocoaview frame ] ];
|
|
||||||
|
|
||||||
/* let the window manager redraw controls, border, etc */
|
|
||||||
[ super display ];
|
|
||||||
|
|
||||||
/* restore visible surface */
|
|
||||||
[ self restoreCachedImage ];
|
|
||||||
}
|
|
||||||
/**
|
/**
|
||||||
* Define the rectangle we draw our window in
|
* Define the rectangle we draw our window in
|
||||||
*/
|
*/
|
||||||
|
|
Loading…
Reference in New Issue