From ee23690fa6c847a5284f8145e73328cdaab2b617 Mon Sep 17 00:00:00 2001 From: George Hazan Date: Tue, 21 Nov 2023 19:01:35 +0300 Subject: SRMM toolbar buttons that require input window to be visible are marked as BBBF_NOREADONLY --- include/m_message.h | 5 +---- include/m_srmm_int.h | 2 +- include/newpluginapi.h | 1 + 3 files changed, 3 insertions(+), 5 deletions(-) (limited to 'include') diff --git a/include/m_message.h b/include/m_message.h index 684069bb36..61cad42f2d 100644 --- a/include/m_message.h +++ b/include/m_message.h @@ -211,6 +211,7 @@ EXTERN_C MIR_APP_DLL(void) Srmm_ClickStatusIcon(MCONTACT hContact, const StatusI #define BBBF_ISSEPARATOR (1<<9) #define BBBF_CANTBEHIDDEN (1<<10) #define BBBF_CREATEBYID (1<<11) // only for the internal use +#define BBBF_NOREADONLY (1<<12) struct BBButton { @@ -226,10 +227,6 @@ struct BBButton const char *pszHotkey; // name of the registered hotkey or NULL }; -// adds a new toolbar button -// returns button's handle on success or NULL otherwise -EXTERN_C MIR_APP_DLL(HANDLE) Srmm_AddButton(const BBButton *bbdi, HPLUGIN); - // modifies the existing toolbar button // returns 0 on success and nonzero value otherwise EXTERN_C MIR_APP_DLL(int) Srmm_ModifyButton(BBButton *bbdi); diff --git a/include/m_srmm_int.h b/include/m_srmm_int.h index ce1a6a8423..a21098ea32 100644 --- a/include/m_srmm_int.h +++ b/include/m_srmm_int.h @@ -64,7 +64,7 @@ struct CustomButtonData : public MZeroedObject HANDLE m_hIcon; // Handle to icolib registred icon bool m_bIMButton, m_bChatButton; - bool m_bCanBeHidden, m_bCantBeHidden, m_bHidden, m_bSeparator, m_bDisabled, m_bPushButton; + bool m_bCanBeHidden, m_bCantBeHidden, m_bHidden, m_bSeparator, m_bDisabled, m_bPushButton, m_bNoReadonly; bool m_bRSided; uint8_t m_opFlags; HPLUGIN m_pPlugin; diff --git a/include/newpluginapi.h b/include/newpluginapi.h index e04ff075c0..76ca3e3343 100644 --- a/include/newpluginapi.h +++ b/include/newpluginapi.h @@ -197,6 +197,7 @@ public: HANDLE addIcon(const struct SKINICONDESC*); HANDLE addTTB(const struct TTBButton*); + HANDLE addButton(const struct BBButton *); HGENMENU addRootMenu(int hMenuObject, LPCWSTR ptszName, int position, HANDLE hIcoLib = nullptr); -- cgit v1.2.3