From a5a6c8afb1d68330dc1e112ca9bdb0e38c435ad8 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Robert=20P=C3=B6sel?= Date: Wed, 31 Aug 2016 10:11:26 +0000 Subject: Facebook: Implement loading history from server (via contact menu) git-svn-id: http://svn.miranda-ng.org/main/trunk@17220 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c --- protocols/FacebookRM/src/theme.cpp | 11 +++++++++++ 1 file changed, 11 insertions(+) (limited to 'protocols/FacebookRM/src/theme.cpp') diff --git a/protocols/FacebookRM/src/theme.cpp b/protocols/FacebookRM/src/theme.cpp index 70ca0eb696..8e7ae32cf7 100644 --- a/protocols/FacebookRM/src/theme.cpp +++ b/protocols/FacebookRM/src/theme.cpp @@ -35,6 +35,7 @@ HGENMENU g_hContactMenuAuthDeny; HGENMENU g_hContactMenuPoke; HGENMENU g_hContactMenuPostStatus; HGENMENU g_hContactMenuVisitConversation; +HGENMENU g_hContactMenuLoadHistory; static IconItem icons[] = { @@ -104,6 +105,7 @@ static int PrebuildContactMenu(WPARAM wParam, LPARAM lParam) Menu_ShowItem(g_hContactMenuPoke, false); Menu_ShowItem(g_hContactMenuPostStatus, false); Menu_ShowItem(g_hContactMenuVisitConversation, false); + Menu_ShowItem(g_hContactMenuLoadHistory, false); // Process them in correct account FacebookProto *proto = GetInstanceByHContact(MCONTACT(wParam)); @@ -156,6 +158,14 @@ void InitContactMenus() CreateServiceFunction(mi.pszService, GlobalService<&FacebookProto::Poke>); g_hContactMenuPoke = Menu_AddContactMenuItem(&mi); + SET_UID(mi, 0x58e75db0, 0xb9e0, 0x4aa8, 0xbb, 0x42, 0x8d, 0x7d, 0xd1, 0xf6, 0x8e, 0x99); + mi.position = -2000006005; + mi.hIcolibItem = GetIconHandle("conversation"); // TODO: Use better icon + mi.name.a = LPGEN("Load history"); + mi.pszService = "FacebookProto/LoadHistory"; + CreateServiceFunction(mi.pszService, GlobalService<&FacebookProto::LoadHistory>); + g_hContactMenuLoadHistory = Menu_AddContactMenuItem(&mi); + SET_UID(mi, 0x619efdcb, 0x99c0, 0x44a8, 0xbf, 0x28, 0xc3, 0xe0, 0x2f, 0xb3, 0x7e, 0x77); mi.position = -2000006010; mi.hIcolibItem = Skin_GetIconHandle(SKINICON_AUTH_REVOKE); @@ -209,6 +219,7 @@ int FacebookProto::OnPrebuildContactMenu(WPARAM wParam, LPARAM) Menu_ShowItem(g_hContactMenuVisitFriendship, !bIsChatroom && !bIsPage); Menu_ShowItem(g_hContactMenuVisitConversation, true); Menu_ShowItem(g_hContactMenuPostStatus, !bIsChatroom); + Menu_ShowItem(g_hContactMenuLoadHistory, !bIsChatroom); if (!isOffline() && !bIsChatroom && !bIsPage) { -- cgit v1.2.3