diff options
author | George Hazan <george.hazan@gmail.com> | 2012-07-08 18:45:11 +0000 |
---|---|---|
committer | George Hazan <george.hazan@gmail.com> | 2012-07-08 18:45:11 +0000 |
commit | 929cf4f6f089cc4db4eea16898402120fc812e30 (patch) | |
tree | 67218e5b14923f8021b4406249756bdf1cab232a /plugins/ExternalAPI | |
parent | 71defe6c2ba6284e775f2317311e29a77c02b81d (diff) |
default buttons from Clist Nicer+ & Modern
git-svn-id: http://svn.miranda-ng.org/main/trunk@859 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c
Diffstat (limited to 'plugins/ExternalAPI')
-rw-r--r-- | plugins/ExternalAPI/m_toptoolbar.h | 30 |
1 files changed, 19 insertions, 11 deletions
diff --git a/plugins/ExternalAPI/m_toptoolbar.h b/plugins/ExternalAPI/m_toptoolbar.h index 6b5f6abd15..5ef3a20352 100644 --- a/plugins/ExternalAPI/m_toptoolbar.h +++ b/plugins/ExternalAPI/m_toptoolbar.h @@ -1,6 +1,8 @@ #ifndef M_TOPTOOLBAR_H
#define M_TOPTOOLBAR_H
+#define TTB_OPTDIR "TopToolBar"
+
//button flags
#define TTBBF_DISABLED 0x0001
#define TTBBF_VISIBLE 0x0002
@@ -32,14 +34,9 @@ typedef struct { HICON hIconDn;
HANDLE hIconHandleDn;
};
- union {
- char *pszTooltipDn;
- TCHAR *ptszTooltipDn;
- };
- union {
- char *pszTooltipUp;
- TCHAR *ptszTooltipUp;
- };
+
+ char *pszTooltipUp;
+ char *pszTooltipDn;
}
TTBButton, * lpTTBButton;
@@ -52,18 +49,29 @@ Called when the toolbar services are available !!!Warning you may work with TTB services only in this event or later.
*/
-#define ME_TTB_MODULELOADED "TopToolBar/ModuleLoaded"
+#define ME_TTB_MODULELOADED "TopToolBar/ModuleLoaded"
+/*
+toptoolbar/initbuttons event
+wParam = lParam = 0
+Called when the toolbar needs to add default buttons
+*/
+#define ME_TTB_INITBUTTONS "TopToolBar/InitButtons"
//=== SERVICES ===
/*
toptoolbar/addbutton service
wparam = (TTBButton*)lpTTBButton
-lparam = 0
+lparam = hLangpack
returns: hTTBButton - handle of added button on success, -1 on failure.
*/
-#define MS_TTB_ADDBUTTON "TopToolBar/AddButton"
+
+extern int hLangpack;
+
+__forceinline HANDLE TopToolbar_AddButton(TTBButton *pButton)
+{ return (HANDLE)CallService("TopToolBar/AddButton", (WPARAM)pButton, hLangpack);
+}
/*
toptoolbar/removebutton service
|