Skip to content

Commit

Permalink
GLSupport: OSX - add override annotations
Browse files Browse the repository at this point in the history
  • Loading branch information
paroj committed Nov 1, 2024
1 parent a84db69 commit e90817b
Show file tree
Hide file tree
Showing 3 changed files with 23 additions and 23 deletions.
6 changes: 3 additions & 3 deletions RenderSystems/GLSupport/include/OSX/OgreOSXCocoaContext.h
Original file line number Diff line number Diff line change
Expand Up @@ -43,17 +43,17 @@ namespace Ogre {
virtual ~CocoaContext();

/** See GLContext */
virtual void setCurrent();
void setCurrent() override;
/**
* This is called before another context is made current. By default,
* nothing is done here.
*/
virtual void endCurrent();
void endCurrent() override;
/** Create a new context based on the same window/pbuffer as this
context - mostly useful for additional threads.
@note The caller is responsible for deleting the returned context.
*/
virtual GLContext* clone() const;
GLContext* clone() const override;

/** Grab the NSOpenGLContext if it exists */
NSOpenGLContext* getContext();
Expand Down
28 changes: 14 additions & 14 deletions RenderSystems/GLSupport/include/OSX/OgreOSXCocoaWindow.h
Original file line number Diff line number Diff line change
Expand Up @@ -69,39 +69,39 @@ namespace Ogre {
NSView* ogreView() const { return mView; }
NSWindow* ogreWindow() const { return mWindow; }
NSOpenGLContext* nsopenGLContext() const { return mGLContext; }
GLContext* getContext() const { return mContext; }
GLContext* getContext() const override { return mContext; }
void createWithView(OgreGLView *view);

/** @copydoc see RenderWindow::getViewPointToPixelScale */
float getViewPointToPixelScale();
float getViewPointToPixelScale() override;
/** Overridden - see RenderWindow */
void create(const String& name, unsigned int widthPt, unsigned int heightPt,
bool fullScreen, const NameValuePairList *miscParams);
bool fullScreen, const NameValuePairList *miscParams) override;
/** Overridden - see RenderWindow */
void destroy(void);
void destroy(void) override;
/** @copydoc see RenderWindow::setHidden */
void setHidden(bool hidden);
void setHidden(bool hidden) override;
/** @copydoc see RenderWindow::setVSyncEnabled */
void setVSyncEnabled(bool vsync);
void setVSyncEnabled(bool vsync) override;
/** Overridden - see RenderWindow */
void reposition(int leftPt, int topPt);
void reposition(int leftPt, int topPt) override;
/** Overridden - see RenderWindow */
void resize(unsigned int widthPt, unsigned int heightPt);
void resize(unsigned int widthPt, unsigned int heightPt) override;
/** Overridden - see RenderWindow */
void swapBuffers();
void swapBuffers() override;
/** Overridden - see RenderWindow */
virtual void setFullscreen(bool fullScreen, unsigned int widthPt, unsigned int heightPt);
void setFullscreen(bool fullScreen, unsigned int widthPt, unsigned int heightPt) override;
/** Overridden - see RenderWindow */
virtual unsigned int getWidth(void) const;
unsigned int getWidth(void) const override;
/** Overridden - see RenderWindow */
virtual unsigned int getHeight(void) const;
unsigned int getHeight(void) const override;
/** Overridden - see RenderWindow */
void windowMovedOrResized(void);
void windowMovedOrResized(void) override;
void windowHasResized(void);
void createNewWindow(unsigned int width, unsigned int height, String title);
void createWindowFromExternal(NSView *viewRef);

void getCustomAttribute( const String& name, void* pData );
void getCustomAttribute( const String& name, void* pData ) override;
};
}

Expand Down
12 changes: 6 additions & 6 deletions RenderSystems/GLSupport/include/OSX/OgreOSXGLSupport.h
Original file line number Diff line number Diff line change
Expand Up @@ -41,26 +41,26 @@ class OSXGLSupport : public GLNativeSupport
OSXGLSupport(int profile) : GLNativeSupport(profile) {}
~OSXGLSupport() {}

ConfigOptionMap getConfigOptions();
ConfigOptionMap getConfigOptions() override;

/// @copydoc RenderSystem::createRenderWindow
virtual RenderWindow* newWindow( const String &name, unsigned int width, unsigned int height,
bool fullScreen, const NameValuePairList *miscParams = 0 );
RenderWindow* newWindow( const String &name, unsigned int width, unsigned int height,
bool fullScreen, const NameValuePairList *miscParams = 0 ) override;

/**
* Start anything special
*/
void start();
void start() override;

/**
* Stop anything special
*/
void stop();
void stop() override;

/**
* Get the address of a function
*/
void* getProcAddress( const char *name ) const;
void* getProcAddress( const char *name ) const override;

// Core Foundation Array callback function for sorting, must be static for the function ptr
static CFComparisonResult _compareModes (const void *val1, const void *val2, void *context);
Expand Down

0 comments on commit e90817b

Please sign in to comment.