From bf6da57cbdbb14d2ecba3b9cf83bb82988aba83b Mon Sep 17 00:00:00 2001 From: sveith Date: Tue, 7 Apr 2009 22:36:07 +0000 Subject: [PATCH] Added experimental x64 build option for VS2008 --- cmd/launcher/CHotkeyOptions.cpp | 14 +- .../CMSWindowsClientTaskBarReceiver.cpp | 7 +- cmd/synergyc/synergyc.cpp | 8 +- cmd/synergys/synergys.cpp | 6 + vs2008/client/client.vcproj | 154 +++++++++++++++++ vs2008/hook/hook.vcproj | 155 +++++++++++++++++ vs2008/launcher/launcher.vcproj | 162 +++++++++++++++++- vs2008/libsynergy/libsynergy.vcproj | 131 ++++++++++++++ vs2008/server/server.vcproj | 154 +++++++++++++++++ vs2008/synergy-plus.sln | 22 +++ 10 files changed, 797 insertions(+), 16 deletions(-) diff --git a/cmd/launcher/CHotkeyOptions.cpp b/cmd/launcher/CHotkeyOptions.cpp index 5aa981e0..6e882740 100644 --- a/cmd/launcher/CHotkeyOptions.cpp +++ b/cmd/launcher/CHotkeyOptions.cpp @@ -559,7 +559,7 @@ CHotkeyOptions::CConditionDialog::doModal(HWND parent, s_lastGoodCondition = NULL; } int n = DialogBox(s_instance, MAKEINTRESOURCE(IDD_HOTKEY_CONDITION), - parent, dlgProc); + parent, (DLGPROC) dlgProc); condition = s_condition; delete s_lastGoodCondition; @@ -579,8 +579,8 @@ CHotkeyOptions::CConditionDialog::doInit(HWND hwnd) { // subclass edit control HWND child = getItem(hwnd, IDC_HOTKEY_CONDITION_HOTKEY); - s_editWndProc = (WNDPROC)GetWindowLong(child, GWL_WNDPROC); - SetWindowLong(child, GWL_WNDPROC, (LONG)editProc); + s_editWndProc = (WNDPROC)GetWindowLongPtr(child, GWLP_WNDPROC); + SetWindowLongPtr(child, GWLP_WNDPROC, (LONG_PTR) editProc); // fill control fillHotkey(hwnd); @@ -944,7 +944,7 @@ CHotkeyOptions::CActionDialog::doModal(HWND parent, CConfig* config, } int n = DialogBox(s_instance, MAKEINTRESOURCE(IDD_HOTKEY_ACTION), - parent, dlgProc); + parent, (DLGPROC) dlgProc); onActivate = s_onActivate; action = s_action; @@ -960,8 +960,8 @@ CHotkeyOptions::CActionDialog::doInit(HWND hwnd) { // subclass edit control HWND child = getItem(hwnd, IDC_HOTKEY_ACTION_HOTKEY); - s_editWndProc = (WNDPROC)GetWindowLong(child, GWL_WNDPROC); - SetWindowLong(child, GWL_WNDPROC, (LONG)editProc); + s_editWndProc = (WNDPROC)GetWindowLongPtr(child, GWLP_WNDPROC); + SetWindowLongPtr(child, GWLP_WNDPROC, (LONG_PTR)editProc); setWindowText(getItem(hwnd, IDC_HOTKEY_ACTION_HOTKEY), ""); fillHotkey(hwnd); @@ -1734,7 +1734,7 @@ CHotkeyOptions::CScreensDialog::doModal(HWND parent, CConfig* config, s_config = config; s_action = action; DialogBox(s_instance, MAKEINTRESOURCE(IDD_HOTKEY_SCREENS), - parent, dlgProc); + parent, (DLGPROC) dlgProc); s_config = NULL; s_action = NULL; } diff --git a/cmd/synergyc/CMSWindowsClientTaskBarReceiver.cpp b/cmd/synergyc/CMSWindowsClientTaskBarReceiver.cpp index c002b9f1..6f41bc17 100644 --- a/cmd/synergyc/CMSWindowsClientTaskBarReceiver.cpp +++ b/cmd/synergyc/CMSWindowsClientTaskBarReceiver.cpp @@ -325,14 +325,13 @@ CMSWindowsClientTaskBarReceiver::staticDlgProc(HWND hwnd, if (msg == WM_INITDIALOG) { self = reinterpret_cast( reinterpret_cast(lParam)); - SetWindowLong(hwnd, GWL_USERDATA, lParam); + SetWindowLongPtr(hwnd, GWLP_USERDATA, (LONG_PTR) lParam); } else { // get the extra window data and forward the call - LONG data = GetWindowLong(hwnd, GWL_USERDATA); + LONG_PTR data = GetWindowLongPtr(hwnd, GWLP_USERDATA); if (data != 0) { - self = reinterpret_cast( - reinterpret_cast(data)); + self = (CMSWindowsClientTaskBarReceiver*) data; } } diff --git a/cmd/synergyc/synergyc.cpp b/cmd/synergyc/synergyc.cpp index 1a230f0d..45140478 100644 --- a/cmd/synergyc/synergyc.cpp +++ b/cmd/synergyc/synergyc.cpp @@ -713,7 +713,13 @@ parse(int argc, const char* const* argv) } // identify system - LOG((CLOG_INFO "Synergy client %s on %s", kVersion, ARCH->getOSName().c_str())); + LOG((CLOG_INFO "%s Client on %s %s", kAppVersion, ARCH->getOSName().c_str(), ARCH->getPlatformName().c_str())); + +#ifdef WIN32 +#ifdef _AMD64_ + LOG((CLOG_WARN "This is an experimental x64 build of %s. Use it at your own risk.", kApplication)); +#endif +#endif } diff --git a/cmd/synergys/synergys.cpp b/cmd/synergys/synergys.cpp index 46428450..46ebb497 100644 --- a/cmd/synergys/synergys.cpp +++ b/cmd/synergys/synergys.cpp @@ -1040,6 +1040,12 @@ parse(int argc, const char* const* argv) // identify system LOG((CLOG_INFO "%s Server on %s %s", kAppVersion, ARCH->getOSName().c_str(), ARCH->getPlatformName().c_str())); + +#ifdef WIN32 +#ifdef _AMD64_ + LOG((CLOG_WARN "This is an experimental x64 build of %s. Use it at your own risk.", kApplication)); +#endif +#endif } static diff --git a/vs2008/client/client.vcproj b/vs2008/client/client.vcproj index ca25cb65..caf0a222 100644 --- a/vs2008/client/client.vcproj +++ b/vs2008/client/client.vcproj @@ -12,6 +12,9 @@ + @@ -89,6 +92,80 @@ Name="VCPostBuildEventTool" /> + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + @@ -166,6 +169,158 @@ Name="VCPostBuildEventTool" /> + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/vs2008/launcher/launcher.vcproj b/vs2008/launcher/launcher.vcproj index 11f0bdb1..a636d5db 100644 --- a/vs2008/launcher/launcher.vcproj +++ b/vs2008/launcher/launcher.vcproj @@ -12,6 +12,9 @@ + @@ -89,6 +92,80 @@ Name="VCPostBuildEventTool" /> + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + - + + @@ -142,6 +145,134 @@ Name="VCPostBuildEventTool" /> + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/vs2008/server/server.vcproj b/vs2008/server/server.vcproj index b2862524..bad7e1f8 100644 --- a/vs2008/server/server.vcproj +++ b/vs2008/server/server.vcproj @@ -12,6 +12,9 @@ + @@ -90,6 +93,81 @@ Name="VCPostBuildEventTool" /> + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +