From be489c4e6f4c1ab4b4d7f84e35a73e34e1b0b331 Mon Sep 17 00:00:00 2001 From: George Hazan Date: Thu, 25 Jun 2015 23:34:47 +0000 Subject: - Menu_EnableItem & Menu_SetChecked - more suitable helpers to set flags; - fix for checks in frame menus; - code cleaning git-svn-id: http://svn.miranda-ng.org/main/trunk@14389 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c --- protocols/FacebookRM/src/proto.h | 2 +- protocols/FacebookRM/src/theme.cpp | 9 ++++----- 2 files changed, 5 insertions(+), 6 deletions(-) (limited to 'protocols/FacebookRM') diff --git a/protocols/FacebookRM/src/proto.h b/protocols/FacebookRM/src/proto.h index a43953e728..33cdd19bfe 100644 --- a/protocols/FacebookRM/src/proto.h +++ b/protocols/FacebookRM/src/proto.h @@ -224,7 +224,7 @@ public: std::tstring GetAvatarFolder(); bool GetDbAvatarInfo(PROTO_AVATAR_INFORMATION &ai, std::string *url); void CheckAvatarChange(MCONTACT hContact, const std::string &image_url); - void ToggleStatusMenuItems(BOOL bEnable); + void ToggleStatusMenuItems(bool bEnable); void StickerAsSmiley(std::string stickerId, const std::string &url, MCONTACT hContact); void SaveName(MCONTACT hContact, const facebook_user *fbu); std::string PrepareUrl(std::string url); diff --git a/protocols/FacebookRM/src/theme.cpp b/protocols/FacebookRM/src/theme.cpp index 922c065db7..934dc808a9 100644 --- a/protocols/FacebookRM/src/theme.cpp +++ b/protocols/FacebookRM/src/theme.cpp @@ -292,10 +292,9 @@ int FacebookProto::OnBuildStatusMenu(WPARAM, LPARAM) return 0; } -void FacebookProto::ToggleStatusMenuItems(BOOL bEnable) +void FacebookProto::ToggleStatusMenuItems(bool bEnable) { - int flags = (bEnable) ? 0 : CMIF_GRAYED; - Menu_ModifyItem(m_hMenuRoot, NULL, INVALID_HANDLE_VALUE, flags); - Menu_ModifyItem(m_hStatusMind, NULL, INVALID_HANDLE_VALUE, flags); - Menu_ModifyItem(m_hMenuServicesRoot, NULL, INVALID_HANDLE_VALUE, flags); + Menu_EnableItem(m_hMenuRoot, bEnable); + Menu_EnableItem(m_hStatusMind, bEnable); + Menu_EnableItem(m_hMenuServicesRoot, bEnable); } -- cgit v1.2.3