aboutsummaryrefslogtreecommitdiffstats
path: root/common/rfb/CConnection.h
diff options
context:
space:
mode:
authorPierre Ossman <ossman@cendio.se>2024-04-03 17:26:03 +0200
committerPierre Ossman <ossman@cendio.se>2024-06-24 13:47:18 +0200
commite3132b406de025ec4ecd612977425c7e7273ecf9 (patch)
tree815ab6630f84810b0e4c9b2c65917287b4e01692 /common/rfb/CConnection.h
parent8530a1bd034feee8bd6e3a436887af187b058f2b (diff)
downloadtigervnc-e3132b406de025ec4ecd612977425c7e7273ecf9.tar.gz
tigervnc-e3132b406de025ec4ecd612977425c7e7273ecf9.zip
Mark overridden virtual functions
Use the new "override" keyword to properly differentiate between new virtual methods, and existing virtual methods being overridden.
Diffstat (limited to 'common/rfb/CConnection.h')
-rw-r--r--common/rfb/CConnection.h44
1 files changed, 21 insertions, 23 deletions
diff --git a/common/rfb/CConnection.h b/common/rfb/CConnection.h
index df0fbb14..dca98a92 100644
--- a/common/rfb/CConnection.h
+++ b/common/rfb/CConnection.h
@@ -97,34 +97,32 @@ namespace rfb {
// Note: These must be called by any deriving classes
- virtual void setDesktopSize(int w, int h);
- virtual void setExtendedDesktopSize(unsigned reason, unsigned result,
- int w, int h,
- const ScreenSet& layout);
+ void setDesktopSize(int w, int h) override;
+ void setExtendedDesktopSize(unsigned reason, unsigned result,
+ int w, int h,
+ const ScreenSet& layout) override;
- virtual void endOfContinuousUpdates();
+ void endOfContinuousUpdates() override;
- virtual void serverInit(int width, int height,
- const PixelFormat& pf,
- const char* name);
+ void serverInit(int width, int height, const PixelFormat& pf,
+ const char* name) override;
- virtual bool readAndDecodeRect(const Rect& r, int encoding,
- ModifiablePixelBuffer* pb);
+ bool readAndDecodeRect(const Rect& r, int encoding,
+ ModifiablePixelBuffer* pb) override;
- virtual void framebufferUpdateStart();
- virtual void framebufferUpdateEnd();
- virtual bool dataRect(const Rect& r, int encoding);
+ void framebufferUpdateStart() override;
+ void framebufferUpdateEnd() override;
+ bool dataRect(const Rect& r, int encoding) override;
- virtual void serverCutText(const char* str);
+ void serverCutText(const char* str) override;
- virtual void handleClipboardCaps(uint32_t flags,
- const uint32_t* lengths);
- virtual void handleClipboardRequest(uint32_t flags);
- virtual void handleClipboardPeek();
- virtual void handleClipboardNotify(uint32_t flags);
- virtual void handleClipboardProvide(uint32_t flags,
- const size_t* lengths,
- const uint8_t* const* data);
+ void handleClipboardCaps(uint32_t flags,
+ const uint32_t* lengths) override;
+ void handleClipboardRequest(uint32_t flags) override;
+ void handleClipboardPeek() override;
+ void handleClipboardNotify(uint32_t flags) override;
+ void handleClipboardProvide(uint32_t flags, const size_t* lengths,
+ const uint8_t* const* data) override;
// Methods to be overridden in a derived class
@@ -249,7 +247,7 @@ namespace rfb {
// responds to requests, stating no support for synchronisation.
// When overriding, call CMsgHandler::fence() directly in order to
// state correct support for fence flags.
- virtual void fence(uint32_t flags, unsigned len, const uint8_t data[]);
+ void fence(uint32_t flags, unsigned len, const uint8_t data[]) override;
private:
bool processVersionMsg();