summaryrefslogtreecommitdiff
path: root/protocols/AimOscar
diff options
context:
space:
mode:
authorGeorge Hazan <george.hazan@gmail.com>2015-06-30 20:27:23 +0000
committerGeorge Hazan <george.hazan@gmail.com>2015-06-30 20:27:23 +0000
commita8c93cfbf235c31cf604cb6bd40009e9bf88f36a (patch)
tree0eaf9592ee3cd752e8f2d0273132de0004aa1f6e /protocols/AimOscar
parent6b893bc94df93321a216ba62c3d56a6e08086e36 (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/AimOscar')
-rw-r--r--protocols/AimOscar/src/proto.cpp5
-rw-r--r--protocols/AimOscar/src/proto.h1
-rw-r--r--protocols/AimOscar/src/theme.cpp18
3 files changed, 1 insertions, 23 deletions
diff --git a/protocols/AimOscar/src/proto.cpp b/protocols/AimOscar/src/proto.cpp
index 6097af60cb..4dc782f75a 100644
--- a/protocols/AimOscar/src/proto.cpp
+++ b/protocols/AimOscar/src/proto.cpp
@@ -703,11 +703,6 @@ int __cdecl CAimProto::OnEvent(PROTOEVENTTYPE eventType, WPARAM wParam, LPARAM l
}
break;
- case EV_PROTO_ONRENAME:
- if (hMenuRoot)
- Menu_ModifyItem(hMenuRoot, m_tszUserName);
- break;
-
case EV_PROTO_ONCONTACTDELETED:
return OnContactDeleted(wParam, lParam);
diff --git a/protocols/AimOscar/src/proto.h b/protocols/AimOscar/src/proto.h
index 5ee46474c8..ea4688b1ef 100644
--- a/protocols/AimOscar/src/proto.h
+++ b/protocols/AimOscar/src/proto.h
@@ -133,7 +133,6 @@ struct CAimProto : public PROTO<CAimProto>
HANDLE hDirectBoundPort;//direct connection listening port
//Handles for the context menu items
- HGENMENU hMenuRoot;
HGENMENU hHTMLAwayContextMenuItem;
HGENMENU hAddToServerListContextMenuItem;
HGENMENU hBlockContextMenuItem;
diff --git a/protocols/AimOscar/src/theme.cpp b/protocols/AimOscar/src/theme.cpp
index de5f0a4220..c419b3d1ec 100644
--- a/protocols/AimOscar/src/theme.cpp
+++ b/protocols/AimOscar/src/theme.cpp
@@ -209,24 +209,8 @@ int CAimProto::OnPreBuildContactMenu(WPARAM hContact, LPARAM)
void CAimProto::InitMainMenus(void)
{
- HGENMENU hRoot = Menu_GetProtocolRoot(m_szModuleName);
- if (hRoot == NULL) {
- CMenuItem mi;
- mi.flags = CMIF_TCHAR | CMIF_KEEPUNTRANSLATED;
- mi.hIcolibItem = GetIconHandle("aim");
- mi.name.t = m_tszUserName;
- mi.position = 500090000;
- hRoot = hMenuRoot = Menu_AddProtoMenuItem(&mi);
- }
- else {
- if (hMenuRoot) {
- Menu_RemoveItem(hMenuRoot);
- hMenuRoot = NULL;
- }
- }
-
CMenuItem mi;
- mi.root = hRoot;
+ mi.root = Menu_GetProtocolRoot(this);
mi.pszService = "/ManageAccount";
CreateProtoService(mi.pszService, &CAimProto::ManageAccount);