diff options
author | George Hazan <george.hazan@gmail.com> | 2015-06-30 20:27:23 +0000 |
---|---|---|
committer | George Hazan <george.hazan@gmail.com> | 2015-06-30 20:27:23 +0000 |
commit | a8c93cfbf235c31cf604cb6bd40009e9bf88f36a (patch) | |
tree | 0eaf9592ee3cd752e8f2d0273132de0004aa1f6e /protocols/Yahoo/src | |
parent | 6b893bc94df93321a216ba62c3d56a6e08086e36 (diff) |
- fix for the old perversion with manual protocol root calculation;
- protocol menu root is always created by the core;
- other minor problems with protocol menus in main menu went away
git-svn-id: http://svn.miranda-ng.org/main/trunk@14462 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c
Diffstat (limited to 'protocols/Yahoo/src')
-rw-r--r-- | protocols/Yahoo/src/proto.cpp | 5 | ||||
-rw-r--r-- | protocols/Yahoo/src/proto.h | 1 | ||||
-rw-r--r-- | protocols/Yahoo/src/services.cpp | 21 |
3 files changed, 1 insertions, 26 deletions
diff --git a/protocols/Yahoo/src/proto.cpp b/protocols/Yahoo/src/proto.cpp index faab974481..ccb3c16257 100644 --- a/protocols/Yahoo/src/proto.cpp +++ b/protocols/Yahoo/src/proto.cpp @@ -638,11 +638,6 @@ int __cdecl CYahooProto::OnEvent(PROTOEVENTTYPE eventType, WPARAM wParam, LPARAM MenuMainInit();
break;
- case EV_PROTO_ONRENAME:
- if (mainMenuRoot)
- Menu_ModifyItem(mainMenuRoot, m_tszUserName, INVALID_HANDLE_VALUE, CMIF_KEEPUNTRANSLATED);
- break;
-
case EV_PROTO_ONCONTACTDELETED:
return OnContactDeleted(wParam, lParam);
diff --git a/protocols/Yahoo/src/proto.h b/protocols/Yahoo/src/proto.h index a220b3b788..992b9292c3 100644 --- a/protocols/Yahoo/src/proto.h +++ b/protocols/Yahoo/src/proto.h @@ -279,7 +279,6 @@ private: HANDLE hYahooNudge;
- HGENMENU mainMenuRoot;
HGENMENU hShowProfileMenuItem;
HGENMENU menuItemsAll[ 8 ];
};
diff --git a/protocols/Yahoo/src/services.cpp b/protocols/Yahoo/src/services.cpp index 49cdb8b93d..25e7a2a1e1 100644 --- a/protocols/Yahoo/src/services.cpp +++ b/protocols/Yahoo/src/services.cpp @@ -359,24 +359,8 @@ INT_PTR __cdecl CYahooProto::GetUnreadEmailCount(WPARAM, LPARAM) void CYahooProto::MenuMainInit(void)
{
CMenuItem mi;
-
- HGENMENU hRoot = Menu_GetProtocolRoot(m_szModuleName);
- if (hRoot == NULL) {
- mi.position = 500015000;
- mi.flags = CMIF_TCHAR | CMIF_KEEPUNTRANSLATED;
- mi.hIcolibItem = GetIconHandle(IDI_YAHOO);
- mi.name.t = m_tszUserName;
- hRoot = mainMenuRoot = Menu_AddProtoMenuItem(&mi);
- }
- else {
- if (mainMenuRoot) {
- Menu_RemoveItem(mainMenuRoot);
- mainMenuRoot = NULL;
- }
- }
-
mi.flags = 0;
- mi.root = hRoot;
+ mi.root = Menu_GetProtocolRoot(this);
// Show custom status menu
mi.pszService = YAHOO_SET_CUST_STAT;
@@ -450,9 +434,6 @@ void CYahooProto::MenuContactInit(void) void CYahooProto::MenuUninit(void)
{
- if (mainMenuRoot)
- Menu_RemoveItem(mainMenuRoot);
-
Menu_RemoveItem(hShowProfileMenuItem);
}
|