From 38ccdfad49393e06ac7246550ac4d6baea862319 Mon Sep 17 00:00:00 2001 From: George Hazan Date: Tue, 16 Sep 2014 14:34:12 +0000 Subject: compilation fix git-svn-id: http://svn.miranda-ng.org/main/trunk@10481 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c --- protocols/WhatsApp/src/theme.cpp | 31 ++++++++++++++++--------------- 1 file changed, 16 insertions(+), 15 deletions(-) (limited to 'protocols') diff --git a/protocols/WhatsApp/src/theme.cpp b/protocols/WhatsApp/src/theme.cpp index ed1ef25743..3597084672 100644 --- a/protocols/WhatsApp/src/theme.cpp +++ b/protocols/WhatsApp/src/theme.cpp @@ -225,31 +225,32 @@ int WhatsAppProto::OnPrebuildContactMenu(WPARAM wParam,LPARAM lParam) return 0; } -int WhatsAppProto::OnBuildStatusMenu(WPARAM wParam,LPARAM lParam) +int WhatsAppProto::OnBuildStatusMenu(WPARAM wParam, LPARAM lParam) { debugLogA(""); char text[200]; - strcpy(text,m_szModuleName); - char *tDest = text+strlen(text); + strcpy(text, m_szModuleName); + char *tDest = text + strlen(text); - CLISTMENUITEM mi = {sizeof(mi)}; + CLISTMENUITEM mi = { sizeof(mi) }; mi.pszService = text; HGENMENU hRoot = MO_GetProtoRootMenu(m_szModuleName); if (hRoot == NULL) { mi.popupPosition = 500085000; mi.hParentMenu = HGENMENU_ROOT; - mi.flags = CMIF_ROOTPOPUP | CMIF_TCHAR | CMIF_KEEPUNTRANSLATED | ( this->isOnline() ? 0 : CMIF_GRAYED ); - mi.icolibItem = GetIconHandle( "whatsApp" ); + mi.flags = CMIF_ROOTPOPUP | CMIF_TCHAR | CMIF_KEEPUNTRANSLATED | (this->isOnline() ? 0 : CMIF_GRAYED); + mi.icolibItem = GetIconHandle("whatsApp"); mi.ptszName = m_tszUserName; hRoot = m_hMenuRoot = Menu_AddProtoMenuItem(&mi); - } else { - if ( m_hMenuRoot ) - CallService( MS_CLIST_REMOVEMAINMENUITEM, ( WPARAM )m_hMenuRoot, 0 ); + } + else { + if (m_hMenuRoot) + CallService(MO_REMOVEMENUITEM, (WPARAM)m_hMenuRoot, 0); m_hMenuRoot = NULL; } - mi.flags = CMIF_CHILDPOPUP | ( this->isOnline() ? 0 : CMIF_GRAYED ); + mi.flags = CMIF_CHILDPOPUP | (this->isOnline() ? 0 : CMIF_GRAYED); mi.position = 201001; CreateProtoService("/CreateGroup", &WhatsAppProto::OnCreateGroup); @@ -262,11 +263,11 @@ int WhatsAppProto::OnBuildStatusMenu(WPARAM wParam,LPARAM lParam) return 0; } -void WhatsAppProto::ToggleStatusMenuItems( BOOL bEnable ) +void WhatsAppProto::ToggleStatusMenuItems(BOOL bEnable) { - CLISTMENUITEM clmi = {sizeof(clmi)}; - clmi.flags = CMIM_FLAGS | (( bEnable ) ? 0 : CMIF_GRAYED); + CLISTMENUITEM clmi = { sizeof(clmi) }; + clmi.flags = CMIM_FLAGS | ((bEnable) ? 0 : CMIF_GRAYED); - CallService( MS_CLIST_MODIFYMENUITEM, ( WPARAM ) m_hMenuRoot, ( LPARAM )&clmi ); - CallService( MS_CLIST_MODIFYMENUITEM, ( WPARAM ) m_hMenuCreateGroup, ( LPARAM )&clmi ); + CallService(MS_CLIST_MODIFYMENUITEM, (WPARAM)m_hMenuRoot, (LPARAM)&clmi); + CallService(MS_CLIST_MODIFYMENUITEM, (WPARAM)m_hMenuCreateGroup, (LPARAM)&clmi); } -- cgit v1.2.3