summaryrefslogtreecommitdiff
path: root/src/video/cocoa/cocoa_v.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/video/cocoa/cocoa_v.h')
-rw-r--r--src/video/cocoa/cocoa_v.h13
1 files changed, 7 insertions, 6 deletions
diff --git a/src/video/cocoa/cocoa_v.h b/src/video/cocoa/cocoa_v.h
index f9920c20e..0961e1660 100644
--- a/src/video/cocoa/cocoa_v.h
+++ b/src/video/cocoa/cocoa_v.h
@@ -16,13 +16,12 @@
extern bool _cocoa_video_started;
+@class OTTD_CocoaWindowDelegate;
+
class VideoDriver_Cocoa : public VideoDriver {
private:
Dimension orig_res; ///< Saved window size for non-fullscreen mode.
- int device_width; ///< Width of device in pixel
- int device_height; ///< Height of device in pixel
-
int window_width; ///< Current window width in pixel
int window_height; ///< Current window height in pixel
int window_pitch;
@@ -46,6 +45,8 @@ public:
CGColorSpaceRef color_space; ///< Window color space
CGContextRef cgcontext; ///< Context reference for Quartz subdriver
+ OTTD_CocoaWindowDelegate *delegate; //!< Window delegate object
+
public:
VideoDriver_Cocoa();
@@ -69,7 +70,7 @@ public:
/** Main game loop. */
void GameLoop(); // In event.mm.
- bool WindowResized();
+ void AllocateBackingStore();
protected:
Dimension GetScreenSize() const override;
@@ -85,8 +86,8 @@ private:
void GameSizeChanged();
void UpdateVideoModes();
- void GetDeviceInfo();
- bool SetVideoMode(int width, int height, int bpp);
+
+ bool MakeWindow(int width, int height);
void UpdatePalette(uint first_color, uint num_colors);
void CheckPaletteAnim();