From e3bea6d9c261c87d7f67ecc06392c0d0cd4fe2dc Mon Sep 17 00:00:00 2001 From: George Hazan Date: Fri, 18 Jan 2019 21:50:38 +0300 Subject: fixes #1776 (remove MS_URL_SENDURL "SRUrl/SendCommand") --- include/delphi/interfaces.inc | 1 - include/delphi/m_api.pas | 1 - include/delphi/m_url.inc | 36 ----------------------------- include/m_url.h | 35 ---------------------------- plugins/HistoryStats/src/stdafx.h | 1 - plugins/QuickContacts/res/resource.rc | 8 +++---- plugins/QuickContacts/src/dialog.cpp | 24 ------------------- plugins/QuickContacts/src/quickcontacts.cpp | 6 ----- plugins/QuickContacts/src/resource.h | 2 -- plugins/QuickContacts/src/stdafx.h | 1 - 10 files changed, 3 insertions(+), 112 deletions(-) delete mode 100644 include/delphi/m_url.inc delete mode 100644 include/m_url.h diff --git a/include/delphi/interfaces.inc b/include/delphi/interfaces.inc index c0e660bf82..8aa46f59f2 100644 --- a/include/delphi/interfaces.inc +++ b/include/delphi/interfaces.inc @@ -13,7 +13,6 @@ const MIID_TRANSLATE :MUUID='{0C0954EA-43D7-4452-99AC-F084D4456716}'; // Replaceable internal modules interface ids const MIID_HISTORY :MUUID='{5CA0CBC1-999A-4EA2-8B44-F8F67D7F8EBE}'; const MIID_UIUSERINFO :MUUID='{570B931C-9AF8-48F1-AD9F-C4498C618A77}'; -const MIID_SRURL :MUUID='{5192445C-F5E8-46C0-8F9E-2B6D43E5C753}'; const MIID_SRAUTH :MUUID='{377780B9-2B3B-405B-9F36-B3C4878E6F33}'; const MIID_SRAWAY :MUUID='{5AB54C76-1B4C-4A00-B404-48CBEA5FEFE7}'; const MIID_SREMAIL :MUUID='{D005B5A6-1B66-445A-B603-74D4D4552DE2}'; diff --git a/include/delphi/m_api.pas b/include/delphi/m_api.pas index dc8c8ecced..7d5032e1b8 100644 --- a/include/delphi/m_api.pas +++ b/include/delphi/m_api.pas @@ -237,7 +237,6 @@ var {$include m_ssl.inc} {$include statusmodes.inc} {$include m_timezones.inc} - {$include m_url.inc} {$include m_userinfo.inc} {$include m_utils.inc} {$include m_xml.inc} diff --git a/include/delphi/m_url.inc b/include/delphi/m_url.inc deleted file mode 100644 index d95063661a..0000000000 --- a/include/delphi/m_url.inc +++ /dev/null @@ -1,36 +0,0 @@ -{ -Miranda IM: the free IM client for Microsoft* Windows* - -Copyright 2000-2003 Miranda ICQ/IM project, -all portions of this codebase are copyrighted to the people -listed in contributors.txt. - -This program is free software; you can redistribute it and/or -modify it under the terms of the GNU General Public License -as published by the Free Software Foundation; either version 2 -of the License, or (at your option) any later version. - -This program is distributed in the hope that it will be useful, -but WITHOUT ANY WARRANTY; without even the implied warranty of -MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -GNU General Public License for more details. - -You should have received a copy of the GNU General Public License -along with this program; if not, write to the Free Software -Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. -} - -{$IFNDEF M_URL} -{$DEFINE M_URL} - -const - { - wParam : TMCONTACT - lParam : 0 - Affects: bring up the send URL dialogbox for a user - Returns: 0 on success, nonzero on failure, see notes - Notes : service returns before the URL is sent. - } - MS_URL_SENDURL:PAnsiChar = 'SRUrl/SendCommand'; - -{$ENDIF} diff --git a/include/m_url.h b/include/m_url.h deleted file mode 100644 index bcbd8ecd84..0000000000 --- a/include/m_url.h +++ /dev/null @@ -1,35 +0,0 @@ -/* - -Miranda NG: the free IM client for Microsoft* Windows* - -Copyright (C) 2012-19 Miranda NG team (https://miranda-ng.org) -Copyright (c) 2000-08 Miranda ICQ/IM project, -all portions of this codebase are copyrighted to the people -listed in contributors.txt. - -This program is free software; you can redistribute it and/or -modify it under the terms of the GNU General Public License -as published by the Free Software Foundation; either version 2 -of the License, or (at your option) any later version. - -This program is distributed in the hope that it will be useful, -but WITHOUT ANY WARRANTY; without even the implied warranty of -MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -GNU General Public License for more details. - -You should have received a copy of the GNU General Public License -along with this program; if not, write to the Free Software -Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. -*/ - -#ifndef M_URL_H__ -#define M_URL_H__ 1 - -//bring up the send URL dialog for a user -//wParam = (MCONTACT)hContact -//lParam = 0 -//returns 0 on success or nonzero on failure -//returns immediately, before the url is sent -#define MS_URL_SENDURL "SRUrl/SendCommand" - -#endif // M_URL_H__ diff --git a/plugins/HistoryStats/src/stdafx.h b/plugins/HistoryStats/src/stdafx.h index 94ebbc4452..fcf0d2c131 100644 --- a/plugins/HistoryStats/src/stdafx.h +++ b/plugins/HistoryStats/src/stdafx.h @@ -58,7 +58,6 @@ #include #include #include -#include // not used #include // not used #include #include diff --git a/plugins/QuickContacts/res/resource.rc b/plugins/QuickContacts/res/resource.rc index c01c88e081..dd676d7732 100644 --- a/plugins/QuickContacts/res/resource.rc +++ b/plugins/QuickContacts/res/resource.rc @@ -74,12 +74,11 @@ BEGIN CONTROL "",IDC_MESSAGE,"MButtonClass",0x0,41,36,17,15, 0x18000000L CONTROL "",IDC_FILE,"MButtonClass",0x0,83,36,17,15,0x18000000L - CONTROL "",IDC_URL,"MButtonClass",0x0,104,36,17,15,0x18000000L - CONTROL "",IDC_USERINFO,"MButtonClass",0x0,125,36,17,15, + CONTROL "",IDC_USERINFO,"MButtonClass",0x0,104,36,17,15, 0x18000000L - CONTROL "",IDC_HISTORY,"MButtonClass",0x0,146,36,17,15, + CONTROL "",IDC_HISTORY,"MButtonClass",0x0,125,36,17,15, 0x18000000L - CONTROL "",IDC_MENU,"MButtonClass",0x0,167,36,17,15,0x18000000L + CONTROL "",IDC_MENU,"MButtonClass",0x0,146,36,17,15,0x18000000L END @@ -117,7 +116,6 @@ BEGIN "H", HOTKEY_HISTORY, VIRTKEY, CONTROL, NOINVERT "I", HOTKEY_INFO, VIRTKEY, CONTROL, NOINVERT "M", HOTKEY_MENU, VIRTKEY, CONTROL, NOINVERT - "U", HOTKEY_URL, VIRTKEY, CONTROL, NOINVERT END #ifdef APSTUDIO_INVOKED diff --git a/plugins/QuickContacts/src/dialog.cpp b/plugins/QuickContacts/src/dialog.cpp index c01d155eac..c0f386018a 100644 --- a/plugins/QuickContacts/src/dialog.cpp +++ b/plugins/QuickContacts/src/dialog.cpp @@ -225,7 +225,6 @@ void EnableButtons(HWND hwndDlg, MCONTACT hContact) if (hContact == NULL) { EnableWindow(GetDlgItem(hwndDlg, IDC_MESSAGE), FALSE); EnableWindow(GetDlgItem(hwndDlg, IDC_FILE), FALSE); - EnableWindow(GetDlgItem(hwndDlg, IDC_URL), FALSE); EnableWindow(GetDlgItem(hwndDlg, IDC_USERINFO), FALSE); EnableWindow(GetDlgItem(hwndDlg, IDC_HISTORY), FALSE); EnableWindow(GetDlgItem(hwndDlg, IDC_MENU), FALSE); @@ -247,7 +246,6 @@ void EnableButtons(HWND hwndDlg, MCONTACT hContact) EnableWindow(GetDlgItem(hwndDlg, IDC_MESSAGE), caps & PF1_IMSEND ? TRUE : FALSE); EnableWindow(GetDlgItem(hwndDlg, IDC_FILE), caps & PF1_FILESEND ? TRUE : FALSE); - EnableWindow(GetDlgItem(hwndDlg, IDC_URL), caps & PF1_URLSEND ? TRUE : FALSE); EnableWindow(GetDlgItem(hwndDlg, IDC_USERINFO), TRUE); EnableWindow(GetDlgItem(hwndDlg, IDC_HISTORY), TRUE); EnableWindow(GetDlgItem(hwndDlg, IDC_MENU), TRUE); @@ -518,7 +516,6 @@ static INT_PTR CALLBACK MainDlgProc(HWND hwndDlg, UINT msg, WPARAM wParam, LPARA FillCheckbox(hwndDlg, IDC_SHOW_ALL_CONTACTS, LPGENW("Show all contacts"), NULL); FillButton(hwndDlg, IDC_MESSAGE, LPGENW("Send message"), nullptr, Skin_LoadIcon(SKINICON_EVENT_MESSAGE)); FillButton(hwndDlg, IDC_FILE, LPGENW("Send file"), NULL, Skin_LoadIcon(SKINICON_EVENT_FILE)); - FillButton(hwndDlg, IDC_URL, LPGENW("Send URL"), NULL, Skin_LoadIcon(SKINICON_EVENT_URL)); FillButton(hwndDlg, IDC_USERINFO, LPGENW("Open user info"), NULL, Skin_LoadIcon(SKINICON_OTHER_USERDETAILS)); FillButton(hwndDlg, IDC_HISTORY, LPGENW("Open history"), NULL, Skin_LoadIcon(SKINICON_OTHER_HISTORY)); FillButton(hwndDlg, IDC_MENU, LPGENW("Open contact menu"), NULL, Skin_LoadIcon(SKINICON_OTHER_DOWNARROW)); @@ -604,27 +601,6 @@ static INT_PTR CALLBACK MainDlgProc(HWND hwndDlg, UINT msg, WPARAM wParam, LPARA } break; - case HOTKEY_URL: - case IDC_URL: - { - MCONTACT hContact = GetSelectedContact(hwndDlg); - if (hContact == NULL) { - SetDlgItemText(hwndDlg, IDC_USERNAME, L""); - SetFocus(GetDlgItem(hwndDlg, IDC_USERNAME)); - break; - } - - // Is button enabled? - if (!IsWindowEnabled(GetDlgItem(hwndDlg, IDC_URL))) - break; - - CallService(MS_URL_SENDURL, hContact, 0); - - g_plugin.setDword("LastSentTo", hContact); - SendMessage(hwndDlg, WM_CLOSE, 0, 0); - } - break; - case HOTKEY_INFO: case IDC_USERINFO: { diff --git a/plugins/QuickContacts/src/quickcontacts.cpp b/plugins/QuickContacts/src/quickcontacts.cpp index e6039dc83e..90d827652e 100644 --- a/plugins/QuickContacts/src/quickcontacts.cpp +++ b/plugins/QuickContacts/src/quickcontacts.cpp @@ -74,12 +74,6 @@ static int ModulesLoaded(WPARAM, LPARAM) hkd.szDescription.w = LPGENW("Send file"); g_plugin.addHotkey(&hkd); - hkd.lParam = HOTKEY_URL; - hkd.DefHotKey = HOTKEYCODE(HOTKEYF_CONTROL, 'U'); - hkd.pszName = "Quick Contacts/URL"; - hkd.szDescription.w = LPGENW("Send URL"); - g_plugin.addHotkey(&hkd); - hkd.lParam = HOTKEY_INFO; hkd.DefHotKey = HOTKEYCODE(HOTKEYF_CONTROL, 'I'); hkd.pszName = "Quick Contacts/Info"; diff --git a/plugins/QuickContacts/src/resource.h b/plugins/QuickContacts/src/resource.h index 38fd6df5cb..04d0a8bb23 100644 --- a/plugins/QuickContacts/src/resource.h +++ b/plugins/QuickContacts/src/resource.h @@ -19,12 +19,10 @@ #define IDC_GROUP_COLUMN 1062 #define IDC_FILE 1063 #define IDC_GROUP_LEFT 1063 -#define IDC_URL 1064 #define IDC_USERINFO 1065 #define IDC_HISTORY 1066 #define IDC_MENU 1067 #define HOTKEY_FILE 40001 -#define HOTKEY_URL 40002 #define HOTKEY_INFO 40003 #define HOTKEY_HISTORY 40004 #define HOTKEY_ALL_CONTACTS 40005 diff --git a/plugins/QuickContacts/src/stdafx.h b/plugins/QuickContacts/src/stdafx.h index a2d7392f14..88dab13406 100644 --- a/plugins/QuickContacts/src/stdafx.h +++ b/plugins/QuickContacts/src/stdafx.h @@ -36,7 +36,6 @@ Boston, MA 02111-1307, USA. #include #include #include -#include #include #include #include -- cgit v1.2.3