OpenClonk
C4DrawGLMac.h
Go to the documentation of this file.
1 /*
2  * OpenClonk, http://www.openclonk.org
3  *
4  * Copyright (c) 2009-2016, The OpenClonk Team and contributors
5  *
6  * Distributed under the terms of the ISC license; see accompanying file
7  * "COPYING" for details.
8  *
9  * "Clonk" is a registered trademark of Matthes Bender, used with permission.
10  * See accompanying file "TRADEMARK" for details.
11  *
12  * To redistribute this file separately, substitute the full license texts
13  * for the above references.
14  */
15 
16 #import <Cocoa/Cocoa.h>
17 #include "platform/C4Window.h"
18 
19 #ifdef USE_COCOA
20 
21 @class C4WindowController;
22 
23 extern int ActualFullscreenX, ActualFullscreenY;
24 
25 @interface C4OpenGLView : NSView
26 {
27 @private
28  NSOpenGLContext* context;
29 }
30 - (C4WindowController*) controller;
31 - (void)update;
32 - (void) enableEvents;
33 - (void) showCursor;
34 - (void) hideCursor;
35 - (BOOL) shouldHideMouseCursor;
36 - (void) setContextSurfaceBackingSizeToOwnDimensions;
37 - (IBAction) increaseZoom:(id)sender;
38 - (IBAction) decreaseZoom:(id)sender;
39 
40 + (CGDirectDisplayID) displayID;
41 + (NSOpenGLContext*) mainContext;
42 + (void) setSurfaceBackingSizeOf:(NSOpenGLContext*) context width:(int)wdt height:(int)hgt;
43 + (NSOpenGLContext*) createContext:(CStdGLCtx*) pMainCtx;
44 
45 @property(readwrite, strong) NSOpenGLContext* context;
46 @end
47 
48 @interface C4EditorOpenGLView: C4OpenGLView
49 {
50 }
51 - (IBAction) grabContents:(id) sender;
52 - (IBAction) copy:(id) sender;
53 - (IBAction) delete:(id) sender;
54 - (IBAction) resetZoom:(id) sender;
55 @end
56 
57 #endif