From 89113840fb4160af43bbc6cc22b1b13c5118259d Mon Sep 17 00:00:00 2001 From: Kirill Volinsky Date: Wed, 29 Apr 2015 06:49:54 +0000 Subject: m_* headers moved to ExternalAPI folder git-svn-id: http://svn.miranda-ng.org/main/trunk@13240 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c --- plugins/Clist_modern/src/hdr/modern_clc.h | 2 +- plugins/Clist_modern/src/hdr/modern_statusbar.h | 2 +- plugins/Clist_modern/src/m_api/m_skinbutton.h | 29 ---- plugins/Clist_modern/src/m_api/m_xpTheme.h | 19 --- plugins/Clist_modern/src/modern_clui.cpp | 2 +- plugins/Clist_modern/src/modern_docking.cpp | 2 +- plugins/Clist_modern/src/modern_skinbutton.cpp | 2 +- plugins/Clist_modern/src/modern_skinselector.cpp | 2 +- plugins/Clist_modern/src/modern_tbbutton.cpp | 2 +- plugins/Clist_modern/src/modern_toolbar.cpp | 2 +- plugins/Clist_modern/src/modern_viewmodebar.cpp | 2 +- plugins/Clist_modern/src/modern_xptheme.cpp | 2 +- plugins/Clist_nicer/skineditor/skinedit_12.vcxproj | 8 +- plugins/Clist_nicer/skineditor/src/commonheaders.h | 3 +- plugins/Clist_nicer/src/Include/commonheaders.h | 2 +- plugins/Clist_nicer/src/Include/m_cln_skinedit.h | 169 --------------------- plugins/ExternalAPI/m_cln_skinedit.h | 169 +++++++++++++++++++++ plugins/ExternalAPI/m_skinbutton.h | 29 ++++ plugins/ExternalAPI/m_xpTheme.h | 19 +++ 19 files changed, 234 insertions(+), 233 deletions(-) delete mode 100644 plugins/Clist_modern/src/m_api/m_skinbutton.h delete mode 100644 plugins/Clist_modern/src/m_api/m_xpTheme.h delete mode 100644 plugins/Clist_nicer/src/Include/m_cln_skinedit.h create mode 100644 plugins/ExternalAPI/m_cln_skinedit.h create mode 100644 plugins/ExternalAPI/m_skinbutton.h create mode 100644 plugins/ExternalAPI/m_xpTheme.h (limited to 'plugins') diff --git a/plugins/Clist_modern/src/hdr/modern_clc.h b/plugins/Clist_modern/src/hdr/modern_clc.h index f5fb9b2222..6301cc1f9d 100644 --- a/plugins/Clist_modern/src/hdr/modern_clc.h +++ b/plugins/Clist_modern/src/hdr/modern_clc.h @@ -27,7 +27,7 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. #ifndef _CLC_H_ #define _CLC_H_ #include "modern_image_array.h" -#include "../m_api/m_xpTheme.h" +#include "m_xpTheme.h" #include "modern_defsettings.h" #include "modern_clist.h" diff --git a/plugins/Clist_modern/src/hdr/modern_statusbar.h b/plugins/Clist_modern/src/hdr/modern_statusbar.h index 2339ed2c51..2ac385b6d4 100644 --- a/plugins/Clist_modern/src/hdr/modern_statusbar.h +++ b/plugins/Clist_modern/src/hdr/modern_statusbar.h @@ -4,7 +4,7 @@ #define modern_statusbar_h__ #include "modern_commonprototypes.h" -#include "../m_api/m_xpTheme.h" +#include "m_xpTheme.h" int ModernDrawStatusBar(HWND hwnd, HDC hDC); int ModernDrawStatusBarWorker(HWND hWnd, HDC hDC); diff --git a/plugins/Clist_modern/src/m_api/m_skinbutton.h b/plugins/Clist_modern/src/m_api/m_skinbutton.h deleted file mode 100644 index 1ca5c38e6d..0000000000 --- a/plugins/Clist_modern/src/m_api/m_skinbutton.h +++ /dev/null @@ -1,29 +0,0 @@ -#include "m_button.h" - -#define MBM_UPDATETRANSPARENTFLAG WM_USER+52 -#define MBM_SETICOLIBHANDLE WM_USER+53 -#define MBM_REFRESHICOLIBICON WM_USER+54 - -#define BUTTONSETID WM_USER+55 -#define BUTTONDRAWINPARENT WM_USER+56 -#define BUTTONSETMARGINS WM_USER+57 - -#define SBF_ALIGN_TL_RIGHT 1 -#define SBF_ALIGN_TL_HCENTER 2 -#define SBF_ALIGN_TL_BOTTOM 4 -#define SBF_ALIGN_TL_VCENTER 8 - -#define SBF_ALIGN_BR_RIGHT 16 -#define SBF_ALIGN_BR_HCENTER 32 -#define SBF_ALIGN_BR_BOTTOM 64 -#define SBF_ALIGN_BR_VCENTER 128 - -#define SBF_CALL_ON_PRESS 256 - -// Params for draw flag at Repos function -#define SBRF_DO_NOT_DRAW 0 -#define SBRF_DO_REDRAW_ALL 1 -#define SBRF_DO_ALT_DRAW 2 -#define SBRF_REDRAW ( SBRF_DO_REDRAW_ALL|SBRF_DO_ALT_DRAW ) - -#define BUTTONNEEDREDRAW 1256 \ No newline at end of file diff --git a/plugins/Clist_modern/src/m_api/m_xpTheme.h b/plugins/Clist_modern/src/m_api/m_xpTheme.h deleted file mode 100644 index 90925470f4..0000000000 --- a/plugins/Clist_modern/src/m_api/m_xpTheme.h +++ /dev/null @@ -1,19 +0,0 @@ -/* Wrapper for XP theme */ -typedef void * XPTHANDLE; -typedef HANDLE HTHEME; - -XPTHANDLE xpt_AddThemeHandle(HWND hwnd, LPCWSTR className); -void xpt_FreeThemeHandle(XPTHANDLE xptHandle); -void xpt_FreeThemeForWindow(HWND hwnd); -BOOL xpt_IsValidHandle(XPTHANDLE xptHandle); -HRESULT xpt_DrawThemeBackground(XPTHANDLE xptHandle, HDC hdc, int type, int state, const RECT * sizeRect, const RECT * clipRect); -HRESULT xpt_DrawThemeParentBackground(HWND hWnd, HDC hdc, const RECT * sizeRect); -HRESULT xpt_DrawThemeText(XPTHANDLE xptHandle, HDC hdc, int type, int state, LPCTSTR lpStr, int len, DWORD flag1, DWORD flag2, const RECT * textRect); -BOOL xpt_IsThemeBackgroundPartiallyTransparent(XPTHANDLE xptHandle, int type, int state); -HRESULT xpt_DrawTheme(XPTHANDLE xptHandle, HWND hwnd, HDC hdc, int type, int state, const RECT *sizeRect, const RECT * clipRect); -BOOL xpt_IsThemed(XPTHANDLE xptHandle); -BOOL xpt_EnableThemeDialogTexture(HWND hwnd, DWORD flags); - -// next will be called only from one place -void XPThemesUnloadModule(); -void xpt_OnWM_THEMECHANGED(); diff --git a/plugins/Clist_modern/src/modern_clui.cpp b/plugins/Clist_modern/src/modern_clui.cpp index 3c4750bb19..ed66adfadf 100644 --- a/plugins/Clist_modern/src/modern_clui.cpp +++ b/plugins/Clist_modern/src/modern_clui.cpp @@ -24,7 +24,7 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. #include "hdr/modern_commonheaders.h" -#include "m_api/m_skinbutton.h" +#include "m_skinbutton.h" #include "hdr/modern_skinengine.h" #include "hdr/modern_statusbar.h" diff --git a/plugins/Clist_modern/src/modern_docking.cpp b/plugins/Clist_modern/src/modern_docking.cpp index b2c4e0f083..837bcfc797 100644 --- a/plugins/Clist_modern/src/modern_docking.cpp +++ b/plugins/Clist_modern/src/modern_docking.cpp @@ -25,7 +25,7 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. #include "hdr/modern_commonheaders.h" #include "hdr/modern_clist.h" #include "m_skin_eng.h" -#include "m_api/m_skinbutton.h" +#include "m_skinbutton.h" #include "hdr/modern_commonprototypes.h" #include "hdr/modern_sync.h" diff --git a/plugins/Clist_modern/src/modern_skinbutton.cpp b/plugins/Clist_modern/src/modern_skinbutton.cpp index d843175566..f9ba51083c 100644 --- a/plugins/Clist_modern/src/modern_skinbutton.cpp +++ b/plugins/Clist_modern/src/modern_skinbutton.cpp @@ -29,7 +29,7 @@ This file contains code related to new modern free positioned skinned buttons #include "hdr/modern_commonheaders.h" #include "hdr/modern_skinengine.h" #include "hdr/modern_clcpaint.h" -#include "m_api/m_skinbutton.h" +#include "m_skinbutton.h" #define MODERNSKINBUTTONCLASS "MirandaModernSkinButtonClass" BOOL ModernSkinButtonModuleIsLoaded = FALSE; diff --git a/plugins/Clist_modern/src/modern_skinselector.cpp b/plugins/Clist_modern/src/modern_skinselector.cpp index 7264c6d359..7d62758208 100644 --- a/plugins/Clist_modern/src/modern_skinselector.cpp +++ b/plugins/Clist_modern/src/modern_skinselector.cpp @@ -29,7 +29,7 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. #include "hdr/modern_skinselector.h" #include "hdr/modern_skinengine.h" #include "m_skin_eng.h" -#include "m_api/m_skinbutton.h" +#include "m_skinbutton.h" #include "hdr/modern_commonprototypes.h" /// IMPLEMENTATIONS diff --git a/plugins/Clist_modern/src/modern_tbbutton.cpp b/plugins/Clist_modern/src/modern_tbbutton.cpp index a7b30af19f..d5c6843322 100644 --- a/plugins/Clist_modern/src/modern_tbbutton.cpp +++ b/plugins/Clist_modern/src/modern_tbbutton.cpp @@ -1,6 +1,6 @@ #include "hdr/modern_commonheaders.h" #include "hdr/modern_commonprototypes.h" -#include "m_api/m_skinbutton.h" +#include "m_skinbutton.h" #include "hdr/modern_clcpaint.h" #include diff --git a/plugins/Clist_modern/src/modern_toolbar.cpp b/plugins/Clist_modern/src/modern_toolbar.cpp index 6db6d801dc..07195a35f2 100644 --- a/plugins/Clist_modern/src/modern_toolbar.cpp +++ b/plugins/Clist_modern/src/modern_toolbar.cpp @@ -26,7 +26,7 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. #include "hdr/modern_commonheaders.h" #include "hdr/modern_commonprototypes.h" -#include "./m_api/m_skinbutton.h" +#include "m_skinbutton.h" #include #include "hdr/modern_sync.h" diff --git a/plugins/Clist_modern/src/modern_viewmodebar.cpp b/plugins/Clist_modern/src/modern_viewmodebar.cpp index cbaf820fd8..57ae8d4969 100644 --- a/plugins/Clist_modern/src/modern_viewmodebar.cpp +++ b/plugins/Clist_modern/src/modern_viewmodebar.cpp @@ -29,7 +29,7 @@ $Id: viewmodes.c 2998 2006-06-01 07:11:52Z nightwish2004 $ #include "hdr/modern_commonheaders.h" #include "CLUIFrames/cluiframes.h" -#include "m_api/m_skinbutton.h" +#include "m_skinbutton.h" #define TIMERID_VIEWMODEEXPIRE 100 diff --git a/plugins/Clist_modern/src/modern_xptheme.cpp b/plugins/Clist_modern/src/modern_xptheme.cpp index ac8cecae7c..1d8fd910f5 100644 --- a/plugins/Clist_modern/src/modern_xptheme.cpp +++ b/plugins/Clist_modern/src/modern_xptheme.cpp @@ -1,6 +1,6 @@ #include "hdr/modern_commonheaders.h" #include "hdr/modern_commonprototypes.h" -#include "m_api/m_xpTheme.h" +#include "m_xpTheme.h" //statical diff --git a/plugins/Clist_nicer/skineditor/skinedit_12.vcxproj b/plugins/Clist_nicer/skineditor/skinedit_12.vcxproj index c8980ea262..c89759d6fa 100644 --- a/plugins/Clist_nicer/skineditor/skinedit_12.vcxproj +++ b/plugins/Clist_nicer/skineditor/skinedit_12.vcxproj @@ -78,7 +78,7 @@ Full OnlyExplicitInline Size - ..\..\..\include;%(AdditionalIncludeDirectories) + ..\..\..\include;..\..\ExternalAPI;%(AdditionalIncludeDirectories) NDEBUG;_WINDOWS;_USRDLL;%(PreprocessorDefinitions) true true @@ -107,7 +107,7 @@ Disabled - ..\..\..\include;%(AdditionalIncludeDirectories) + ..\..\..\include;..\..\ExternalAPI;%(AdditionalIncludeDirectories) _DEBUG;_WINDOWS;_USRDLL;%(PreprocessorDefinitions) EnableFastChecks MultiThreadedDebugDLL @@ -136,7 +136,7 @@ Full OnlyExplicitInline Size - ..\..\..\include\;%(AdditionalIncludeDirectories) + ..\..\..\include;..\..\ExternalAPI;%(AdditionalIncludeDirectories) NDEBUG;_WINDOWS;_USRDLL;%(PreprocessorDefinitions) true true @@ -165,7 +165,7 @@ Disabled - ..\..\..\include;%(AdditionalIncludeDirectories) + ..\..\..\include;..\..\ExternalAPI;%(AdditionalIncludeDirectories) _DEBUG;_WINDOWS;_USRDLL;%(PreprocessorDefinitions) EnableFastChecks MultiThreadedDebugDLL diff --git a/plugins/Clist_nicer/skineditor/src/commonheaders.h b/plugins/Clist_nicer/skineditor/src/commonheaders.h index 1563e24d18..1fb84deb9f 100644 --- a/plugins/Clist_nicer/skineditor/src/commonheaders.h +++ b/plugins/Clist_nicer/skineditor/src/commonheaders.h @@ -33,6 +33,7 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. #include #include -#include "../../src/include/m_cln_skinedit.h" +#include "m_cln_skinedit.h" + #include "Version.h" #include "skineditres.h" diff --git a/plugins/Clist_nicer/src/Include/commonheaders.h b/plugins/Clist_nicer/src/Include/commonheaders.h index fd0d4fda8a..dfa289636b 100644 --- a/plugins/Clist_nicer/src/Include/commonheaders.h +++ b/plugins/Clist_nicer/src/Include/commonheaders.h @@ -58,8 +58,8 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. #include #include +#include -#include "m_cln_skinedit.h" #include "resource.h" #include "Version.h" #include "extbackg.h" diff --git a/plugins/Clist_nicer/src/Include/m_cln_skinedit.h b/plugins/Clist_nicer/src/Include/m_cln_skinedit.h deleted file mode 100644 index b98be9b2ba..0000000000 --- a/plugins/Clist_nicer/src/Include/m_cln_skinedit.h +++ /dev/null @@ -1,169 +0,0 @@ - -/* - * services - */ - -#define MS_CLNSE_INVOKE "CLN_Skinedit/Invoke" -#define MS_CLNSE_FILLBYCURRENTSEL "CLN_Skinedit/FillByCurrentSel" - -/* - * data structs - */ - -typedef struct _tagImageItem { - char szName[40]; - HBITMAP hbm; - BYTE bLeft, bRight, bTop, bBottom; // sizing margins - BYTE alpha; - DWORD dwFlags; - HDC hdc; - HBITMAP hbmOld; - LONG inner_height, inner_width; - LONG width, height; - BLENDFUNCTION bf; - BYTE bStretch; - HBRUSH fillBrush; - LONG glyphMetrics[4]; - struct _tagImageItem *nextItem; -} ImageItem; - -typedef struct _tagButtonItem { - char szName[40]; - HWND hWnd; - LONG xOff, yOff; - LONG width, height; - ImageItem *imgNormal, *imgPressed, *imgHover; - LONG normalGlyphMetrics[4]; - LONG hoverGlyphMetrics[4]; - LONG pressedGlyphMetrics[4]; - DWORD dwFlags, dwStockFlags; - DWORD uId; - TCHAR szTip[256]; - char szService[256]; - char szModule[256], szSetting[256]; - BYTE bValuePush[256], bValueRelease[256]; - DWORD type; - void (*pfnAction)(struct _tagButtonItem *item, HWND hwndDlg, struct MessageWindowData *dat, HWND hwndItem); - void (*pfnCallback)(struct _tagButtonItem *item, HWND hwndDlg, struct MessageWindowData *dat, HWND hwndItem); - TCHAR tszLabel[40]; - struct _tagButtonItem *nextItem; -} ButtonItem; - -typedef struct { - char szName[40]; - char szDBname[40]; - int statusID; - - BYTE GRADIENT; - BYTE CORNER; - - DWORD COLOR; - DWORD COLOR2; - - BYTE COLOR2_TRANSPARENT; - - DWORD TEXTCOLOR; - - int ALPHA; - - int MARGIN_LEFT; - int MARGIN_TOP; - int MARGIN_RIGHT; - int MARGIN_BOTTOM; - BYTE IGNORED; - DWORD BORDERSTYLE; - ImageItem *imageItem; -} StatusItems_t; - -typedef struct { - BOOL bGRADIENT; - BOOL bCORNER; - BOOL bCOLOR; - BOOL bCOLOR2; - BOOL bCOLOR2_TRANSPARENT; - BOOL bTEXTCOLOR; - BOOL bALPHA; - BOOL bMARGIN_LEFT; - BOOL bMARGIN_TOP; - BOOL bMARGIN_RIGHT; - BOOL bMARGIN_BOTTOM; - BOOL bIGNORED; - BOOL bBORDERSTYLE; -} ChangedSItems_t; - -typedef struct _tagSkinDescription { - DWORD cbSize; - StatusItems_t **StatusItems; - int lastItem; - int firstItem; - char szModule[100]; - HWND hWndParent, hWndTab; - HWND hwndCLUI; - HWND hwndSkinEdit; /* out param */ - HWND hwndImageEdit; /* out param */ - HMENU hMenuItems; - void (*pfnSaveCompleteStruct)(void); - void (*pfnClcOptionsChanged )(void); - void* (*pfnMalloc)(unsigned int); - void (*pfnFree)(void); - void* (*pfnRealloc)(void *, unsigned int); - void* reserved[20]; -} SKINDESCRIPTION; - -// defines - -// FLAGS -#define CORNER_NONE 0 -#define CORNER_ACTIVE 1 -#define CORNER_TL 2 -#define CORNER_TR 4 -#define CORNER_BR 8 -#define CORNER_BL 16 - -#define GRADIENT_NONE 0 -#define GRADIENT_ACTIVE 1 -#define GRADIENT_LR 2 -#define GRADIENT_RL 4 -#define GRADIENT_TB 8 -#define GRADIENT_BT 16 - -#define IMAGE_PERPIXEL_ALPHA 1 -#define IMAGE_FLAG_DIVIDED 2 -#define IMAGE_FILLSOLID 4 -#define IMAGE_GLYPH 8 - -#define IMAGE_STRETCH_V 1 -#define IMAGE_STRETCH_H 2 -#define IMAGE_STRETCH_B 4 - -#define BUTTON_ISINTERNAL 1 -#define BUTTON_ISTOGGLE 2 -#define BUTTON_ISSERVICE 4 -#define BUTTON_ISPROTOSERVICE 8 -#define BUTTON_PASSHCONTACTW 16 -#define BUTTON_PASSHCONTACTL 32 -#define BUTTON_ISDBACTION 64 -#define BUTTON_ISCONTACTDBACTION 128 -#define BUTTON_DBACTIONONCONTACT 256 -#define BUTTON_ISSIDEBAR 512 -#define BUTTON_NORMALGLYPHISICON 1024 -#define BUTTON_PRESSEDGLYPHISICON 2048 -#define BUTTON_HOVERGLYPHISICON 4096 -#define BUTTON_HASLABEL 8192 - -#define CLCDEFAULT_GRADIENT 0 -#define CLCDEFAULT_CORNER 0 - -#define CLCDEFAULT_COLOR 0xd0d0d0 -#define CLCDEFAULT_COLOR2 0xd0d0d0 - -#define CLCDEFAULT_TEXTCOLOR 0x000000 - -#define CLCDEFAULT_COLOR2_TRANSPARENT 1 - -#define CLCDEFAULT_ALPHA 100 -#define CLCDEFAULT_MRGN_LEFT 0 -#define CLCDEFAULT_MRGN_TOP 0 -#define CLCDEFAULT_MRGN_RIGHT 0 -#define CLCDEFAULT_MRGN_BOTTOM 0 -#define CLCDEFAULT_IGNORE 1 diff --git a/plugins/ExternalAPI/m_cln_skinedit.h b/plugins/ExternalAPI/m_cln_skinedit.h new file mode 100644 index 0000000000..b98be9b2ba --- /dev/null +++ b/plugins/ExternalAPI/m_cln_skinedit.h @@ -0,0 +1,169 @@ + +/* + * services + */ + +#define MS_CLNSE_INVOKE "CLN_Skinedit/Invoke" +#define MS_CLNSE_FILLBYCURRENTSEL "CLN_Skinedit/FillByCurrentSel" + +/* + * data structs + */ + +typedef struct _tagImageItem { + char szName[40]; + HBITMAP hbm; + BYTE bLeft, bRight, bTop, bBottom; // sizing margins + BYTE alpha; + DWORD dwFlags; + HDC hdc; + HBITMAP hbmOld; + LONG inner_height, inner_width; + LONG width, height; + BLENDFUNCTION bf; + BYTE bStretch; + HBRUSH fillBrush; + LONG glyphMetrics[4]; + struct _tagImageItem *nextItem; +} ImageItem; + +typedef struct _tagButtonItem { + char szName[40]; + HWND hWnd; + LONG xOff, yOff; + LONG width, height; + ImageItem *imgNormal, *imgPressed, *imgHover; + LONG normalGlyphMetrics[4]; + LONG hoverGlyphMetrics[4]; + LONG pressedGlyphMetrics[4]; + DWORD dwFlags, dwStockFlags; + DWORD uId; + TCHAR szTip[256]; + char szService[256]; + char szModule[256], szSetting[256]; + BYTE bValuePush[256], bValueRelease[256]; + DWORD type; + void (*pfnAction)(struct _tagButtonItem *item, HWND hwndDlg, struct MessageWindowData *dat, HWND hwndItem); + void (*pfnCallback)(struct _tagButtonItem *item, HWND hwndDlg, struct MessageWindowData *dat, HWND hwndItem); + TCHAR tszLabel[40]; + struct _tagButtonItem *nextItem; +} ButtonItem; + +typedef struct { + char szName[40]; + char szDBname[40]; + int statusID; + + BYTE GRADIENT; + BYTE CORNER; + + DWORD COLOR; + DWORD COLOR2; + + BYTE COLOR2_TRANSPARENT; + + DWORD TEXTCOLOR; + + int ALPHA; + + int MARGIN_LEFT; + int MARGIN_TOP; + int MARGIN_RIGHT; + int MARGIN_BOTTOM; + BYTE IGNORED; + DWORD BORDERSTYLE; + ImageItem *imageItem; +} StatusItems_t; + +typedef struct { + BOOL bGRADIENT; + BOOL bCORNER; + BOOL bCOLOR; + BOOL bCOLOR2; + BOOL bCOLOR2_TRANSPARENT; + BOOL bTEXTCOLOR; + BOOL bALPHA; + BOOL bMARGIN_LEFT; + BOOL bMARGIN_TOP; + BOOL bMARGIN_RIGHT; + BOOL bMARGIN_BOTTOM; + BOOL bIGNORED; + BOOL bBORDERSTYLE; +} ChangedSItems_t; + +typedef struct _tagSkinDescription { + DWORD cbSize; + StatusItems_t **StatusItems; + int lastItem; + int firstItem; + char szModule[100]; + HWND hWndParent, hWndTab; + HWND hwndCLUI; + HWND hwndSkinEdit; /* out param */ + HWND hwndImageEdit; /* out param */ + HMENU hMenuItems; + void (*pfnSaveCompleteStruct)(void); + void (*pfnClcOptionsChanged )(void); + void* (*pfnMalloc)(unsigned int); + void (*pfnFree)(void); + void* (*pfnRealloc)(void *, unsigned int); + void* reserved[20]; +} SKINDESCRIPTION; + +// defines + +// FLAGS +#define CORNER_NONE 0 +#define CORNER_ACTIVE 1 +#define CORNER_TL 2 +#define CORNER_TR 4 +#define CORNER_BR 8 +#define CORNER_BL 16 + +#define GRADIENT_NONE 0 +#define GRADIENT_ACTIVE 1 +#define GRADIENT_LR 2 +#define GRADIENT_RL 4 +#define GRADIENT_TB 8 +#define GRADIENT_BT 16 + +#define IMAGE_PERPIXEL_ALPHA 1 +#define IMAGE_FLAG_DIVIDED 2 +#define IMAGE_FILLSOLID 4 +#define IMAGE_GLYPH 8 + +#define IMAGE_STRETCH_V 1 +#define IMAGE_STRETCH_H 2 +#define IMAGE_STRETCH_B 4 + +#define BUTTON_ISINTERNAL 1 +#define BUTTON_ISTOGGLE 2 +#define BUTTON_ISSERVICE 4 +#define BUTTON_ISPROTOSERVICE 8 +#define BUTTON_PASSHCONTACTW 16 +#define BUTTON_PASSHCONTACTL 32 +#define BUTTON_ISDBACTION 64 +#define BUTTON_ISCONTACTDBACTION 128 +#define BUTTON_DBACTIONONCONTACT 256 +#define BUTTON_ISSIDEBAR 512 +#define BUTTON_NORMALGLYPHISICON 1024 +#define BUTTON_PRESSEDGLYPHISICON 2048 +#define BUTTON_HOVERGLYPHISICON 4096 +#define BUTTON_HASLABEL 8192 + +#define CLCDEFAULT_GRADIENT 0 +#define CLCDEFAULT_CORNER 0 + +#define CLCDEFAULT_COLOR 0xd0d0d0 +#define CLCDEFAULT_COLOR2 0xd0d0d0 + +#define CLCDEFAULT_TEXTCOLOR 0x000000 + +#define CLCDEFAULT_COLOR2_TRANSPARENT 1 + +#define CLCDEFAULT_ALPHA 100 +#define CLCDEFAULT_MRGN_LEFT 0 +#define CLCDEFAULT_MRGN_TOP 0 +#define CLCDEFAULT_MRGN_RIGHT 0 +#define CLCDEFAULT_MRGN_BOTTOM 0 +#define CLCDEFAULT_IGNORE 1 diff --git a/plugins/ExternalAPI/m_skinbutton.h b/plugins/ExternalAPI/m_skinbutton.h new file mode 100644 index 0000000000..1ca5c38e6d --- /dev/null +++ b/plugins/ExternalAPI/m_skinbutton.h @@ -0,0 +1,29 @@ +#include "m_button.h" + +#define MBM_UPDATETRANSPARENTFLAG WM_USER+52 +#define MBM_SETICOLIBHANDLE WM_USER+53 +#define MBM_REFRESHICOLIBICON WM_USER+54 + +#define BUTTONSETID WM_USER+55 +#define BUTTONDRAWINPARENT WM_USER+56 +#define BUTTONSETMARGINS WM_USER+57 + +#define SBF_ALIGN_TL_RIGHT 1 +#define SBF_ALIGN_TL_HCENTER 2 +#define SBF_ALIGN_TL_BOTTOM 4 +#define SBF_ALIGN_TL_VCENTER 8 + +#define SBF_ALIGN_BR_RIGHT 16 +#define SBF_ALIGN_BR_HCENTER 32 +#define SBF_ALIGN_BR_BOTTOM 64 +#define SBF_ALIGN_BR_VCENTER 128 + +#define SBF_CALL_ON_PRESS 256 + +// Params for draw flag at Repos function +#define SBRF_DO_NOT_DRAW 0 +#define SBRF_DO_REDRAW_ALL 1 +#define SBRF_DO_ALT_DRAW 2 +#define SBRF_REDRAW ( SBRF_DO_REDRAW_ALL|SBRF_DO_ALT_DRAW ) + +#define BUTTONNEEDREDRAW 1256 \ No newline at end of file diff --git a/plugins/ExternalAPI/m_xpTheme.h b/plugins/ExternalAPI/m_xpTheme.h new file mode 100644 index 0000000000..90925470f4 --- /dev/null +++ b/plugins/ExternalAPI/m_xpTheme.h @@ -0,0 +1,19 @@ +/* Wrapper for XP theme */ +typedef void * XPTHANDLE; +typedef HANDLE HTHEME; + +XPTHANDLE xpt_AddThemeHandle(HWND hwnd, LPCWSTR className); +void xpt_FreeThemeHandle(XPTHANDLE xptHandle); +void xpt_FreeThemeForWindow(HWND hwnd); +BOOL xpt_IsValidHandle(XPTHANDLE xptHandle); +HRESULT xpt_DrawThemeBackground(XPTHANDLE xptHandle, HDC hdc, int type, int state, const RECT * sizeRect, const RECT * clipRect); +HRESULT xpt_DrawThemeParentBackground(HWND hWnd, HDC hdc, const RECT * sizeRect); +HRESULT xpt_DrawThemeText(XPTHANDLE xptHandle, HDC hdc, int type, int state, LPCTSTR lpStr, int len, DWORD flag1, DWORD flag2, const RECT * textRect); +BOOL xpt_IsThemeBackgroundPartiallyTransparent(XPTHANDLE xptHandle, int type, int state); +HRESULT xpt_DrawTheme(XPTHANDLE xptHandle, HWND hwnd, HDC hdc, int type, int state, const RECT *sizeRect, const RECT * clipRect); +BOOL xpt_IsThemed(XPTHANDLE xptHandle); +BOOL xpt_EnableThemeDialogTexture(HWND hwnd, DWORD flags); + +// next will be called only from one place +void XPThemesUnloadModule(); +void xpt_OnWM_THEMECHANGED(); -- cgit v1.2.3