diff options
author | George Hazan <ghazan@miranda.im> | 2018-06-24 17:06:09 +0300 |
---|---|---|
committer | George Hazan <ghazan@miranda.im> | 2018-06-24 17:06:09 +0300 |
commit | c0bbc949f03f56f4a2fe94b609736075f09f5609 (patch) | |
tree | eae7fd4a110881e4730f224252d9a40985121c0a /plugins | |
parent | 7b81cefb8ec338749b675e948dd2a23226fb073c (diff) |
ProxySwitch:
- correct version resource;
- code cleaning;
- 64-bit adaptation
Diffstat (limited to 'plugins')
-rw-r--r-- | plugins/ProxySwitch/res/Version.rc | 48 | ||||
-rw-r--r-- | plugins/ProxySwitch/src/main.cpp | 23 | ||||
-rw-r--r-- | plugins/ProxySwitch/src/opt.cpp | 2 | ||||
-rw-r--r-- | plugins/ProxySwitch/src/version.h | 10 |
4 files changed, 18 insertions, 65 deletions
diff --git a/plugins/ProxySwitch/res/Version.rc b/plugins/ProxySwitch/res/Version.rc index 37934706a0..5a5ddd63ed 100644 --- a/plugins/ProxySwitch/res/Version.rc +++ b/plugins/ProxySwitch/res/Version.rc @@ -6,50 +6,4 @@ #include "..\src\version.h" -#define APSTUDIO_READONLY_SYMBOLS -#include "afxres.h" -#undef APSTUDIO_READONLY_SYMBOLS - -///////////////////////////////////////////////////////////////////////////// -// English (U.S.) resources - -#if !defined(AFX_RESOURCE_DLL) || defined(AFX_TARG_ENU) -#ifdef _WIN32 -LANGUAGE LANG_ENGLISH, SUBLANG_ENGLISH_US -#pragma code_page(1252) -#endif //_WIN32 - -VS_VERSION_INFO VERSIONINFO - FILEVERSION __FILEVERSION_STRING - PRODUCTVERSION __FILEVERSION_STRING - FILEFLAGSMASK 0x17L -#ifdef _DEBUG - FILEFLAGS 0x1L -#else - FILEFLAGS 0x0L -#endif - FILEOS 0x4L - FILETYPE 0x2L - FILESUBTYPE 0x0L -BEGIN - BLOCK "StringFileInfo" - BEGIN - BLOCK "000004b0" - BEGIN - VALUE "Author", __AUTHOR - VALUE "FileDescription", __DESCRIPTION - VALUE "FileVersion", __VERSION_STRING - VALUE "InternalName", __PLUGIN_NAME - VALUE "LegalCopyright", __COPYRIGHT - VALUE "OriginalFilename", __FILENAME - VALUE "ProductName", __PLUGIN_NAME - END - END - BLOCK "VarFileInfo" - BEGIN - VALUE "Translation", 0x0, 1200 - END -END - -#endif // English (U.S.) resources -///////////////////////////////////////////////////////////////////////////// +#include "..\..\build\Version.rc" diff --git a/plugins/ProxySwitch/src/main.cpp b/plugins/ProxySwitch/src/main.cpp index 93f6328f1e..c02807b19c 100644 --- a/plugins/ProxySwitch/src/main.cpp +++ b/plugins/ProxySwitch/src/main.cpp @@ -69,7 +69,7 @@ static HANDLE hSvcShowMyIP = NULL; /* ################################################################################ */ -static int ShowMyIPAddrs(WPARAM wParam, LPARAM lParam) +static INT_PTR ShowMyIPAddrs(WPARAM, LPARAM) { PopupMyIPAddrs(NULL); return 0; @@ -102,7 +102,7 @@ void PopupMyIPAddrs(wchar_t *msg) } } -static int ProxyEnable(WPARAM wParam, LPARAM lParam) +static INT_PTR ProxyEnable(WPARAM, LPARAM) { Set_IE_Proxy_Status(1); Set_Miranda_Proxy_Status(1); @@ -110,7 +110,7 @@ static int ProxyEnable(WPARAM wParam, LPARAM lParam) return 0; } -static int ProxyDisable(WPARAM wParam, LPARAM lParam) +static INT_PTR ProxyDisable(WPARAM, LPARAM) { Set_IE_Proxy_Status(0); Set_Miranda_Proxy_Status(0); @@ -134,43 +134,42 @@ void CopyIP2Clipboard(UCHAR idx) CloseClipboard(); } -static int CopyIP2Clipboard0(WPARAM wParam, LPARAM lParam) +static INT_PTR CopyIP2Clipboard0(WPARAM, LPARAM) { CopyIP2Clipboard(0); return 0; } -static int CopyIP2Clipboard1(WPARAM wParam, LPARAM lParam) +static INT_PTR CopyIP2Clipboard1(WPARAM, LPARAM) { CopyIP2Clipboard(1); return 0; } -static int CopyIP2Clipboard2(WPARAM wParam, LPARAM lParam) +static INT_PTR CopyIP2Clipboard2(WPARAM, LPARAM) { CopyIP2Clipboard(2); return 0; } -static int CopyIP2Clipboard3(WPARAM wParam, LPARAM lParam) +static INT_PTR CopyIP2Clipboard3(WPARAM, LPARAM) { CopyIP2Clipboard(3); return 0; } -static int CopyIP2Clipboard4(WPARAM wParam, LPARAM lParam) +static INT_PTR CopyIP2Clipboard4(WPARAM, LPARAM) { CopyIP2Clipboard(4); return 0; } -static int CopyIP2Clipboard5(WPARAM wParam, LPARAM lParam) +static INT_PTR CopyIP2Clipboard5(WPARAM, LPARAM) { CopyIP2Clipboard(5); return 0; } - void UpdateInterfacesMenu(void) { UCHAR idx; @@ -273,7 +272,7 @@ void UpdatePopupMenu(BOOL State) //CallService(MS_CLIST_MODIFYMENUITEM, (WPARAM)hEnableDisablePopupMenu, (LPARAM)&mi); } -static int PopupSwitch(WPARAM wParam, LPARAM lParam) +static INT_PTR PopupSwitch(WPARAM, LPARAM) { opt_popups = !opt_popups; UpdatePopupMenu(opt_popups); @@ -331,7 +330,7 @@ int CMPlugin::Load() return 0; } -int Init(WPARAM wParam, LPARAM lParam) +int Init(WPARAM, LPARAM) { CMenuItem mi(g_plugin); diff --git a/plugins/ProxySwitch/src/opt.cpp b/plugins/ProxySwitch/src/opt.cpp index a7a7ecb1e0..366ca7e1cc 100644 --- a/plugins/ProxySwitch/src/opt.cpp +++ b/plugins/ProxySwitch/src/opt.cpp @@ -32,7 +32,7 @@ void ShowHelp(HWND hdlg, int showhide_help) ShowWindow(GetDlgItem(hdlg, IDC_EDIT_HIDEINTF), showhide_others); } -BOOL CALLBACK OptionsProc(HWND hdlg, UINT msg, WPARAM wparam, LPARAM lparam) +INT_PTR CALLBACK OptionsProc(HWND hdlg, UINT msg, WPARAM wparam, LPARAM lparam) { switch (msg) { diff --git a/plugins/ProxySwitch/src/version.h b/plugins/ProxySwitch/src/version.h index d2fc801bf4..b591e28534 100644 --- a/plugins/ProxySwitch/src/version.h +++ b/plugins/ProxySwitch/src/version.h @@ -1,13 +1,13 @@ #define __MAJOR_VERSION 1 #define __MINOR_VERSION 0 -#define __RELEASE_NUM 0 -#define __BUILD_NUM 1 +#define __RELEASE_NUM 0 +#define __BUILD_NUM 1 #include <stdver.h> -#define __PLUGIN_NAME "ProxySwitch" -#define __FILENAME "ProxySwitch.dll" +#define __PLUGIN_NAME "ProxySwitch" +#define __FILENAME "ProxySwitch.dll" #define __DESCRIPTION "The plugin watches IP address changes, displays popups, and adjusts the proxy settings of Miranda, Internet Explorer and Firefox." -#define __AUTHOR "Petr Smejkal" +#define __AUTHOR "Petr Smejkal" #define __AUTHORWEB "https://miranda-ng.org/p/ProxySwitch/" #define __COPYRIGHT "© 2005 Petr Smejkal" |