aboutsummaryrefslogtreecommitdiffstats
path: root/win/vncconfig/Sharing.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 /win/vncconfig/Sharing.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 'win/vncconfig/Sharing.h')
-rw-r--r--win/vncconfig/Sharing.h6
1 files changed, 3 insertions, 3 deletions
diff --git a/win/vncconfig/Sharing.h b/win/vncconfig/Sharing.h
index 73966c9d..a6459e5f 100644
--- a/win/vncconfig/Sharing.h
+++ b/win/vncconfig/Sharing.h
@@ -30,19 +30,19 @@ namespace rfb {
public:
SharingPage(const RegKey& rk)
: PropSheetPage(GetModuleHandle(nullptr), MAKEINTRESOURCE(IDD_SHARING)), regKey(rk) {}
- void initDialog() {
+ void initDialog() override {
setItemChecked(IDC_DISCONNECT_CLIENTS, rfb::Server::disconnectClients);
setItemChecked(IDC_SHARE_NEVER, rfb::Server::neverShared);
setItemChecked(IDC_SHARE_ALWAYS, rfb::Server::alwaysShared);
setItemChecked(IDC_SHARE_CLIENT, !(rfb::Server::neverShared || rfb::Server::alwaysShared));
}
- bool onCommand(int /*id*/, int /*cmd*/) {
+ bool onCommand(int /*id*/, int /*cmd*/) override {
setChanged((isItemChecked(IDC_DISCONNECT_CLIENTS) != rfb::Server::disconnectClients) ||
(isItemChecked(IDC_SHARE_NEVER) != rfb::Server::neverShared) ||
(isItemChecked(IDC_SHARE_ALWAYS) != rfb::Server::alwaysShared));
return true;
}
- bool onOk() {
+ bool onOk() override {
regKey.setBool("DisconnectClients", isItemChecked(IDC_DISCONNECT_CLIENTS));
regKey.setBool("AlwaysShared", isItemChecked(IDC_SHARE_ALWAYS));
regKey.setBool("NeverShared", isItemChecked(IDC_SHARE_NEVER));