diff options
author | Alexey Kulakov <panda75@bk.ru> | 2012-07-04 20:10:29 +0000 |
---|---|---|
committer | Alexey Kulakov <panda75@bk.ru> | 2012-07-04 20:10:29 +0000 |
commit | 65e002b63efdb00571d0ba4ec1a73b14e1d7d3a0 (patch) | |
tree | d96b2f52ca3c89172f269cdb172c89cf6141d69c /include/delphi/m_toptoolbar.inc | |
parent | d7f143dba9e53347a1d7897bcd3989751c7f45f8 (diff) |
Pascal headers moved to include\delphi directory (with small updates)
removed deprecated m_mwclc.h file and link on it in AutoShutdown plugin
git-svn-id: http://svn.miranda-ng.org/main/trunk@763 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c
Diffstat (limited to 'include/delphi/m_toptoolbar.inc')
-rw-r--r-- | include/delphi/m_toptoolbar.inc | 108 |
1 files changed, 108 insertions, 0 deletions
diff --git a/include/delphi/m_toptoolbar.inc b/include/delphi/m_toptoolbar.inc new file mode 100644 index 0000000000..d990c458e8 --- /dev/null +++ b/include/delphi/m_toptoolbar.inc @@ -0,0 +1,108 @@ +{$IFNDEF M_TOPTOOLBAR}
+{$DEFINE M_TOPTOOLBAR}
+
+//button flags
+const
+ TTBBF_DISABLED = 1;
+ TTBBF_VISIBLE = 2;
+ TTBBF_PUSHED = 4;
+ TTBBF_SHOWTOOLTIP = 8;
+ TTBBF_ISSEPARATOR = 32;
+ TTBBF_ISLBUTTON = 64;
+ TTBBF_ICONBYHANDLE = 128;
+ TTBBF_ISSBUTTON = 256;
+ TTBBF_ASPUSHBUTTON = 512;
+
+type
+ PTTBButton = ^TTBButton;
+ TTBButton = record
+ cbSize :int;
+ pszService :PAnsiChar; // or program for lButtons
+ dwFlags :DWORD;
+ lParamUp :LPARAM;
+ wParamUp :WPARAM;
+ lParamDown :LPARAM;
+ wParamDown :WPARAM;
+ name :PAnsiChar;
+ hIconUp :HICON; // or hIconHandleUp:HANDLE
+ hIconDn :HICON; // or hIconHandleDn:HANDLE
+ end;
+
+const
+
+//=== EVENTS ===
+{
+ toptoolbar/moduleloaded event
+ wParam = lParam = 0
+ Called when the toolbar services are available
+
+ !!!Warning you may work with TTB services only in this event or later.
+
+ Im use settimer() - so notify appear in miranda message loop
+ after all onmodulesload calls.
+}
+ ME_TTB_MODULELOADED:PAnsiChar = 'TopToolBar/ModuleLoaded';
+
+{
+//=== SERVICES ===
+
+ toptoolbar/addbutton service
+ wparam = (TTBButton*)lpTTBButton
+ lparam = 0
+ returns: hTTBButton - handle of added button on success, -1 on failure.
+}
+ MS_TTB_ADDBUTTON:PAnsiChar = 'TopToolBar/AddButton';
+
+{
+ toptoolbar/removebutton service
+ wparam = (HANDLE)hTTButton
+ lparam = 0
+ returns: 0 on success, -1 on failure.
+}
+ MS_TTB_REMOVEBUTTON:PAnsiChar = 'TopToolBar/RemoveButton';
+
+{
+ toptoolbar/setstate service
+ wparam = (HANDLE)hTTButton
+ lparam = (LPARAM) state
+ returns: 0 on success, -1 on failure.
+}
+ TTBST_PUSHED = 1;
+ TTBST_RELEASED = 2;
+
+ MS_TTB_SETBUTTONSTATE:PAnsiChar = 'TopToolBar/SetState';
+
+{
+ toptoolbar/getstate service
+ wparam = (HANDLE)hTTButton
+ lparam = 0
+ returns: state on success, -1 on failure.
+}
+ MS_TTB_GETBUTTONSTATE:PAnsiChar = 'TopToolBar/GetState';
+
+{
+ toptoolbar/getoptions service
+ (HIWORD)wparam = (HANDLE)hTTButton
+ (LOWORD)wparam = TTBO_FLAG
+ lparam = 0,or lparam=lpTTBButton if flag=TTBO_ALLDATA
+ returns: value on success, -1 on failure.
+}
+ TTBO_FLAGS = 0; // get/set all flags
+ TTBO_POS = 1; // position
+ TTBO_WIDTH = 2; // not impemented
+ TTBO_HEIGHT = 3; // not impemented
+ TTBO_TIPNAME = 4; // tool tip name
+ TTBO_ALLDATA = 5; // change all data via lparam=lpTTBButton
+
+ MS_TTB_GETBUTTONOPTIONS:PAnsiChar = 'TopToolBar/GetOptions';
+
+{
+ toptoolbar/setoptions service
+ (HIWORD)wparam = (HANDLE)hTTButton
+ (LOWORD)wparam = TTBO_FLAG
+ lparam = value
+ returns: 1 on success, -1 on failure.
+}
+ MS_TTB_SETBUTTONOPTIONS:PAnsiChar = 'TopToolBar/SetOptions';
+
+{$ENDIF}
|