diff options
author | Kirill Volinsky <mataes2007@gmail.com> | 2014-12-14 21:30:16 +0000 |
---|---|---|
committer | Kirill Volinsky <mataes2007@gmail.com> | 2014-12-14 21:30:16 +0000 |
commit | c730f12da81f636ecf65aa656a46b9337daaa37a (patch) | |
tree | 0b069d59b6366447e0a0d40982ac610fbe86d9a7 /plugins/Clist_modern/src/hdr | |
parent | 91867c03b57bbf85eae500475683c16da4ec3a9c (diff) |
Clist_modern: changed warning lavel to w4
git-svn-id: http://svn.miranda-ng.org/main/trunk@11425 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c
Diffstat (limited to 'plugins/Clist_modern/src/hdr')
21 files changed, 771 insertions, 709 deletions
diff --git a/plugins/Clist_modern/src/hdr/modern_cache_funcs.h b/plugins/Clist_modern/src/hdr/modern_cache_funcs.h index 24dc9db73d..b3fc754b88 100644 --- a/plugins/Clist_modern/src/hdr/modern_cache_funcs.h +++ b/plugins/Clist_modern/src/hdr/modern_cache_funcs.h @@ -39,8 +39,8 @@ void Cache_GetThirdLineText(struct SHORTDATA *dat, ClcCacheEntry *pdnce); void Cache_GetAvatar(ClcData *dat, ClcContact *contact);
void Cache_GetTimezone(ClcData *dat, MCONTACT hContact);
int Cache_GetLineText(ClcCacheEntry *pdnce, int type, LPTSTR text, int text_size, TCHAR *variable_text, BOOL xstatus_has_priority,
- BOOL show_status_if_no_away, BOOL show_listening_if_no_away, BOOL use_name_and_message_for_xstatus,
- BOOL pdnce_time_show_only_if_different);
+ BOOL show_status_if_no_away, BOOL show_listening_if_no_away, BOOL use_name_and_message_for_xstatus,
+ BOOL pdnce_time_show_only_if_different);
void amRequestAwayMsg(MCONTACT hContact);
diff --git a/plugins/Clist_modern/src/hdr/modern_callproc.h b/plugins/Clist_modern/src/hdr/modern_callproc.h index 4e3df47257..824d10e6d9 100644 --- a/plugins/Clist_modern/src/hdr/modern_callproc.h +++ b/plugins/Clist_modern/src/hdr/modern_callproc.h @@ -4,125 +4,141 @@ namespace call {
#include <windows.h>
-//////////////////////////////////////////////////////////////////////////
-// USE AS
-// ret = call::sync( proc, param1, param2 ... etc)
-//////////////////////////////////////////////////////////////////////////
-// internal realization
-enum ASYNC_T { ASYNC = 0, SYNC };
-int __ProcessCall( class __baseCall * pStorage, ASYNC_T async );
-
-class __baseCall { public: virtual int __DoCallStorageProc() =0; virtual ~__baseCall() {}; };
-template< class R > class _callParams0 : public __baseCall
-{
-public:
- R(*_proc)();
- _callParams0( R (*proc)()) : _proc(proc){};
- int __DoCallStorageProc() { return (int)_proc(); }
-};
-
-template<> class _callParams0<void> : public __baseCall
-{
-public:
- void(*_proc)();
- _callParams0( void (*proc)()) : _proc(proc){};
- int __DoCallStorageProc() { _proc(); return 0; }
-};
-
-template< class R, class A> class _callParams1 : public __baseCall
-{
-public:
- R(*_proc)(A); A _a;
- _callParams1( R(*proc)(A), A a) : _proc(proc), _a(a) {};
- int __DoCallStorageProc() { return (int)_proc(_a); }
-};
-
-template<class A> class _callParams1<void, A> : public __baseCall
-{
-public:
- void(*_proc)(A); A _a;
- _callParams1( void(*proc)(A), A a) : _proc(proc), _a(a) {};
- int __DoCallStorageProc() { _proc(_a); return 0; }
-};
-
-template< class R, class A, class B> class _callParams2 : public __baseCall
-{
-public:
- R (*_proc)(A, B); A _a; B _b;
- _callParams2( R (*proc)(A, B), A a, B b) : _proc(proc), _a(a), _b(b) {};
- int __DoCallStorageProc() { return (int)_proc(_a, _b); }
-};
-
-template< class A, class B> class _callParams2<void, A, B> : public __baseCall
-{
-public:
- void (*_proc)(A, B); A _a; B _b;
- _callParams2( void (*proc)(A, B), A a, B b) : _proc(proc), _a(a), _b(b) {};
- int __DoCallStorageProc() { _proc(_a, _b); return 0; }
-};
-
-template< class R, class A, class B, class C> class _callParams3 : public __baseCall
-{
-public:
- R (*_proc)(A, B, C); A _a; B _b; C _c;
- _callParams3( R (*proc)(A, B, C), A a, B b, C c ) : _proc(proc), _a(a), _b(b), _c(c) {};
- int __DoCallStorageProc() { return (int)_proc(_a,_b,_c); }
-};
-
-template< class A, class B, class C> class _callParams3<void, A, B, C> : public __baseCall
-{
-public:
- void (*_proc)(A, B, C); A _a; B _b; C _c;
- _callParams3( void (*proc)(A, B, C), A a, B b, C c ) : _proc(proc), _a(a), _b(b), _c(c) {};
- int __DoCallStorageProc() { _proc(_a,_b,_c); return 0;}
-};
-
-template < class R > R __DoCall( R(*__proc)(), ASYNC_T sync_mode )
-{
- typedef _callParams0< R > callClass;
- callClass * storage = new callClass( __proc );
- return (R) call::__ProcessCall( storage, sync_mode );
-};
-
-template < class R, class A > R __DoCall( R(*__proc)( A ), A a, ASYNC_T sync_mode )
-{
- typedef _callParams1< R, A > callClass;
- callClass * storage = new callClass( __proc, a );
- return (R)__ProcessCall( storage, sync_mode );
-};
-
-
-template < class R, class A, class B > R __DoCall( R(*__proc)( A, B ), A a, B b, ASYNC_T sync_mode )
-{
- typedef _callParams2< R, A, B > callClass;
- callClass * storage = new callClass( __proc, a, b);
- return (R)__ProcessCall( storage, sync_mode );
-};
-
-
-template < class R, class A, class B, class C > R __DoCall( R(*__proc)( A, B, C ), A a, B b, C c, ASYNC_T sync_mode )
-{
- typedef _callParams3< R, A, B, C > callClass;
- callClass * storage = new callClass( __proc, a, b, c);
- return (R)__ProcessCall( storage, sync_mode );
-};
-
-
-template < class R > R sync( R(*_proc)())
-{ return __DoCall(_proc, SYNC); };
-template < class R, class A > R sync( R(*_proc)( A ), A a )
-{ return __DoCall(_proc, a, SYNC); };
-template < class R, class A, class B > R sync( R(*_proc)( A,B), A a, B b )
-{ return __DoCall(_proc, a, b, SYNC); };
-template < class R, class A, class B, class C > R sync( R(*_proc)( A,B,C ), A a, B b, C c)
-{ return __DoCall(_proc, a, b, c, SYNC); };
-template < class R > int async( R(*_proc)())
-{ return __DoCall(_proc, ASYNC); };
-template < class R, class A > R async( R(*_proc)( A ), A a )
-{ return __DoCall(_proc, a, ASYNC); };
-template < class R, class A, class B > R async( R(*_proc)( A,B), A a, B b )
-{ return __DoCall(_proc, a, b, ASYNC); };
-template < class R, class A, class B, class C > R async( R(*_proc)( A,B,C ), A a, B b, C c)
-{ return __DoCall(_proc, a, b, c, ASYNC); };
+ //////////////////////////////////////////////////////////////////////////
+ // USE AS
+ // ret = call::sync( proc, param1, param2 ... etc)
+ //////////////////////////////////////////////////////////////////////////
+ // internal realization
+ enum ASYNC_T { ASYNC = 0, SYNC };
+ int __ProcessCall(class __baseCall * pStorage, ASYNC_T async);
+
+ class __baseCall { public: virtual int __DoCallStorageProc() = 0; virtual ~__baseCall() {}; };
+ template< class R > class _callParams0 : public __baseCall
+ {
+ public:
+ R(*_proc)();
+ _callParams0(R(*proc)()) : _proc(proc){};
+ int __DoCallStorageProc() { return (int)_proc(); }
+ };
+
+ template<> class _callParams0<void> : public __baseCall
+ {
+ public:
+ void(*_proc)();
+ _callParams0(void(*proc)()) : _proc(proc){};
+ int __DoCallStorageProc() { _proc(); return 0; }
+ };
+
+ template< class R, class A> class _callParams1 : public __baseCall
+ {
+ public:
+ R(*_proc)(A); A _a;
+ _callParams1(R(*proc)(A), A a) : _proc(proc), _a(a) {};
+ int __DoCallStorageProc() { return (int)_proc(_a); }
+ };
+
+ template<class A> class _callParams1<void, A> : public __baseCall
+ {
+ public:
+ void(*_proc)(A); A _a;
+ _callParams1(void(*proc)(A), A a) : _proc(proc), _a(a) {};
+ int __DoCallStorageProc() { _proc(_a); return 0; }
+ };
+
+ template< class R, class A, class B> class _callParams2 : public __baseCall
+ {
+ public:
+ R(*_proc)(A, B); A _a; B _b;
+ _callParams2(R(*proc)(A, B), A a, B b) : _proc(proc), _a(a), _b(b) {};
+ int __DoCallStorageProc() { return (int)_proc(_a, _b); }
+ };
+
+ template< class A, class B> class _callParams2<void, A, B> : public __baseCall
+ {
+ public:
+ void(*_proc)(A, B); A _a; B _b;
+ _callParams2(void(*proc)(A, B), A a, B b) : _proc(proc), _a(a), _b(b) {};
+ int __DoCallStorageProc() { _proc(_a, _b); return 0; }
+ };
+
+ template< class R, class A, class B, class C> class _callParams3 : public __baseCall
+ {
+ public:
+ R(*_proc)(A, B, C); A _a; B _b; C _c;
+ _callParams3(R(*proc)(A, B, C), A a, B b, C c) : _proc(proc), _a(a), _b(b), _c(c) {};
+ int __DoCallStorageProc() { return (int)_proc(_a, _b, _c); }
+ };
+
+ template< class A, class B, class C> class _callParams3<void, A, B, C> : public __baseCall
+ {
+ public:
+ void(*_proc)(A, B, C); A _a; B _b; C _c;
+ _callParams3(void(*proc)(A, B, C), A a, B b, C c) : _proc(proc), _a(a), _b(b), _c(c) {};
+ int __DoCallStorageProc() { _proc(_a, _b, _c); return 0; }
+ };
+
+ template < class R > R __DoCall(R(*__proc)(), ASYNC_T sync_mode)
+ {
+ typedef _callParams0< R > callClass;
+ callClass * storage = new callClass(__proc);
+ return (R)call::__ProcessCall(storage, sync_mode);
+ };
+
+ template < class R, class A > R __DoCall(R(*__proc)(A), A a, ASYNC_T sync_mode)
+ {
+ typedef _callParams1< R, A > callClass;
+ callClass * storage = new callClass(__proc, a);
+ return (R)__ProcessCall(storage, sync_mode);
+ };
+
+
+ template < class R, class A, class B > R __DoCall(R(*__proc)(A, B), A a, B b, ASYNC_T sync_mode)
+ {
+ typedef _callParams2< R, A, B > callClass;
+ callClass * storage = new callClass(__proc, a, b);
+ return (R)__ProcessCall(storage, sync_mode);
+ };
+
+
+ template < class R, class A, class B, class C > R __DoCall(R(*__proc)(A, B, C), A a, B b, C c, ASYNC_T sync_mode)
+ {
+ typedef _callParams3< R, A, B, C > callClass;
+ callClass * storage = new callClass(__proc, a, b, c);
+ return (R)__ProcessCall(storage, sync_mode);
+ };
+
+
+ template < class R > R sync(R(*_proc)())
+ {
+ return __DoCall(_proc, SYNC);
+ };
+ template < class R, class A > R sync(R(*_proc)(A), A a)
+ {
+ return __DoCall(_proc, a, SYNC);
+ };
+ template < class R, class A, class B > R sync(R(*_proc)(A, B), A a, B b)
+ {
+ return __DoCall(_proc, a, b, SYNC);
+ };
+ template < class R, class A, class B, class C > R sync(R(*_proc)(A, B, C), A a, B b, C c)
+ {
+ return __DoCall(_proc, a, b, c, SYNC);
+ };
+ template < class R > int async(R(*_proc)())
+ {
+ return __DoCall(_proc, ASYNC);
+ };
+ template < class R, class A > R async(R(*_proc)(A), A a)
+ {
+ return __DoCall(_proc, a, ASYNC);
+ };
+ template < class R, class A, class B > R async(R(*_proc)(A, B), A a, B b)
+ {
+ return __DoCall(_proc, a, b, ASYNC);
+ };
+ template < class R, class A, class B, class C > R async(R(*_proc)(A, B, C), A a, B b, C c)
+ {
+ return __DoCall(_proc, a, b, c, ASYNC);
+ };
}; // namespace call
#endif // modern_callproc_h__
diff --git a/plugins/Clist_modern/src/hdr/modern_clc.h b/plugins/Clist_modern/src/hdr/modern_clc.h index 1ec9a4dc44..ef47a3dc21 100644 --- a/plugins/Clist_modern/src/hdr/modern_clc.h +++ b/plugins/Clist_modern/src/hdr/modern_clc.h @@ -89,7 +89,7 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. #define TIMERID_FIRST TIMERID_RENAME
#define TIMERID_LAST TIMERID_RECALCSCROLLBAR
-void clcSetDelayTimer( UINT_PTR uIDEvent, HWND hwnd, int nDelay = -1);
+void clcSetDelayTimer(UINT_PTR uIDEvent, HWND hwnd, int nDelay = -1);
#define FONTID_CONTACTS 0
#define FONTID_INVIS 1
@@ -186,7 +186,7 @@ typedef struct tagClcContactTextPiece } ClcContactTextPiece;
enum {
- CIT_PAINT_END=0, //next items are invalids
+ CIT_PAINT_END = 0, //next items are invalids
CIT_AVATAR, // 1
CIT_ICON, // 2
CIT_TEXT, // 3 //the contact name or group name
@@ -195,7 +195,7 @@ enum { CIT_TIME, // 6
CIT_CHECKBOX, // 7
CIT_SELECTION, // 8
- CIT_EXTRA=64 //use bit compare for extra icon, the mask &0x3F will return number of extra icon
+ CIT_EXTRA = 64 //use bit compare for extra icon, the mask &0x3F will return number of extra icon
};
struct tContactItems
@@ -232,7 +232,7 @@ struct ClcContact : public ClcContactBase // For extended layout
BYTE ext_nItemsNum;
BOOL ext_fItemsValid;
- tContactItems ext_mpItemsDesc[EXTRA_ICON_COUNT+10]; //up to 10 items
+ tContactItems ext_mpItemsDesc[EXTRA_ICON_COUNT + 10]; //up to 10 items
__forceinline bool isChat() const
{
@@ -242,7 +242,7 @@ struct ClcContact : public ClcContactBase struct ClcModernFontInfo {
HFONT hFont;
- int fontHeight,changed;
+ int fontHeight, changed;
COLORREF colour;
BYTE effect;
COLORREF effectColour1;
@@ -342,7 +342,7 @@ struct ClcData : public ClcDataBase BOOL third_line_show_status_if_no_away;
BOOL third_line_show_listening_if_no_away;
BOOL third_line_use_name_and_message_for_xstatus;
- struct ClcModernFontInfo fontModernInfo[FONTID_MODERN_MAX+1];
+ struct ClcModernFontInfo fontModernInfo[FONTID_MODERN_MAX + 1];
HWND hWnd;
BYTE menuOwnerType;
int menuOwnerID;
@@ -400,48 +400,48 @@ typedef struct tagOVERLAYICONINFO void ClcOptionsChanged(void);
//clcidents.c
-int cliGetRowsPriorTo(ClcGroup *group,ClcGroup *subgroup,int contactIndex);
+int cliGetRowsPriorTo(ClcGroup *group, ClcGroup *subgroup, int contactIndex);
int FindItem(HWND hwnd, ClcData *dat, DWORD hItem, ClcContact **contact, ClcGroup **subgroup, int *isVisible, BOOL isIgnoreSubcontacts);
-int cliGetRowByIndex(ClcData *dat,int testindex,ClcContact **contact,ClcGroup **subgroup);
+int cliGetRowByIndex(ClcData *dat, int testindex, ClcContact **contact, ClcGroup **subgroup);
HANDLE ContactToHItem(ClcContact *contact);
-HANDLE ContactToItemHandle(ClcContact *contact,DWORD *nmFlags);
+HANDLE ContactToItemHandle(ClcContact *contact, DWORD *nmFlags);
void ClearRowByIndexCache();
//clcitems.c
-ClcGroup *cli_AddGroup(HWND hwnd,ClcData *dat,const TCHAR *szName,DWORD flags,int groupId,int calcTotalMembers);
+ClcGroup *cli_AddGroup(HWND hwnd, ClcData *dat, const TCHAR *szName, DWORD flags, int groupId, int calcTotalMembers);
void cli_FreeGroup(ClcGroup *group);
-int cli_AddInfoItemToGroup(ClcGroup *group,int flags,const TCHAR *pszText);
+int cli_AddInfoItemToGroup(ClcGroup *group, int flags, const TCHAR *pszText);
void cliRebuildEntireList(HWND hwnd, ClcData *dat);
void cli_DeleteItemFromTree(HWND hwnd, MCONTACT hItem);
-void cli_AddContactToTree(HWND hwnd,ClcData *dat,MCONTACT hContact,int updateTotalCount,int checkHideOffline);
-void cli_SortCLC(HWND hwnd,ClcData *dat,int useInsertionSort);
-int GetNewSelection(ClcGroup *group,int selection, int direction);
+void cli_AddContactToTree(HWND hwnd, ClcData *dat, MCONTACT hContact, int updateTotalCount, int checkHideOffline);
+void cli_SortCLC(HWND hwnd, ClcData *dat, int useInsertionSort);
+int GetNewSelection(ClcGroup *group, int selection, int direction);
//clcmsgs.c
-LRESULT cli_ProcessExternalMessages(HWND hwnd,ClcData *dat,UINT msg,WPARAM wParam, LPARAM lParam);
+LRESULT cli_ProcessExternalMessages(HWND hwnd, ClcData *dat, UINT msg, WPARAM wParam, LPARAM lParam);
//clcutils.c
-void cliRecalcScrollBar(HWND hwnd,ClcData *dat);
-void cliBeginRenameSelection(HWND hwnd,ClcData *dat);
-int cliHitTest(HWND hwnd,ClcData *dat,int testx,int testy,ClcContact **contact,ClcGroup **group,DWORD *flags);
-void cliScrollTo(HWND hwnd,ClcData *dat,int desty,int noSmooth);
-int GetDropTargetInformation(HWND hwnd,ClcData *dat,POINT pt);
-void LoadCLCOptions(HWND hwnd,ClcData *dat, BOOL bFirst);
+void cliRecalcScrollBar(HWND hwnd, ClcData *dat);
+void cliBeginRenameSelection(HWND hwnd, ClcData *dat);
+int cliHitTest(HWND hwnd, ClcData *dat, int testx, int testy, ClcContact **contact, ClcGroup **group, DWORD *flags);
+void cliScrollTo(HWND hwnd, ClcData *dat, int desty, int noSmooth);
+int GetDropTargetInformation(HWND hwnd, ClcData *dat, POINT pt);
+void LoadCLCOptions(HWND hwnd, ClcData *dat, BOOL bFirst);
//clcpaint.c
-void CLCPaint_cliPaintClc(HWND hwnd,ClcData *dat,HDC hdc,RECT *rcPaint);
+void CLCPaint_cliPaintClc(HWND hwnd, ClcData *dat, HDC hdc, RECT *rcPaint);
//clcopts.c
int ClcOptInit(WPARAM wParam, LPARAM lParam);
DWORD GetDefaultExStyle(void);
-void GetFontSetting(int i,LOGFONT *lf,COLORREF *colour,BYTE *effect, COLORREF *eColour1,COLORREF *eColour2);
+void GetFontSetting(int i, LOGFONT *lf, COLORREF *colour, BYTE *effect, COLORREF *eColour1, COLORREF *eColour2);
//clistsettings.c
-TCHAR * GetContactDisplayNameW(MCONTACT hContact, int mode );
+TCHAR * GetContactDisplayNameW(MCONTACT hContact, int mode);
//groups.c
-TCHAR* GetGroupNameTS( int idx, DWORD* pdwFlags );
+TCHAR* GetGroupNameTS(int idx, DWORD* pdwFlags);
int RenameGroupT(WPARAM groupID, LPARAM newName);
int GetContactCachedStatus(MCONTACT hContact);
diff --git a/plugins/Clist_modern/src/hdr/modern_clcpaint.h b/plugins/Clist_modern/src/hdr/modern_clcpaint.h index 97c299fdbe..879452125f 100644 --- a/plugins/Clist_modern/src/hdr/modern_clcpaint.h +++ b/plugins/Clist_modern/src/hdr/modern_clcpaint.h @@ -9,15 +9,15 @@ public: CLCPaint();
~CLCPaint() {};
- CLINTERFACE void cliPaintClc(HWND hwnd, ClcData *dat, HDC hdc, RECT *rcPaint);
- CLINTERFACE tPaintCallbackProc PaintCallbackProc(HWND hWnd, HDC hDC, RECT *rcPaint, HRGN rgn, DWORD dFlags, void * CallBackData);
+ CLINTERFACE void cliPaintClc(HWND hwnd, ClcData *dat, HDC hdc, RECT *rcPaint);
+ CLINTERFACE tPaintCallbackProc PaintCallbackProc(HWND hWnd, HDC hDC, RECT *rcPaint, HRGN rgn, DWORD dFlags, void * CallBackData);
- BOOL IsForegroundWindow(HWND hWnd);
- HFONT ChangeToFont(HDC hdc, ClcData *dat, int id, int *fontHeight);
- int GetBasicFontID(ClcContact *contact);
- void GetTextSize(SIZE *text_size, HDC hdcMem, RECT free_row_rc, TCHAR *szText, SortedList *plText, UINT uTextFormat, int smiley_height);
- void AddParam(MODERNMASK *mpModernMask, DWORD dwParamHash, const char* szValue, DWORD dwValueHash);
- BOOL CheckMiniMode(ClcData *dat, BOOL selected, BOOL hot);
+ BOOL IsForegroundWindow(HWND hWnd);
+ HFONT ChangeToFont(HDC hdc, ClcData *dat, int id, int *fontHeight);
+ int GetBasicFontID(ClcContact *contact);
+ void GetTextSize(SIZE *text_size, HDC hdcMem, RECT free_row_rc, TCHAR *szText, SortedList *plText, UINT uTextFormat, int smiley_height);
+ void AddParam(MODERNMASK *mpModernMask, DWORD dwParamHash, const char* szValue, DWORD dwValueHash);
+ BOOL CheckMiniMode(ClcData *dat, BOOL selected);
private:
static const int HORIZONTAL_SPACE;
@@ -37,7 +37,7 @@ private: enum tagenumHASHINDEX
{
- hi_Module=0,
+ hi_Module = 0,
hi_ID,
hi_Type,
hi_Open,
@@ -106,52 +106,52 @@ private: void _AddParamShort(MODERNMASK *mpModernMask, DWORD dwParamIndex, DWORD dwValueIndex);
void _FillParam(MASKPARAM * lpParam, DWORD dwParamHash, const char* szValue, DWORD dwValueHash);
MODERNMASK* _GetCLCContactRowBackModernMask(ClcGroup *group, ClcContact *Drawing, int indent, int index, BOOL selected, BOOL hottrack, ClcData *dat);
- void _RTLRect(RECT *rect, int width, int offset);
- void _PaintRowItemsEx(HWND hwnd, HDC hdcMem, ClcData *dat, ClcContact *Drawing, RECT row_rc, RECT free_row_rc, int left_pos, int right_pos, int selected, int hottrack, RECT *rcPaint);
+ void _RTLRect(RECT *rect, int width);
+ void _PaintRowItemsEx(HWND hwnd, HDC hdcMem, ClcData *dat, ClcContact *Drawing, RECT row_rc, RECT free_row_rc, int selected, int hottrack);
void _DrawStatusIcon(ClcContact *Drawing, ClcData *dat, int iImage, HDC hdcMem, int x, int y, int cx, int cy, DWORD colorbg, DWORD colorfg, int mode);
- BOOL _DrawNonEnginedBackground(HWND hwnd, HDC hdcMem, RECT *rcPaint, RECT clRect, ClcData *dat);
+ BOOL _DrawNonEnginedBackground(HDC hdcMem, RECT *rcPaint, RECT clRect, ClcData *dat);
void _PaintClc(HWND hwnd, ClcData *dat, HDC hdc, RECT *rcPaint);
void _StoreItemPos(ClcContact *contact, int ItemType, RECT *rc);
- void _CalcItemsPos(HWND hwnd, HDC hdcMem, ClcData *dat, ClcContact *Drawing, RECT *in_row_rc, RECT *in_free_row_rc, int left_pos, int right_pos, int selected, int hottrack);
+ void _CalcItemsPos(HDC hdcMem, ClcData *dat, ClcContact *Drawing, RECT *in_row_rc, RECT *in_free_row_rc, int left_pos, int right_pos, int selected);
BOOL __IsVisible(RECT *firtRect, RECT *secondRect);
void _GetBlendMode(IN ClcData *dat, IN ClcContact *Drawing, IN BOOL selected, IN BOOL hottrack, IN BOOL bFlag, OUT COLORREF * OutColourFg, OUT int * OutMode);
- void _DrawContactItems(HWND hwnd, HDC hdcMem, ClcData *dat, ClcContact *Drawing, RECT *row_rc, RECT *free_row_rc, int left_pos, int right_pos, int selected, int hottrack, RECT *rcPaint);
- void _PaintRowItems (HWND hwnd, HDC hdcMem, ClcData *dat, ClcContact *Drawing, RECT row_rc, RECT free_row_rc, int left_pos, int right_pos, int selected, int hottrack, RECT *rcPaint);
+ void _DrawContactItems(HDC hdcMem, ClcData *dat, ClcContact *Drawing, RECT *row_rc, RECT *free_row_rc, int selected, int hottrack, RECT *rcPaint);
+ void _PaintRowItems(HWND hwnd, HDC hdcMem, ClcData *dat, ClcContact *Drawing, RECT row_rc, RECT free_row_rc, int left_pos, int right_pos, int selected, int hottrack, RECT *rcPaint);
- void _DrawContactAvatar (HDC hdcMem, ClcData *dat, ClcContact *Drawing, RECT *row_rc, int& selected, int& hottrack, RECT& text_rc, RECT *prcItem);
- void _DrawContactIcon (HDC hdcMem, ClcData *dat, ClcContact *Drawing, int& selected, int& hottrack, RECT& text_rc, RECT *prcItem);
- void _DrawContactText (HDC hdcMem, ClcData *dat, ClcContact *Drawing, int& selected, int& hottrack, RECT& text_rc, RECT *prcItem, UINT uTextFormat);
- void _DrawContactSubText (HDC hdcMem, ClcData *dat, ClcContact *Drawing, int& selected, int& hottrack, RECT& text_rc, RECT *prcItem, UINT uTextFormat, BYTE itemType);
- void _DrawContactTime (HDC hdcMem, ClcData *dat, ClcContact *Drawing, int& selected, int& hottrack, RECT& text_rc, RECT *prcItem);
- void _DrawContactExtraIcon (HDC hdcMem, ClcData *dat, ClcContact *Drawing, int& selected, int& hottrack, RECT& text_rc, RECT *rc, int iImage);
- void _DrawContactSelection (HDC hdcMem, ClcData *dat, ClcContact *Drawing, int& selected, int& hottrack, RECT *rcPaint, RECT *prcItem);
- void _DrawContactLine (HDC hdcMem, ClcData *dat, ClcContact *Drawing, RECT *free_row_rc, RECT *rcPaint, RECT& text_rc);
+ void _DrawContactAvatar(HDC hdcMem, ClcData *dat, ClcContact *Drawing, RECT *row_rc, int& selected, int& hottrack, RECT *prcItem);
+ void _DrawContactIcon(HDC hdcMem, ClcData *dat, ClcContact *Drawing, int& selected, int& hottrack, RECT *prcItem);
+ void _DrawContactText(HDC hdcMem, ClcData *dat, ClcContact *Drawing, int& selected, int& hottrack, RECT& text_rc, RECT *prcItem, UINT uTextFormat);
+ void _DrawContactSubText(HDC hdcMem, ClcData *dat, ClcContact *Drawing, int& selected, int& hottrack, RECT& text_rc, RECT *prcItem, UINT uTextFormat, BYTE itemType);
+ void _DrawContactTime(HDC hdcMem, ClcData *dat, ClcContact *Drawing, RECT *prcItem);
+ void _DrawContactExtraIcon(HDC hdcMem, ClcData *dat, ClcContact *Drawing, int& selected, int& hottrack, RECT *rc, int iImage);
+ void _DrawContactSelection(HDC hdcMem, ClcData *dat, int& selected, int& hottrack, RECT *rcPaint, RECT *prcItem);
+ void _DrawContactLine(HDC hdcMem, ClcContact *Drawing, RECT *free_row_rc, RECT *rcPaint, RECT& text_rc);
- int _rcWidth(RECT *rc) { return rc->right-rc->left; }
- int _rcHeight(RECT *rc) { return rc->bottom-rc->top; }
+ int _rcWidth(RECT *rc) { return rc->right - rc->left; }
+ int _rcHeight(RECT *rc) { return rc->bottom - rc->top; }
private:
- enum enDrawMode
- {
- DM_LAYERED = 1, // Draw normal skin on 32 bit with alpha layer
- DM_NON_LAYERED = 2, // Draw skinnable, but does not take care about alpha
- DM_CLASSIC = 4, // Old style draw for classic
- DM_CONTROL = 8, // Draw as control according to windows color scheme
- DM_FLOAT = 16, // Float mode
- DM_GRAY = 32, // Grayed mode
- DM_GREYALTERNATE = 64, // Gray odd lines
- DM_DRAW_OFFSCREEN = DM_FLOAT | DM_CONTROL | DM_NON_LAYERED | DM_CLASSIC,
+ enum enDrawMode
+ {
+ DM_LAYERED = 1, // Draw normal skin on 32 bit with alpha layer
+ DM_NON_LAYERED = 2, // Draw skinnable, but does not take care about alpha
+ DM_CLASSIC = 4, // Old style draw for classic
+ DM_CONTROL = 8, // Draw as control according to windows color scheme
+ DM_FLOAT = 16, // Float mode
+ DM_GRAY = 32, // Grayed mode
+ DM_GREYALTERNATE = 64, // Gray odd lines
+ DM_DRAW_OFFSCREEN = DM_FLOAT | DM_CONTROL | DM_NON_LAYERED | DM_CLASSIC,
};
inline int _DetermineDrawMode(HWND hWnd, ClcData *dat);
struct _PaintContext
{
- enum
+ enum
{
- release_none = 0,
- release_hdcmem2 = 1,
- release_hdcmem = 2
+ release_none = 0,
+ release_hdcmem2 = 1,
+ release_hdcmem = 2
};
HDC hdcMem;
HDC hdcMem2;
@@ -168,19 +168,19 @@ private: DWORD fRelease;
_PaintContext(HDC _hdcMem = NULL) :
- hdcMem (_hdcMem ), hdcMem2(NULL ),
- hBmpOsb2(NULL ), oldbmp2(NULL ),
- hBmpOsb(NULL ), oldbmp(NULL ),
- hBrushAlternateGrey (NULL ),
- tmpbkcolour(0 ), tmpforecolour(0 ),
- fRelease (release_none) {};
+ hdcMem(_hdcMem), hdcMem2(NULL),
+ hBmpOsb2(NULL), oldbmp2(NULL),
+ hBmpOsb(NULL), oldbmp(NULL),
+ hBrushAlternateGrey(NULL),
+ tmpbkcolour(0), tmpforecolour(0),
+ fRelease(release_none) {};
};
- inline void _PreparePaintContext(HWND hWnd, ClcData *dat, HDC hdc, int paintMode, RECT& clRect, _PaintContext& pc);
- inline void _DrawBackground(HWND hWnd, ClcData *dat, HDC hdc, int paintMode, RECT* rcPaint, RECT& clRect, _PaintContext& pc);
- inline void _DrawLines(HWND hWnd, ClcData *dat, HDC hdc, int paintMode, RECT* rcPaint, RECT& clRect, _PaintContext& pc);
+ inline void _PreparePaintContext(ClcData *dat, HDC hdc, int paintMode, RECT& clRect, _PaintContext& pc);
+ inline void _DrawBackground(HWND hWnd, ClcData *dat, int paintMode, RECT* rcPaint, RECT& clRect, _PaintContext& pc);
+ inline void _DrawLines(HWND hWnd, ClcData *dat, int paintMode, RECT* rcPaint, RECT& clRect, _PaintContext& pc);
inline void _DrawInsertionMark(ClcData *dat, RECT& clRect, _PaintContext& pc);
- inline void _CopyPaintToDest(HWND hWnd, ClcData *dat, HDC hdc, int paintMode, RECT* rcPaint, RECT& clRect, _PaintContext& pc);
+ inline void _CopyPaintToDest(HDC hdc, int paintMode, RECT* rcPaint, _PaintContext& pc);
inline void _FreePaintContext(_PaintContext& pc);
};
diff --git a/plugins/Clist_modern/src/hdr/modern_clist.h b/plugins/Clist_modern/src/hdr/modern_clist.h index ef89b2b92b..2884c731cd 100644 --- a/plugins/Clist_modern/src/hdr/modern_clist.h +++ b/plugins/Clist_modern/src/hdr/modern_clist.h @@ -29,8 +29,8 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. void LoadContactTree(void);
HTREEITEM GetTreeItemByHContact(MCONTACT hContact);
-void cli_ChangeContactIcon(MCONTACT hContact,int iIcon,int add);
-int GetContactInfosForSort(MCONTACT hContact,char **Proto,TCHAR **Name,int *Status);
+void cli_ChangeContactIcon(MCONTACT hContact, int iIcon, int add);
+int GetContactInfosForSort(MCONTACT hContact, char **Proto, TCHAR **Name, int *Status);
///////////////////////////////////////////////////////////////////////////////
@@ -40,17 +40,17 @@ public: SortedList* plText;
int iMaxSmileyHeight;
- CSmileyString() : plText( NULL ), iMaxSmileyHeight( 0 ) {};
- CSmileyString( const CSmileyString& ssIn )
+ CSmileyString() : plText(NULL), iMaxSmileyHeight(0) {};
+ CSmileyString(const CSmileyString& ssIn)
{
- _CopySmileyList( ssIn.plText );
+ _CopySmileyList(ssIn.plText);
iMaxSmileyHeight = ssIn.iMaxSmileyHeight;
}
- CSmileyString& operator= ( const CSmileyString& ssIn )
+ CSmileyString& operator= (const CSmileyString& ssIn)
{
DestroySmileyList();
- _CopySmileyList( ssIn.plText );
+ _CopySmileyList(ssIn.plText);
iMaxSmileyHeight = ssIn.iMaxSmileyHeight;
return *this;
}
@@ -65,8 +65,8 @@ public: /** Destroy smiley list */
void DestroySmileyList();
/** Copy Smiley List */
- void _CopySmileyList( SortedList *plInput );
- void AddListeningToIcon(struct SHORTDATA *dat, struct ClcCacheEntry *pdnce, TCHAR *szText, BOOL replace_smileys);
+ void _CopySmileyList(SortedList *plInput);
+ void AddListeningToIcon(struct SHORTDATA *dat, TCHAR *szText);
};
diff --git a/plugins/Clist_modern/src/hdr/modern_clui.h b/plugins/Clist_modern/src/hdr/modern_clui.h index f67a575d6a..09d27c011d 100644 --- a/plugins/Clist_modern/src/hdr/modern_clui.h +++ b/plugins/Clist_modern/src/hdr/modern_clui.h @@ -50,69 +50,68 @@ public: CLINTERFACE void cliOnCreateClc();
- EVENTHOOK( OnEvent_ModulesLoaded );
- EVENTHOOK( OnEvent_ContactMenuPreBuild );
- EVENTHOOK( OnEvent_FontReload );
+ EVENTHOOK(OnEvent_ModulesLoaded);
+ EVENTHOOK(OnEvent_ContactMenuPreBuild);
+ EVENTHOOK(OnEvent_FontReload);
- SERVICE( Service_ShowMainMenu );
- SERVICE( Service_ShowStatusMenu );
- SERVICE( Service_Menu_ShowContactAvatar );
- SERVICE( Service_Menu_HideContactAvatar );
+ SERVICE(Service_ShowMainMenu);
+ SERVICE(Service_ShowStatusMenu);
+ SERVICE(Service_Menu_ShowContactAvatar);
+ SERVICE(Service_Menu_HideContactAvatar);
static LRESULT CALLBACK cli_ContactListWndProc(HWND hwnd, UINT msg, WPARAM wParam, LPARAM lParam)
{
CLUI * This = m_pCLUI;
- if (!m_hWnd ) m_hWnd = hwnd;
+ if (!m_hWnd) m_hWnd = hwnd;
BOOL bHandled = FALSE;
- LRESULT lRes= This->PreProcessWndProc( msg, wParam, lParam, bHandled );
- if ( bHandled ) return lRes;
+ LRESULT lRes = This->PreProcessWndProc(msg, wParam, lParam, bHandled);
+ if (bHandled) return lRes;
- switch ( msg )
+ switch (msg)
{
- HANDLE_MESSAGE(WM_NCCREATE, OnNcCreate);
- HANDLE_MESSAGE(WM_CREATE, OnCreate);
- HANDLE_MESSAGE(UM_CREATECLC, OnCreateClc);
- HANDLE_MESSAGE(UM_SETALLEXTRAICONS, OnSetAllExtraIcons);
- HANDLE_MESSAGE(WM_INITMENU, OnInitMenu);
- HANDLE_MESSAGE(WM_SIZE, OnSizingMoving);
- HANDLE_MESSAGE(WM_SIZING, OnSizingMoving);
- HANDLE_MESSAGE(WM_MOVE, OnSizingMoving);
- HANDLE_MESSAGE(WM_EXITSIZEMOVE, OnSizingMoving);
- HANDLE_MESSAGE(WM_WINDOWPOSCHANGING, OnSizingMoving);
- HANDLE_MESSAGE(WM_DISPLAYCHANGE, OnSizingMoving);
- HANDLE_MESSAGE(WM_THEMECHANGED, OnThemeChanged);
+ HANDLE_MESSAGE(WM_NCCREATE, OnNcCreate);
+ HANDLE_MESSAGE(WM_CREATE, OnCreate);
+ HANDLE_MESSAGE(UM_CREATECLC, OnCreateClc);
+ HANDLE_MESSAGE(UM_SETALLEXTRAICONS, OnSetAllExtraIcons);
+ HANDLE_MESSAGE(WM_INITMENU, OnInitMenu);
+ HANDLE_MESSAGE(WM_SIZE, OnSizingMoving);
+ HANDLE_MESSAGE(WM_SIZING, OnSizingMoving);
+ HANDLE_MESSAGE(WM_MOVE, OnSizingMoving);
+ HANDLE_MESSAGE(WM_EXITSIZEMOVE, OnSizingMoving);
+ HANDLE_MESSAGE(WM_WINDOWPOSCHANGING, OnSizingMoving);
+ HANDLE_MESSAGE(WM_DISPLAYCHANGE, OnSizingMoving);
+ HANDLE_MESSAGE(WM_THEMECHANGED, OnThemeChanged);
HANDLE_MESSAGE(WM_DWMCOMPOSITIONCHANGED, OnDwmCompositionChanged);
- HANDLE_MESSAGE(UM_UPDATE, OnUpdate);
- HANDLE_MESSAGE(WM_NCACTIVATE, OnNcPaint);
- HANDLE_MESSAGE(WM_PRINT, OnNcPaint);
- HANDLE_MESSAGE(WM_NCPAINT, OnNcPaint);
- HANDLE_MESSAGE(WM_ERASEBKGND, OnEraseBkgnd);
- HANDLE_MESSAGE(WM_PAINT, OnPaint);
- HANDLE_MESSAGE(WM_LBUTTONDOWN, OnLButtonDown);
- HANDLE_MESSAGE(WM_PARENTNOTIFY, OnParentNotify);
- HANDLE_MESSAGE(WM_SETFOCUS, OnSetFocus);
- HANDLE_MESSAGE(WM_TIMER, OnTimer);
- HANDLE_MESSAGE(WM_ACTIVATE, OnActivate);
- HANDLE_MESSAGE(WM_SETCURSOR, OnSetCursor);
- HANDLE_MESSAGE(WM_MOUSEACTIVATE, OnMouseActivate);
- HANDLE_MESSAGE(WM_NCLBUTTONDOWN, OnNcLButtonDown);
- HANDLE_MESSAGE(WM_NCLBUTTONDBLCLK, OnNcLButtonDblClk);
- HANDLE_MESSAGE(WM_NCHITTEST, OnNcHitTest);
- HANDLE_MESSAGE(WM_SHOWWINDOW, OnShowWindow);
- HANDLE_MESSAGE(WM_SYSCOMMAND, OnSysCommand);
- HANDLE_MESSAGE(WM_KEYDOWN, OnKeyDown);
- HANDLE_MESSAGE(WM_GETMINMAXINFO, OnGetMinMaxInfo);
- HANDLE_MESSAGE(WM_MOVING, OnMoving);
- HANDLE_MESSAGE(WM_NOTIFY, OnNotify);
- HANDLE_MESSAGE(WM_CONTEXTMENU, OnContextMenu);
- HANDLE_MESSAGE(WM_MEASUREITEM, OnMeasureItem);
- HANDLE_MESSAGE(WM_DRAWITEM, OnDrawItem);
- HANDLE_MESSAGE(WM_DESTROY, OnDestroy);
+ HANDLE_MESSAGE(UM_UPDATE, OnUpdate);
+ HANDLE_MESSAGE(WM_NCACTIVATE, OnNcPaint);
+ HANDLE_MESSAGE(WM_PRINT, OnNcPaint);
+ HANDLE_MESSAGE(WM_NCPAINT, OnNcPaint);
+ HANDLE_MESSAGE(WM_ERASEBKGND, OnEraseBkgnd);
+ HANDLE_MESSAGE(WM_PAINT, OnPaint);
+ HANDLE_MESSAGE(WM_LBUTTONDOWN, OnLButtonDown);
+ HANDLE_MESSAGE(WM_PARENTNOTIFY, OnParentNotify);
+ HANDLE_MESSAGE(WM_SETFOCUS, OnSetFocus);
+ HANDLE_MESSAGE(WM_TIMER, OnTimer);
+ HANDLE_MESSAGE(WM_ACTIVATE, OnActivate);
+ HANDLE_MESSAGE(WM_SETCURSOR, OnSetCursor);
+ HANDLE_MESSAGE(WM_MOUSEACTIVATE, OnMouseActivate);
+ HANDLE_MESSAGE(WM_NCLBUTTONDOWN, OnNcLButtonDown);
+ HANDLE_MESSAGE(WM_NCLBUTTONDBLCLK, OnNcLButtonDblClk);
+ HANDLE_MESSAGE(WM_NCHITTEST, OnNcHitTest);
+ HANDLE_MESSAGE(WM_SHOWWINDOW, OnShowWindow);
+ HANDLE_MESSAGE(WM_SYSCOMMAND, OnSysCommand);
+ HANDLE_MESSAGE(WM_KEYDOWN, OnKeyDown);
+ HANDLE_MESSAGE(WM_GETMINMAXINFO, OnGetMinMaxInfo);
+ HANDLE_MESSAGE(WM_MOVING, OnMoving);
+ HANDLE_MESSAGE(WM_NOTIFY, OnNotify);
+ HANDLE_MESSAGE(WM_CONTEXTMENU, OnContextMenu);
+ HANDLE_MESSAGE(WM_MEASUREITEM, OnMeasureItem);
+ HANDLE_MESSAGE(WM_DRAWITEM, OnDrawItem);
+ HANDLE_MESSAGE(WM_DESTROY, OnDestroy);
default:
return This->DefCluiWndProc(msg, wParam, lParam);
}
- return FALSE;
}
@@ -121,8 +120,8 @@ public: //
private:
HRESULT CreateCLC();
- HRESULT FillAlphaChannel( HDC hDC, RECT* prcParent, BYTE bAlpha);
- HRESULT SnappingToEdge( WINDOWPOS * lpWindowPos );
+ HRESULT FillAlphaChannel(HDC hDC, RECT* prcParent);
+ HRESULT SnappingToEdge(WINDOWPOS * lpWindowPos);
HRESULT LoadDllsRuntime();
HRESULT RegisterAvatarMenu(); // TODO move to CLC class
HRESULT CreateCluiFrames();
@@ -131,11 +130,11 @@ private: LRESULT DefCluiWndProc(UINT msg, WPARAM wParam, LPARAM lParam)
{
- return corecli.pfnContactListWndProc( m_hWnd, msg, wParam, lParam);
+ return corecli.pfnContactListWndProc(m_hWnd, msg, wParam, lParam);
}
// MessageMap
- LRESULT PreProcessWndProc(UINT msg, WPARAM wParam, LPARAM lParam, BOOL& bHandled );
+ LRESULT PreProcessWndProc(UINT msg, WPARAM wParam, LPARAM lParam, BOOL& bHandled);
LRESULT OnSizingMoving(UINT msg, WPARAM wParam, LPARAM lParam);
LRESULT OnThemeChanged(UINT msg, WPARAM wParam, LPARAM lParam);
LRESULT OnDwmCompositionChanged(UINT msg, WPARAM wParam, LPARAM lParam);
diff --git a/plugins/Clist_modern/src/hdr/modern_commonheaders.h b/plugins/Clist_modern/src/hdr/modern_commonheaders.h index d8723914e8..fddccd50ef 100644 --- a/plugins/Clist_modern/src/hdr/modern_commonheaders.h +++ b/plugins/Clist_modern/src/hdr/modern_commonheaders.h @@ -47,13 +47,13 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. #if defined (_DEBUG)
#define TRACE(str) { log0(str); }
#else
- #define TRACE(str)
+#define TRACE(str)
#endif
#if defined (_DEBUG)
- #define TRACEVAR(str,n) { log1(str,n); }
+#define TRACEVAR(str,n) { log1(str,n); }
#else
- #define TRACEVAR(str,n)
+#define TRACEVAR(str,n)
#endif
#if defined (_DEBUG)
@@ -143,7 +143,7 @@ extern TCHAR SkinsFolder[MAX_PATH]; #define SCF_TOP 3
#define SCF_BOTTOM 6
-char* __cdecl strstri( char *a, const char *b);
+char* __cdecl strstri(char *a, const char *b);
BOOL __cdecl mir_bool_strcmpi(const char *a, const char *b);
BOOL __cdecl mir_bool_tstrcmpi(const TCHAR *a, const TCHAR *b);
DWORD exceptFunction(LPEXCEPTION_POINTERS EP);
@@ -237,7 +237,7 @@ int AniAva_RemoveInvalidatedAvatars(); // all avatars without validated p int AniAva_RemoveAvatar(MCONTACT hContact); // remove avatar
int AniAva_RedrawAllAvatars(BOOL updateZOrder); // request to repaint all
void AniAva_UpdateParent();
-int AniAva_RenderAvatar(MCONTACT hContact, HDC hdcMem, RECT *rc );
+int AniAva_RenderAvatar(MCONTACT hContact, HDC hdcMem, RECT *rc);
#define CCI_NAME 1
#define CCI_GROUP (1<<1)
@@ -264,12 +264,12 @@ int CLUI_SyncGetPDNCE(WPARAM wParam, LPARAM lParam); WORD pdnce___GetStatus(ClcCacheEntry *pdnce);
/* move to list module */
-typedef void (*ItemDestuctor)(void*);
+typedef void(*ItemDestuctor)(void*);
#ifdef __cplusplus
-const ROWCELL * rowAddCell(ROWCELL* &, int );
+const ROWCELL * rowAddCell(ROWCELL* &, int);
void rowDeleteTree(ROWCELL *cell);
-BOOL rowParse(ROWCELL* &cell, ROWCELL* parent, char *tbuf, int &hbuf, int &sequence, ROWCELL** RowTabAccess );
+BOOL rowParse(ROWCELL* &cell, ROWCELL* parent, char *tbuf, int &hbuf, int &sequence, ROWCELL** RowTabAccess);
void rowSizeWithReposition(ROWCELL* &root, int width);
#endif
@@ -294,34 +294,34 @@ class HashStringKeyNoCase {
public:
- HashStringKeyNoCase( const char* szKey )
+ HashStringKeyNoCase(const char* szKey)
{
- _strKey=_strdup( szKey );
+ _strKey = _strdup(szKey);
_CreateHashKey();
}
- HashStringKeyNoCase( const HashStringKeyNoCase& hsKey )
+ HashStringKeyNoCase(const HashStringKeyNoCase& hsKey)
{
- _strKey = _strdup( hsKey._strKey );
- _dwKey = hsKey._dwKey;
+ _strKey = _strdup(hsKey._strKey);
+ _dwKey = hsKey._dwKey;
}
- HashStringKeyNoCase& operator= ( const HashStringKeyNoCase& hsKey )
+ HashStringKeyNoCase& operator= (const HashStringKeyNoCase& hsKey)
{
- _strKey = _strdup( hsKey._strKey );
- _dwKey = hsKey._dwKey;
+ _strKey = _strdup(hsKey._strKey);
+ _dwKey = hsKey._dwKey;
}
#ifdef _UNICODE
- HashStringKeyNoCase( const wchar_t* szKey )
+ HashStringKeyNoCase(const wchar_t* szKey)
{
- int codepage=0;
- int cbLen = WideCharToMultiByte( codepage, 0, szKey, -1, NULL, 0, NULL, NULL );
- char* result = ( char* )malloc( cbLen+1 );
- WideCharToMultiByte( codepage, 0, szKey, -1, result, cbLen, NULL, NULL );
- result[ cbLen ] = 0;
+ int codepage = 0;
+ int cbLen = WideCharToMultiByte(codepage, 0, szKey, -1, NULL, 0, NULL, NULL);
+ char* result = (char*)malloc(cbLen + 1);
+ WideCharToMultiByte(codepage, 0, szKey, -1, result, cbLen, NULL, NULL);
+ result[cbLen] = 0;
- _strKey=result;
+ _strKey = result;
_CreateHashKey();
}
#endif
@@ -330,7 +330,7 @@ public: {
free(_strKey);
_strKey = NULL;
- _dwKey=0;
+ _dwKey = 0;
}
private:
@@ -339,23 +339,25 @@ private: void _CreateHashKey()
{
- _strKey=_strupr( _strKey );
- _dwKey = mod_CalcHash( _strKey );
+ _strKey = _strupr(_strKey);
+ _dwKey = mod_CalcHash(_strKey);
}
public:
- bool operator< ( const HashStringKeyNoCase& second ) const
+ bool operator< (const HashStringKeyNoCase& second) const
{
- if ( this->_dwKey != second._dwKey )
- return ( this->_dwKey < second._dwKey );
+ if (this->_dwKey != second._dwKey)
+ return (this->_dwKey < second._dwKey);
else
- return ( mir_strcmp( this->_strKey, second._strKey ) < 0 ); // already maked upper so in any case - will be case insensitive
+ return (mir_strcmp(this->_strKey, second._strKey) < 0); // already maked upper so in any case - will be case insensitive
}
struct HashKeyLess
{
- bool operator() ( const HashStringKeyNoCase& first, const HashStringKeyNoCase& second ) const
- { return ( first < second ); }
+ bool operator() (const HashStringKeyNoCase& first, const HashStringKeyNoCase& second) const
+ {
+ return (first < second);
+ }
};
};
diff --git a/plugins/Clist_modern/src/hdr/modern_commonprototypes.h b/plugins/Clist_modern/src/hdr/modern_commonprototypes.h index b0dc2bc203..528ecf6d82 100644 --- a/plugins/Clist_modern/src/hdr/modern_commonprototypes.h +++ b/plugins/Clist_modern/src/hdr/modern_commonprototypes.h @@ -76,7 +76,7 @@ public: __forceinline ~thread_catcher() { m_ptr = 0; }
};
-typedef INT_PTR (*PSYNCCALLBACKPROC)(WPARAM,LPARAM);
+typedef INT_PTR(*PSYNCCALLBACKPROC)(WPARAM, LPARAM);
/************************************************************************/
/* PROTOTYPES */
@@ -87,25 +87,25 @@ typedef INT_PTR (*PSYNCCALLBACKPROC)(WPARAM,LPARAM); BOOL CLCItems_IsShowOfflineGroup(ClcGroup* group);
/* CListMod */
-int CListMod_HideWindow(HWND hwndContactList, int mode);
+int CListMod_HideWindow();
/* CLUI */
-HANDLE RegisterIcolibIconHandle(char * szIcoID, char *szSectionName, char * szDescription, TCHAR * tszDefaultFile, int iDefaultIndex, HINSTANCE hDefaultModule, int iDefaultResource );
+HANDLE RegisterIcolibIconHandle(char * szIcoID, char *szSectionName, char * szDescription, TCHAR * tszDefaultFile, int iDefaultIndex, HINSTANCE hDefaultModule, int iDefaultResource);
void CLUI_UpdateAeroGlass();
void CLUI_ChangeWindowMode();
BOOL CLUI_CheckOwnedByClui(HWND hwnd);
INT_PTR CLUI_GetConnectingIconService(WPARAM wParam, LPARAM lParam);
int CLUI_HideBehindEdge();
-int CLUI_IconsChanged(WPARAM,LPARAM);
+int CLUI_IconsChanged(WPARAM, LPARAM);
int CLUI_IsInMainWindow(HWND hwnd);
int CLUI_OnSkinLoad(WPARAM wParam, LPARAM lParam);
int CLUI_ReloadCLUIOptions();
int CLUI_ShowFromBehindEdge();
-int CLUI_SizingGetWindowRect(HWND hwnd,RECT *rc);
-int CLUI_SizingOnBorder(POINT ,int);
+int CLUI_SizingGetWindowRect(HWND hwnd, RECT *rc);
+int CLUI_SizingOnBorder(POINT, int);
int CLUI_SmoothAlphaTransition(HWND hwnd, BYTE GoalAlpha, BOOL wParam);
int CLUI_TestCursorOnBorders();
-int CLUI_UpdateTimer(BYTE BringIn);
+int CLUI_UpdateTimer();
void CLUI_UpdateLayeredMode();
UINT_PTR CLUI_SafeSetTimer(HWND hwnd, int ID, int Timeout, TIMERPROC proc);
@@ -113,39 +113,39 @@ UINT_PTR CLUI_SafeSetTimer(HWND hwnd, int ID, int Timeout, TIMERPROC proc); int CLUIUnreadEmailCountChanged(WPARAM wParam, LPARAM lParam);
/* GDIPlus */
-BOOL GDIPlus_AlphaBlend(HDC hdcDest,int nXOriginDest,int nYOriginDest,int nWidthDest,int nHeightDest,HDC hdcSrc,int nXOriginSrc,int nYOriginSrc,int nWidthSrc,int nHeightSrc, BLENDFUNCTION * blendFunction);
+BOOL GDIPlus_AlphaBlend(HDC hdcDest, int nXOriginDest, int nYOriginDest, int nWidthDest, int nHeightDest, HDC hdcSrc, int nXOriginSrc, int nYOriginSrc, int nWidthSrc, int nHeightSrc, BLENDFUNCTION * blendFunction);
HBITMAP GDIPlus_LoadGlyphImage(const TCHAR *szFileName);
/* EventArea */
void EventArea_ConfigureEventArea();
/* ModernSkinButton */
-int ModernSkinButton_AddButton(HWND parent,char * ID,char * CommandService,char * StateDefService,char * HandeService, int Left, int Top, int Right, int Bottom, DWORD AlignedTo,TCHAR * Hint,char * DBkey,char * TypeDef,int MinWidth, int MinHeight);
+int ModernSkinButton_AddButton(HWND parent, char * ID, char * CommandService, char * StateDefService, char * HandeService, int Left, int Top, int Right, int Bottom, DWORD AlignedTo, TCHAR * Hint, char * DBkey, char * TypeDef, int MinWidth, int MinHeight);
int ModernSkinButtonLoadModule();
int ModernSkinButton_ReposButtons(HWND parent, BYTE draw, RECT *r);
-int ModernSkinButtonUnloadModule(WPARAM,LPARAM);
+int ModernSkinButtonUnloadModule(WPARAM, LPARAM);
/* RowHeight */
int RowHeight_CalcRowHeight(ClcData *dat, HWND hwnd, ClcContact *contact, int item);
/* SkinEngine */
-BOOL ske_AlphaBlend(HDC hdcDest,int nXOriginDest,int nYOriginDest,int nWidthDest,int nHeightDest,HDC hdcSrc,int nXOriginSrc,int nYOriginSrc,int nWidthSrc,int nHeightSrc,BLENDFUNCTION blendFunction);
+BOOL ske_AlphaBlend(HDC hdcDest, int nXOriginDest, int nYOriginDest, int nWidthDest, int nHeightDest, HDC hdcSrc, int nXOriginSrc, int nYOriginSrc, int nWidthSrc, int nHeightSrc, BLENDFUNCTION blendFunction);
void ske_ApplyTranslucency(void);
-int ske_BltBackImage (HWND destHWND, HDC destDC, RECT *BltClientRect);
+int ske_BltBackImage(HWND destHWND, HDC destDC, RECT *BltClientRect);
HBITMAP ske_CreateDIB32(int cx, int cy);
HBITMAP ske_CreateDIB32Point(int cx, int cy, void ** bits);
HRGN ske_CreateOpaqueRgn(BYTE Level, bool Opaque);
-HICON ske_CreateJoinedIcon(HICON hBottom, HICON hTop,BYTE alpha);
+HICON ske_CreateJoinedIcon(HICON hBottom, HICON hTop, BYTE alpha);
int ske_DrawImageAt(HDC hdc, RECT *rc);
-BOOL ske_DrawIconEx(HDC hdc,int xLeft,int yTop,HICON hIcon,int cxWidth,int cyWidth, UINT istepIfAniCur, HBRUSH hbrFlickerFreeDraw, UINT diFlags);
-int ske_DrawNonFramedObjects(BOOL Erase,RECT *r);
+BOOL ske_DrawIconEx(HDC hdc, int xLeft, int yTop, HICON hIcon, int cxWidth, int cyWidth, UINT istepIfAniCur, HBRUSH hbrFlickerFreeDraw, UINT diFlags);
+int ske_DrawNonFramedObjects(BOOL Erase, RECT *r);
BOOL ske_DrawText(HDC hdc, LPCTSTR lpString, int nCount, RECT *lpRect, UINT format);
LPSKINOBJECTDESCRIPTOR ske_FindObjectByName(const char * szName, BYTE objType, SKINOBJECTSLIST* Skin);
HBITMAP ske_GetCurrentWindowImage();
-int ske_GetFullFilename(TCHAR *buf, const TCHAR *file, TCHAR *skinfolder,BOOL madeAbsolute);
+int ske_GetFullFilename(TCHAR *buf, const TCHAR *file, TCHAR *skinfolder, BOOL madeAbsolute);
int ske_GetSkinFolder(TCHAR *szFileName, char * t2);
-BOOL ske_ImageList_DrawEx( HIMAGELIST himl,int i,HDC hdcDst,int x,int y,int dx,int dy,COLORREF rgbBk,COLORREF rgbFg,UINT fStyle);
-HICON ske_ImageList_GetIcon(HIMAGELIST himl, int i, UINT fStyle);
+BOOL ske_ImageList_DrawEx(HIMAGELIST himl, int i, HDC hdcDst, int x, int y, int dx, int dy, COLORREF rgbBk, COLORREF rgbFg, UINT fStyle);
+HICON ske_ImageList_GetIcon(HIMAGELIST himl, int i);
int ske_JustUpdateWindowImageRect(RECT *rty);
HBITMAP ske_LoadGlyphImage(const TCHAR *szFileName);
HRESULT SkinEngineLoadModule();
@@ -153,13 +153,13 @@ void ske_LoadSkinFromDB(void); int ske_LoadSkinFromIniFile(TCHAR*, BOOL);
TCHAR* ske_ParseText(TCHAR *stzText);
int ske_PrepareImageButDontUpdateIt(RECT *r);
-int ske_ReCreateBackImage(BOOL Erase,RECT *w);
+int ske_ReCreateBackImage(BOOL Erase, RECT *w);
int ske_RedrawCompleteWindow();
bool ske_ResetTextEffect(HDC);
bool ske_SelectTextEffect(HDC hdc, BYTE EffectID, DWORD FirstColor, DWORD SecondColor);
INT_PTR ske_Service_DrawGlyph(WPARAM wParam, LPARAM lParam);
-BOOL ske_SetRectOpaque(HDC memdc,RECT *fr, BOOL force = FALSE );
-BOOL ske_SetRgnOpaque(HDC memdc,HRGN hrgn, BOOL force = FALSE );
+BOOL ske_SetRectOpaque(HDC memdc, RECT *fr, BOOL force = FALSE);
+BOOL ske_SetRgnOpaque(HDC memdc, HRGN hrgn, BOOL force = FALSE);
BOOL ske_TextOut(HDC hdc, int x, int y, LPCTSTR lpString, int nCount);
int ske_UnloadGlyphImage(HBITMAP hbmp);
int SkinEngineUnloadModule();
@@ -168,23 +168,24 @@ int ske_UpdateWindowImageRect(RECT *lpRect); int ske_ValidateFrameImageProc(RECT *r);
__forceinline BOOL ske_DrawTextA(HDC hdc, char *lpString, int nCount, RECT *lpRect, UINT format)
-{ return ske_DrawText(hdc, _A2T(lpString), nCount, lpRect, format);
+{
+ return ske_DrawText(hdc, _A2T(lpString), nCount, lpRect, format);
}
/* CLUIFrames.c PROXIED */
int CLUIFrames_ActivateSubContainers(BOOL wParam);
int CLUIFrames_OnClistResize_mod(WPARAM wParam, LPARAM lParam);
-int CLUIFrames_OnMoving( HWND, RECT *);
-int CLUIFrames_OnShowHide( HWND hwnd, int mode );
-int CLUIFrames_SetLayeredMode( BOOL fLayeredMode, HWND hwnd );
-int CLUIFrames_SetParentForContainers( HWND parent );
+int CLUIFrames_OnMoving(HWND, RECT *);
+int CLUIFrames_OnShowHide(int mode);
+int CLUIFrames_SetLayeredMode(BOOL fLayeredMode, HWND hwnd);
+int CLUIFrames_SetParentForContainers(HWND parent);
int CLUIFramesOnClistResize(WPARAM wParam, LPARAM lParam);
FRAMEWND * FindFrameByItsHWND(HWND FrameHwnd); //cluiframes.c
//int callProxied_DrawTitleBar(HDC hdcMem2,RECT *rect,int Frameid);
-int DrawTitleBar(HDC hdcMem2,RECT *rect,int Frameid);
+int DrawTitleBar(HDC hdcMem2, RECT *rect, int Frameid);
int FindFrameID(HWND FrameHwnd);
int SetAlpha(BYTE Alpha);
@@ -192,7 +193,7 @@ int SetAlpha(BYTE Alpha); /* others TODO: move above */
int Docking_ProcessWindowMessage(WPARAM wParam, LPARAM lParam);
-void DrawBackGround(HWND hwnd,HDC mhdc, HBITMAP hBmpBackground, COLORREF bkColour, DWORD backgroundBmpUse );
+void DrawBackGround(HWND hwnd, HDC mhdc, HBITMAP hBmpBackground, COLORREF bkColour, DWORD backgroundBmpUse);
HRESULT BackgroundsLoadModule();
int BackgroundsUnloadModule();
INT_PTR CALLBACK DlgTmplEditorOpts(HWND hwndDlg, UINT msg, WPARAM wParam, LPARAM lParam); //RowTemplate.c
@@ -203,7 +204,7 @@ char* GetParamN(char *string, char *buf, int buflen, BYTE paramN, char Delim, WCHAR* GetParamN(WCHAR *string, WCHAR *buf, int buflen, BYTE paramN, WCHAR Delim, BOOL SkipSpaces);
DWORD CompareContacts2_getLMTime(MCONTACT u); //contact.c
DWORD mod_CalcHash(const char * a); //mod_skin_selector.c
-HICON cliGetIconFromStatusMode(MCONTACT hContact, const char *szProto,int status); //clistmod.c
+HICON cliGetIconFromStatusMode(MCONTACT hContact, const char *szProto, int status); //clistmod.c
HICON GetMainStatusOverlay(int STATUS); //clc.c
int __fastcall CLVM_GetContactHiddenStatus(MCONTACT hContact, char *szStatus, ClcData *dat); //clcitems.c
int BgStatusBarChange(WPARAM wParam, LPARAM lParam); //clcopts.c
@@ -211,8 +212,8 @@ int ClcDoProtoAck(MCONTACT wParam, ACKDATA *ack); int ModernSkinButtonDeleteAll(); //modernbutton.c
int GetContactCachedStatus(MCONTACT hContact); //clistsettings.c
int GetContactIconC(ClcCacheEntry *cacheEntry); //clistmod.c
-int GetContactIndex(ClcGroup *group,ClcContact *contact); //clcidents.c
-int GetStatusForContact(MCONTACT hContact,char *szProto); //clistsettings.c
+int GetContactIndex(ClcGroup *group, ClcContact *contact); //clcidents.c
+int GetStatusForContact(MCONTACT hContact, char *szProto); //clistsettings.c
int InitCustomMenus(void); //clistmenus.c
int InitFramesMenus(void); //framesmenus.c
int LoadMoveToGroup(); //movetogroup.c
@@ -221,9 +222,9 @@ int MenuModulesLoaded(WPARAM wParam, LPARAM lParam); int MenuModulesShutdown(WPARAM wParam, LPARAM lParam); //clistmenu.c
int MenuProcessCommand(WPARAM wParam, LPARAM lParam); //clistmenu.c
int OnFrameTitleBarBackgroundChange(WPARAM wParam, LPARAM lParam); //cluiframes.c
-int QueueAllFramesUpdating (BYTE); //cluiframes.c
+int QueueAllFramesUpdating(BYTE); //cluiframes.c
int RecursiveDeleteMenu(HMENU hMenu); //clistmenus.c
-int ModernSkinButtonRedrawAll(HDC hdc); //modern_button.c
+int ModernSkinButtonRedrawAll(); //modern_button.c
int RegisterButtonByParce(char * ObjectName, char * Params); //mod_skin_selector.c
int RestoreAllContactData(ClcData *dat); //cache_funcs.c
@@ -234,11 +235,11 @@ INT_PTR ToggleGroups(WPARAM wParam, LPARAM lParam); INT_PTR SetUseGroups(WPARAM wParam, LPARAM lParam); //contact.c
INT_PTR ToggleSounds(WPARAM wParam, LPARAM lParam); //contact.c
void ClcOptionsChanged(); //clc.c
-void Docking_GetMonitorRectFromWindow(HWND hWnd,RECT *rc); //Docking.c
-void DrawAvatarImageWithGDIp(HDC hDestDC,int x, int y, DWORD width, DWORD height, HBITMAP hbmp, int x1, int y1, DWORD width1, DWORD height1,DWORD flag,BYTE alpha); //gdiplus.cpp
+void Docking_GetMonitorRectFromWindow(HWND hWnd, RECT *rc); //Docking.c
+void DrawAvatarImageWithGDIp(HDC hDestDC, int x, int y, DWORD width, DWORD height, HBITMAP hbmp, int x1, int y1, DWORD width1, DWORD height1, DWORD flag, BYTE alpha); //gdiplus.cpp
void FreeRowCell(); //RowHeight
void InitGdiPlus(); //gdiplus.cpp
-void InvalidateDNCEbyPointer(MCONTACT hContact,ClcCacheEntry *pdnce,int SettingType); //clistsettings.c
+void InvalidateDNCEbyPointer(MCONTACT hContact, ClcCacheEntry *pdnce, int SettingType); //clistsettings.c
void ShutdownGdiPlus(); //gdiplus.cpp
void UninitCustomMenus(); //clistmenus.c
void UnloadAvatarOverlayIcon(); //clc.c
@@ -251,7 +252,7 @@ int ExtraImage_ExtraIDToColumnNum(int extra); int LoadSkinButtonModule();
void UninitSkinHotKeys();
-void GetDefaultFontSetting(int i,LOGFONTA *lf,COLORREF *colour);
+void GetDefaultFontSetting(int i, LOGFONTA *lf, COLORREF *colour);
int CLUI_OnSkinLoad(WPARAM wParam, LPARAM lParam);
HRESULT CluiLoadModule();
HRESULT PreLoadContactListModule();
@@ -301,7 +302,7 @@ void CLUI_cli_LoadCluiGlobalOpts(void); INT_PTR cli_TrayIconProcessMessage(WPARAM wParam, LPARAM lParam);
BOOL CLUI__cliInvalidateRect(HWND hWnd, CONST RECT* lpRect, BOOL bErase);
-ClcContact* cliCreateClcContact( void );
+ClcContact* cliCreateClcContact(void);
ClcCacheEntry* cliCreateCacheItem(MCONTACT hContact);
ClcCacheEntry* cliGetCacheEntry(MCONTACT hContact);
@@ -317,7 +318,7 @@ struct DWM_BLURBEHIND HRGN hRgnBlur;
BOOL fTransitionOnMaximized;
};
-extern HRESULT (WINAPI *g_proc_DWMEnableBlurBehindWindow)(HWND hWnd, DWM_BLURBEHIND *pBlurBehind);
+extern HRESULT(WINAPI *g_proc_DWMEnableBlurBehindWindow)(HWND hWnd, DWM_BLURBEHIND *pBlurBehind);
extern tPaintCallbackProc CLCPaint_PaintCallbackProc(HWND hWnd, HDC hDC, RECT *rcPaint, HRGN rgn, DWORD dFlags, void * CallBackData);
diff --git a/plugins/Clist_modern/src/hdr/modern_effectenum.h b/plugins/Clist_modern/src/hdr/modern_effectenum.h index e3c5600dc6..0a63ffbdce 100644 --- a/plugins/Clist_modern/src/hdr/modern_effectenum.h +++ b/plugins/Clist_modern/src/hdr/modern_effectenum.h @@ -20,74 +20,74 @@ typedef struct _MODERNEFFECT }MODERNEFFECT;
#ifdef _EFFECTENUM_FULL_H
- TCHAR * ModernEffectNames[]=
+TCHAR * ModernEffectNames[]=
#else
- TCHAR * _ModernEffectNames[]=
+TCHAR * _ModernEffectNames[] =
#endif
{
- _T("Shadow at left"),
- _T("Shadow at right"),
- _T("Outline"),
- _T("Outline smooth"),
- _T("Smooth bump"),
- _T("Contour thin"),
- _T("Contour heavy"),
+ _T("Shadow at left"),
+ _T("Shadow at right"),
+ _T("Outline"),
+ _T("Outline smooth"),
+ _T("Smooth bump"),
+ _T("Contour thin"),
+ _T("Contour heavy"),
};
#ifdef _EFFECTENUM_FULL_H
MODERNEFFECTMATRIX ModernEffectsEnum[]={
{ //Shadow at Left
{ 0, 0, 0, 0, 0,
- 0, 4, 16, 4, 4,
- 0, 16, 64, 32, 16,
- 0, 4, 32, 32, 16,
- 0, 4, 16, 16, 16 }, 2,2,2,2,1},
- { //Shadow at Right
- { 0, 0, 0, 0, 0,
+ 0, 4, 16, 4, 4,
+ 0, 16, 64, 32, 16,
+ 0, 4, 32, 32, 16,
+ 0, 4, 16, 16, 16 }, 2,2,2,2,1},
+ { //Shadow at Right
+ { 0, 0, 0, 0, 0,
4, 4, 16, 4, 0,
- 16, 32, 64, 16, 0,
+ 16, 32, 64, 16, 0,
16, 32, 32, 4, 0,
16, 16, 16, 4, 0 }, 2,2,2,2,1},
- { //Outline
- { 0, 0, 0, 0, 0,
- 0, 16, 16, 16, 0,
- 0, 16, 32, 16, 0,
- 0, 16, 16, 16, 0,
- 0, 0, 0, 0, 0 }, 1,1,1,1,1},
-
- { //Outline smooth
- { 4, 4, 4, 4, 4,
- 4, 8, 8, 8, 4,
- 4, 8, 32, 8, 4,
- 4, 8, 8, 8, 4,
- 4, 4, 4, 4, 4 }, 2,2,2,2,1},
-
- { //Smooth bump
- { -2, 2, 2, 2, 2,
- -2, -16, 16, 16, 2,
- -2, -16, 48, 16, 2,
- -2, -16,-16, 16, 2,
- -2, -2, -2, -2, -2 }, 2,2,2,2,1+0x80},
- { //Contour thin
- { 0, 0, 0, 0, 0,
- 0, 48, 64, 48, 0,
- 0, 64, 64, 64, 0,
- 0, 48, 64, 48, 0,
- 0, 0, 0, 0, 0 }, 1,1,1,1,1},
- { //Contour heavy
- { 8, 16, 16, 16, 8,
- 16, 64, 64, 64, 16,
- 16, 64, 64, 64, 16,
- 16, 64, 64, 64, 16,
- 8, 16, 16, 16, 8 }, 2,2,2,2,1},
+ { //Outline
+ { 0, 0, 0, 0, 0,
+ 0, 16, 16, 16, 0,
+ 0, 16, 32, 16, 0,
+ 0, 16, 16, 16, 0,
+ 0, 0, 0, 0, 0 }, 1,1,1,1,1},
+
+ { //Outline smooth
+ { 4, 4, 4, 4, 4,
+ 4, 8, 8, 8, 4,
+ 4, 8, 32, 8, 4,
+ 4, 8, 8, 8, 4,
+ 4, 4, 4, 4, 4 }, 2,2,2,2,1},
+
+ { //Smooth bump
+ { -2, 2, 2, 2, 2,
+ -2, -16, 16, 16, 2,
+ -2, -16, 48, 16, 2,
+ -2, -16,-16, 16, 2,
+ -2, -2, -2, -2, -2 }, 2,2,2,2,1+0x80},
+ { //Contour thin
+ { 0, 0, 0, 0, 0,
+ 0, 48, 64, 48, 0,
+ 0, 64, 64, 64, 0,
+ 0, 48, 64, 48, 0,
+ 0, 0, 0, 0, 0 }, 1,1,1,1,1},
+ { //Contour heavy
+ { 8, 16, 16, 16, 8,
+ 16, 64, 64, 64, 16,
+ 16, 64, 64, 64, 16,
+ 16, 64, 64, 64, 16,
+ 8, 16, 16, 16, 8 }, 2,2,2,2,1},
};
#endif
#ifdef _EFFECTENUM_FULL_H
- #define MAXPREDEFINEDEFFECTS sizeof(ModernEffectNames)/sizeof(ModernEffectNames[0])
+#define MAXPREDEFINEDEFFECTS sizeof(ModernEffectNames)/sizeof(ModernEffectNames[0])
#else
- #define MAXPREDEFINEDEFFECTS sizeof(_ModernEffectNames)/sizeof(_ModernEffectNames[0])
- extern TCHAR * ModernEffectNames[];
+#define MAXPREDEFINEDEFFECTS sizeof(_ModernEffectNames)/sizeof(_ModernEffectNames[0])
+extern TCHAR * ModernEffectNames[];
#endif
extern BOOL SkinEngine_ResetTextEffect(HDC);
extern BOOL SkinEngine_SelectTextEffect(HDC hdc, BYTE EffectID, DWORD FirstColor, DWORD SecondColor);
\ No newline at end of file diff --git a/plugins/Clist_modern/src/hdr/modern_gettextasync.h b/plugins/Clist_modern/src/hdr/modern_gettextasync.h index 386b721b19..2a8c63296d 100644 --- a/plugins/Clist_modern/src/hdr/modern_gettextasync.h +++ b/plugins/Clist_modern/src/hdr/modern_gettextasync.h @@ -2,4 +2,4 @@ void InitCacheAsync();
void UninitCacheAsync();
void gtaRenewText(MCONTACT hContact);
-int gtaAddRequest(ClcData *dat,ClcContact *contact,MCONTACT hContact);
+int gtaAddRequest(ClcData *dat, MCONTACT hContact);
diff --git a/plugins/Clist_modern/src/hdr/modern_global_structure.h b/plugins/Clist_modern/src/hdr/modern_global_structure.h index 6572e96290..fd23199eaa 100644 --- a/plugins/Clist_modern/src/hdr/modern_global_structure.h +++ b/plugins/Clist_modern/src/hdr/modern_global_structure.h @@ -5,79 +5,79 @@ typedef struct tagCLUIDATA
{
- /************************************
- ** Global variables **
- ************************************/
-
- /* NotifyArea menu */
- HMENU hMenuNotify;
- WORD wNextMenuID;
- int iIconNotify;
- BOOL bEventAreaEnabled;
- BOOL bNotifyActive;
- DWORD dwFlags;
- int hIconNotify;
+ /************************************
+ ** Global variables **
+ ************************************/
+
+ /* NotifyArea menu */
+ HMENU hMenuNotify;
+ WORD wNextMenuID;
+ int iIconNotify;
+ BOOL bEventAreaEnabled;
+ BOOL bNotifyActive;
+ DWORD dwFlags;
+ int hIconNotify;
MCONTACT hUpdateContact;
- /* Contact List View Mode */
- TCHAR groupFilter[2048];
- char protoFilter[2048];
- char varFilter[2048];
- DWORD lastMsgFilter;
- char current_viewmode[256], old_viewmode[256];
- BYTE boldHideOffline;
- BYTE bOldUseGroups;
- DWORD statusMaskFilter;
- DWORD stickyMaskFilter;
- DWORD filterFlags;
- DWORD bFilterEffective;
- DWORD t_now;
-
- // Modern Global Variables
- BOOL fDisableSkinEngine;
- BOOL fOnDesktop;
- BOOL fSmoothAnimation;
- BOOL fLayered;
- BOOL fDocked;
- BOOL fSortNoOfflineBottom;
- BOOL fAutoSize;
- BOOL fAeroGlass;
- HRGN hAeroGlassRgn;
-
- BOOL mutexPreventDockMoving;
- BOOL mutexOnEdgeSizing;
- BOOL mutexPaintLock;
-
- BYTE bCurrentAlpha;
- BYTE bSTATE;
- BYTE bBehindEdgeSettings;
- BYTE bSortByOrder[3];
-
- signed char nBehindEdgeState;
-
- DWORD dwKeyColor;
-
- HWND hwndEventFrame;
-
- int LeftClientMargin;
- int RightClientMargin;
- int TopClientMargin;
- int BottomClientMargin;
-
- BOOL bInternalAwayMsgDiscovery;
- BOOL bRemoveAwayMessageForOffline;
-
- //hEventHandles
-
- HANDLE hEventBkgrChanged;
- HANDLE hEventPreBuildTrayMenu;
- HANDLE hEventPreBuildGroupMenu;
- HANDLE hEventPreBuildSubGroupMenu;
- HANDLE hEventStatusBarShowToolTip;
- HANDLE hEventStatusBarHideToolTip;
- HANDLE hEventSkinServicesCreated;
-
- int nGapBetweenTitlebar;
+ /* Contact List View Mode */
+ TCHAR groupFilter[2048];
+ char protoFilter[2048];
+ char varFilter[2048];
+ DWORD lastMsgFilter;
+ char current_viewmode[256], old_viewmode[256];
+ BYTE boldHideOffline;
+ BYTE bOldUseGroups;
+ DWORD statusMaskFilter;
+ DWORD stickyMaskFilter;
+ DWORD filterFlags;
+ DWORD bFilterEffective;
+ DWORD t_now;
+
+ // Modern Global Variables
+ BOOL fDisableSkinEngine;
+ BOOL fOnDesktop;
+ BOOL fSmoothAnimation;
+ BOOL fLayered;
+ BOOL fDocked;
+ BOOL fSortNoOfflineBottom;
+ BOOL fAutoSize;
+ BOOL fAeroGlass;
+ HRGN hAeroGlassRgn;
+
+ BOOL mutexPreventDockMoving;
+ BOOL mutexOnEdgeSizing;
+ BOOL mutexPaintLock;
+
+ BYTE bCurrentAlpha;
+ BYTE bSTATE;
+ BYTE bBehindEdgeSettings;
+ BYTE bSortByOrder[3];
+
+ signed char nBehindEdgeState;
+
+ DWORD dwKeyColor;
+
+ HWND hwndEventFrame;
+
+ int LeftClientMargin;
+ int RightClientMargin;
+ int TopClientMargin;
+ int BottomClientMargin;
+
+ BOOL bInternalAwayMsgDiscovery;
+ BOOL bRemoveAwayMessageForOffline;
+
+ //hEventHandles
+
+ HANDLE hEventBkgrChanged;
+ HANDLE hEventPreBuildTrayMenu;
+ HANDLE hEventPreBuildGroupMenu;
+ HANDLE hEventPreBuildSubGroupMenu;
+ HANDLE hEventStatusBarShowToolTip;
+ HANDLE hEventStatusBarHideToolTip;
+ HANDLE hEventSkinServicesCreated;
+
+ int nGapBetweenTitlebar;
} CLUIDATA;
EXTERN_C CLUIDATA g_CluiData;
diff --git a/plugins/Clist_modern/src/hdr/modern_layered_window_engine.h b/plugins/Clist_modern/src/hdr/modern_layered_window_engine.h index 5116828af5..0b9b3c685c 100644 --- a/plugins/Clist_modern/src/hdr/modern_layered_window_engine.h +++ b/plugins/Clist_modern/src/hdr/modern_layered_window_engine.h @@ -8,10 +8,10 @@ class CLayeredWindowEngine private:
/*class CLweInfo
{
- HWND hWnd;
- HRGN hInvalidRgn;
+ HWND hWnd;
+ HRGN hInvalidRgn;
};
- */
+ */
//typedef std::map<HWND, CLweInfo> WndInfos;
enum { state_invalid, state_normal };
@@ -29,18 +29,18 @@ public: void _init();
void _deinit();
- void lock() { EnterCriticalSection( &m_cs ); }
- void unlock() { LeaveCriticalSection( &m_cs ); }
+ void lock() { EnterCriticalSection(&m_cs); }
+ void unlock() { LeaveCriticalSection(&m_cs); }
int get_state();
public:
static void __cdecl LweValidatorProc();
-
+
void LweValidatorProcWorker();
void LweValidatorWorker();
- int LweInvalidateRect( HWND hWnd, const RECT *rect, BOOL bErase );
+ int LweInvalidateRect(HWND hWnd, const RECT *rect, BOOL bErase);
// int LweValidateWindowRect( HWND hWnd, RECT *rect );
// int RegisterWindow( HWND hwnd, tPaintCallbackProc pPaintCallBackProc );
diff --git a/plugins/Clist_modern/src/hdr/modern_row.h b/plugins/Clist_modern/src/hdr/modern_row.h index 4148a692a5..ad84c94071 100644 --- a/plugins/Clist_modern/src/hdr/modern_row.h +++ b/plugins/Clist_modern/src/hdr/modern_row.h @@ -65,23 +65,23 @@ typedef struct tagRowCell BOOL hasfixed; // Параметр показывающий что есть вложенные фиксированные элементы
BOOL fitwidth; // Параметр указывающий что последний элемент заполняет все оставшееся
- // Пространство (расстягивает родителя.оверлей)
+ // Пространство (расстягивает родителя.оверлей)
- int fixed_width;
- int full_width;
+ int fixed_width;
+ int full_width;
- RECT r; // Прямоугольник для рисования элемента
- struct tagRowCell * next; // Поле связи
- struct tagRowCell * child; // Поле связи см. файл описания
+ RECT r; // Прямоугольник для рисования элемента
+ struct tagRowCell * next; // Поле связи
+ struct tagRowCell * child; // Поле связи см. файл описания
}
- ROWCELL, *pROWCELL;
+ROWCELL, *pROWCELL;
// Структура для доступа к контейнерам элемента контакта внутри дерева опивания
#ifndef _CPPCODE
- int cppCalculateRowHeight(ROWCELL *RowRoot);
- void cppCalculateRowItemsPos(ROWCELL *RowRoot, int width);
- ROWCELL *cppInitModernRow(ROWCELL ** tabAccess);
- void cppDeleteTree(ROWCELL * RowRoot);
+int cppCalculateRowHeight(ROWCELL *RowRoot);
+void cppCalculateRowItemsPos(ROWCELL *RowRoot, int width);
+ROWCELL *cppInitModernRow(ROWCELL ** tabAccess);
+void cppDeleteTree(ROWCELL * RowRoot);
#endif
#endif // modern_row_h__
\ No newline at end of file diff --git a/plugins/Clist_modern/src/hdr/modern_skinengine.h b/plugins/Clist_modern/src/hdr/modern_skinengine.h index f920ba6072..581787b5a5 100644 --- a/plugins/Clist_modern/src/hdr/modern_skinengine.h +++ b/plugins/Clist_modern/src/hdr/modern_skinengine.h @@ -49,10 +49,10 @@ struct CURRWNDIMAGEDATA HBITMAP hBackDIB, hBackOld;
BYTE * hImageDIBByte;
BYTE * hBackDIBByte;
- int Width,Height;
+ int Width, Height;
};
-struct EFFECTSSTACKITEM
+struct EFFECTSSTACKITEM
{
HDC hdc;
BYTE EffectID;
@@ -93,7 +93,7 @@ public: enum { IT_UNKNOWN, IT_FILE, IT_RESOURCE };
- typedef HRESULT (*ParserCallback_t)( const char * szSection, const char * szKey, const char * szValue, IniParser * This );
+ typedef HRESULT(*ParserCallback_t)(const char * szSection, const char * szKey, const char * szValue, IniParser * This);
IniParser(TCHAR * szFileName, BYTE flags = FLAG_WITH_SETTINGS);
IniParser(HINSTANCE hInst, const char *resourceName, const char *resourceType, BYTE flags = FLAG_ONLY_OBJECTS);
@@ -102,12 +102,12 @@ public: bool CheckOK() { return _isValid; }
HRESULT Parse(ParserCallback_t pLineCallBackProc, LPARAM lParam);
- static HRESULT WriteStrToDb( const char * szSection, const char * szKey, const char * szValue, IniParser * This);
- static int GetSkinFolder( IN const TCHAR * szFileName, OUT TCHAR * pszFolderName );
+ static HRESULT WriteStrToDb(const char * szSection, const char * szKey, const char * szValue, IniParser * This);
+ static int GetSkinFolder(IN const TCHAR * szFileName, OUT TCHAR * pszFolderName);
private:
// common
- enum { MAX_LINE_LEN = 512 };
+ enum { MAX_LINE_LEN = 512 };
int _eType;
bool _isValid;
char * _szSection;
@@ -116,16 +116,16 @@ private: int _nLine;
void _DoInit();
- BOOL _DoParseLine( char * szLine );
+ BOOL _DoParseLine(char * szLine);
// Processing File
HRESULT _DoParseFile();
FILE * _hFile;
// Processing resource
- void _LoadResourceIni( HINSTANCE hInst, const char * resourceName, const char * resourceType );
+ void _LoadResourceIni(HINSTANCE hInst, const char * resourceName, const char * resourceType);
HRESULT _DoParseResource();
- const char * _RemoveTailings( const char * szLine, size_t& len );
+ const char * _RemoveTailings(const char * szLine, size_t& len);
HGLOBAL _hGlobalRes;
DWORD _dwSizeOfRes;
@@ -138,7 +138,7 @@ private: int ske_UnloadSkin(SKINOBJECTSLIST * Skin);
-int ske_AddDescriptorToSkinObjectList (SKINOBJECTDESCRIPTOR *lpDescr, SKINOBJECTSLIST* Skin);
+int ske_AddDescriptorToSkinObjectList(SKINOBJECTDESCRIPTOR *lpDescr, SKINOBJECTSLIST* Skin);
INT_PTR ske_Service_DrawGlyph(WPARAM wParam, LPARAM lParam);
diff --git a/plugins/Clist_modern/src/hdr/modern_skinned_profile.h b/plugins/Clist_modern/src/hdr/modern_skinned_profile.h index 20d662aee7..6da6e33821 100644 --- a/plugins/Clist_modern/src/hdr/modern_skinned_profile.h +++ b/plugins/Clist_modern/src/hdr/modern_skinned_profile.h @@ -10,38 +10,38 @@ class MString
{
-private:
+private:
TCHAR * _buffer;
public:
- MString() : _buffer( NULL ) {};
- MString( const TCHAR * str ) { _buffer = str ? _tcsdup( str ) : NULL; }
- MString( const MString& str ) { _buffer = str._buffer ? _tcsdup( str._buffer ) : NULL; }
- MString& operator=( const MString& str )
+ MString() : _buffer(NULL) {};
+ MString(const TCHAR * str) { _buffer = str ? _tcsdup(str) : NULL; }
+ MString(const MString& str) { _buffer = str._buffer ? _tcsdup(str._buffer) : NULL; }
+ MString& operator=(const MString& str)
{
- if ( _buffer ) free( _buffer );
- _buffer = str._buffer ? _tcsdup( str._buffer ) : NULL;
+ if (_buffer) free(_buffer);
+ _buffer = str._buffer ? _tcsdup(str._buffer) : NULL;
}
- TCHAR* operator()( const MString& str ) { return _buffer; }
+ TCHAR* operator()(const MString& str) { return _buffer; }
~MString()
{
- if ( _buffer )
- free( _buffer );
+ if (_buffer)
+ free(_buffer);
_buffer = NULL;
}
#ifdef _UNICODE
- MString( const char * str)
- {
- if (!str )
+ MString(const char * str)
+ {
+ if (!str)
_buffer = NULL;
else
{
- int cbLen = MultiByteToWideChar( 0, 0, str, -1, NULL, 0 );
- wchar_t* _buffer = ( wchar_t* )malloc( sizeof( wchar_t )*(cbLen+1));
- if ( _buffer == NULL ) return;
- MultiByteToWideChar( 0, 0, str, -1, _buffer, cbLen );
- _buffer[ cbLen ] = 0;
- }
+ int cbLen = MultiByteToWideChar(0, 0, str, -1, NULL, 0);
+ wchar_t* _buffer = (wchar_t*)malloc(sizeof(wchar_t)*(cbLen + 1));
+ if (_buffer == NULL) return;
+ MultiByteToWideChar(0, 0, str, -1, _buffer, cbLen);
+ _buffer[cbLen] = 0;
+ }
}
#endif
@@ -51,40 +51,40 @@ class CAutoCriticalSection {
public:
CAutoCriticalSection() //Init critical section here
- : _pLinkedCS( NULL )
+ : _pLinkedCS(NULL)
{
- InitializeCriticalSection( &_CS );
+ InitializeCriticalSection(&_CS);
_ifCSOwner = true;
- _ifLocked = false;
+ _ifLocked = false;
}
- CAutoCriticalSection( CAutoCriticalSection& Locker, bool doLock = true )
- : _pLinkedCS ( &Locker )
+ CAutoCriticalSection(CAutoCriticalSection& Locker, bool doLock = true)
+ : _pLinkedCS(&Locker)
{
_ifCSOwner = false;
- _ifLocked = false;
- if ( doLock )
+ _ifLocked = false;
+ if (doLock)
Lock();
}
~CAutoCriticalSection() // Leave if auto locker, and destroy if not
{
- if ( _ifLocked )
+ if (_ifLocked)
Unlock();
- if ( _ifCSOwner )
- DeleteCriticalSection( &_CS );
+ if (_ifCSOwner)
+ DeleteCriticalSection(&_CS);
}
void Lock() // Enter Section
{
- if ( _ifLocked ) return;
- if ( _ifCSOwner ) EnterCriticalSection( &_CS );
+ if (_ifLocked) return;
+ if (_ifCSOwner) EnterCriticalSection(&_CS);
else _pLinkedCS->Lock();
_ifLocked = true;
return;
- }
+ }
void Unlock() // Leave Section
{
- if (!_ifLocked ) return;
- if ( _ifCSOwner ) LeaveCriticalSection( &_CS );
+ if (!_ifLocked) return;
+ if (_ifCSOwner) LeaveCriticalSection(&_CS);
else _pLinkedCS->Unlock();
_ifLocked = false;
}
@@ -99,26 +99,26 @@ private: class ValueVariant
{
public:
- ValueVariant() : _type( VVT_EMPTY ) {};
- ValueVariant( BYTE bValue ) : _type( VVT_BYTE ), _bValue( bValue ) {};
- ValueVariant( WORD wValue ) : _type( VVT_WORD ), _wValue( wValue ) {};
- ValueVariant( DWORD dwValue ) : _type( VVT_DWORD ), _dwValue( dwValue ) {};
- ValueVariant( const MString& strValue ) : _type( VVT_STRING ), _strValue( strValue ) {};
- ValueVariant( const char * szValue ) : _type( VVT_STRING ), _strValue( szValue ) {};
+ ValueVariant() : _type(VVT_EMPTY) {};
+ ValueVariant(BYTE bValue) : _type(VVT_BYTE), _bValue(bValue) {};
+ ValueVariant(WORD wValue) : _type(VVT_WORD), _wValue(wValue) {};
+ ValueVariant(DWORD dwValue) : _type(VVT_DWORD), _dwValue(dwValue) {};
+ ValueVariant(const MString& strValue) : _type(VVT_STRING), _strValue(strValue) {};
+ ValueVariant(const char * szValue) : _type(VVT_STRING), _strValue(szValue) {};
#ifdef _UNICODE
- ValueVariant( const wchar_t * szValue ) : _type( VVT_STRING ), _strValue( szValue ) {};
+ ValueVariant(const wchar_t * szValue) : _type(VVT_STRING), _strValue(szValue) {};
#endif
-
+
BYTE GetByte()
{
- switch ( _type )
+ switch (_type)
{
case VVT_BYTE:
- return ( BYTE ) _bValue;
+ return (BYTE)_bValue;
case VVT_WORD:
case VVT_DWORD:
DebugBreak();
- return ( BYTE ) _bValue;
+ return (BYTE)_bValue;
default:
DebugBreak();
}
@@ -127,15 +127,15 @@ public: WORD GetWord()
{
- switch ( _type )
- {
+ switch (_type)
+ {
case VVT_WORD:
- return ( WORD ) _wValue;
+ return (WORD)_wValue;
case VVT_BYTE:
case VVT_DWORD:
DebugBreak();
- return ( WORD ) _wValue;
+ return (WORD)_wValue;
default:
DebugBreak();
}
@@ -144,15 +144,15 @@ public: DWORD GetDword()
{
- switch ( _type )
- {
+ switch (_type)
+ {
case VVT_DWORD:
- return ( DWORD ) _dwValue;
+ return (DWORD)_dwValue;
case VVT_BYTE:
case VVT_WORD:
DebugBreak();
- return ( DWORD ) _dwValue;
+ return (DWORD)_dwValue;
default:
DebugBreak();
}
@@ -160,8 +160,8 @@ public: }
MString GetString()
{
- switch ( _type )
- {
+ switch (_type)
+ {
case VVT_STRING:
return _strValue;
@@ -172,8 +172,8 @@ public: }
const MString& GetStringStatic()
{
- switch ( _type )
- {
+ switch (_type)
+ {
case VVT_STRING:
return _strValue;
@@ -182,10 +182,10 @@ public: }
return _strValue;
}
- bool IsEmpty() { return _type==VVT_EMPTY; }
+ bool IsEmpty() { return _type == VVT_EMPTY; }
private:
- enum
+ enum
{
VVT_EMPTY = 0,
VVT_BYTE,
@@ -223,7 +223,7 @@ private: KeyList_t SkinnedProfile;
- ValueVariant* _GetValue( const char * szSection, const char * szKey );
+ ValueVariant* _GetValue(const char * szSection, const char * szKey);
CAutoCriticalSection _Lock; // critical section to matable skinned profile access
@@ -233,10 +233,10 @@ public: HRESULT Init();
HRESULT Clear();
- static BYTE SpiGetSkinByte (MCONTACT hContact, const char * szSection, const char * szKey, const BYTE defValue );
- static WORD SpiGetSkinWord (MCONTACT hContact, const char * szSection, const char * szKey, const WORD defValue );
- static DWORD SpiGetSkinDword(MCONTACT hContact, const char * szSection, const char * szKey, const DWORD defValue );
- static BOOL SpiCheckSkinned(MCONTACT hContact, const char * szSection, const char * szKey );
+ static BYTE SpiGetSkinByte(MCONTACT hContact, const char * szSection, const char * szKey, const BYTE defValue);
+ static WORD SpiGetSkinWord(MCONTACT hContact, const char * szSection, const char * szKey, const WORD defValue);
+ static DWORD SpiGetSkinDword(MCONTACT hContact, const char * szSection, const char * szKey, const DWORD defValue);
+ static BOOL SpiCheckSkinned(MCONTACT hContact, const char * szSection, const char * szKey);
};
diff --git a/plugins/Clist_modern/src/hdr/modern_skinselector.h b/plugins/Clist_modern/src/hdr/modern_skinselector.h index 09576c054d..48c6ecdfde 100644 --- a/plugins/Clist_modern/src/hdr/modern_skinselector.h +++ b/plugins/Clist_modern/src/hdr/modern_skinselector.h @@ -66,22 +66,22 @@ struct LISTMODERNMASK /// PROTOTYPES
int AddModernMaskToList(MODERNMASK *mm, LISTMODERNMASK *mmTemplateList);
-int AddStrModernMaskToList(DWORD maskID, char *szStr, char *objectName, LISTMODERNMASK *mmTemplateList, void *pObjectList);
+int AddStrModernMaskToList(DWORD maskID, char *szStr, char *objectName, LISTMODERNMASK *mmTemplateList);
int SortMaskList(LISTMODERNMASK *mmList);
-int DeleteMaskByItID(DWORD mID,LISTMODERNMASK *mmTemplateList);
+int DeleteMaskByItID(DWORD mID, LISTMODERNMASK *mmTemplateList);
int ClearMaskList(LISTMODERNMASK *mmTemplateList);
int ExchangeMasksByID(DWORD mID1, DWORD mID2, LISTMODERNMASK *mmTemplateList);
int ParseToModernMask(MODERNMASK *mm, char *szText);
-BOOL CompareModernMask(MODERNMASK *mmValue,MODERNMASK *mmTemplate);
-BOOL CompareStrWithModernMask(char * szValue,MODERNMASK *mmTemplate);
-MODERNMASK * FindMaskByStr(char * szValue,LISTMODERNMASK * mmTemplateList);
+BOOL CompareModernMask(MODERNMASK *mmValue, MODERNMASK *mmTemplate);
+BOOL CompareStrWithModernMask(char * szValue, MODERNMASK *mmTemplate);
+MODERNMASK * FindMaskByStr(char * szValue, LISTMODERNMASK * mmTemplateList);
DWORD mod_CalcHash(const char * a);
char * ModernMaskToString(MODERNMASK *mm, char *buf, UINT bufsize);
int RegisterObjectByParce(char * ObjectName, char *Params);
-SKINOBJECTDESCRIPTOR* skin_FindObjectByRequest(char *szValue,LISTMODERNMASK *mmTemplateList);
-SKINOBJECTDESCRIPTOR* skin_FindObjectByMask (MODERNMASK *mm,LISTMODERNMASK *mmTemplateList);
+SKINOBJECTDESCRIPTOR* skin_FindObjectByRequest(char *szValue, LISTMODERNMASK *mmTemplateList);
+SKINOBJECTDESCRIPTOR* skin_FindObjectByMask(MODERNMASK *mm, LISTMODERNMASK *mmTemplateList);
TCHAR * GetParamNT(char * string, TCHAR * buf, int buflen, BYTE paramN, char Delim, BOOL SkipSpaces);
int SkinDrawGlyphMask(HDC hdc, RECT *rcSize, RECT *rcClip, MODERNMASK *ModernMask);
#endif
diff --git a/plugins/Clist_modern/src/hdr/modern_static_clui.h b/plugins/Clist_modern/src/hdr/modern_static_clui.h index 552337cb65..7d19d6dd92 100644 --- a/plugins/Clist_modern/src/hdr/modern_static_clui.h +++ b/plugins/Clist_modern/src/hdr/modern_static_clui.h @@ -67,7 +67,7 @@ int CListSettings_SetToCache(ClcCacheEntry *pSrc, DWORD flag); int CLUIServices_LoadModule(void); INT_PTR CLUIServices_SortList(WPARAM wParam, LPARAM lParam); -void Docking_GetMonitorRectFromWindow(HWND hWnd,RECT *rc); +void Docking_GetMonitorRectFromWindow(HWND hWnd, RECT *rc); int EventArea_Create(HWND hCluiWnd); @@ -76,7 +76,7 @@ int ExtraImage_ExtraIDToColumnNum(int extra); void GroupMenus_Init(); int ModernSkinButtonLoadModule(); -int ModernSkinButton_ReposButtons(HWND parent, BYTE draw,RECT *r); +int ModernSkinButton_ReposButtons(HWND parent, BYTE draw, RECT *r); void ske_ApplyTranslucency(); HBITMAP ske_CreateDIB32(int cx, int cy); @@ -100,7 +100,7 @@ int CLUI_SizingOnBorder(POINT pt, int size); int CLUI_SmoothAlphaTransition(HWND hwnd, BYTE GoalAlpha, BOOL wParam); int CLUI_TestCursorOnBorders(); -static int CLUI_SmoothAlphaThreadTransition(HWND hwnd); +static int CLUI_SmoothAlphaThreadTransition(); /* structs */ diff --git a/plugins/Clist_modern/src/hdr/modern_static_cluiframes_service.h b/plugins/Clist_modern/src/hdr/modern_static_cluiframes_service.h index fdcbe3192b..7a4ce4007a 100644 --- a/plugins/Clist_modern/src/hdr/modern_static_cluiframes_service.h +++ b/plugins/Clist_modern/src/hdr/modern_static_cluiframes_service.h @@ -27,8 +27,8 @@ static int _us_DoAlignFrameClient(WPARAM wParam, LPARAM lParam); static int _us_DoAlignFrameBottom(WPARAM wParam, LPARAM lParam);
static int _us_DoSetFrameFloat(WPARAM wParam, LPARAM lParam);
-enum {
- CFM_FIRST_MGS= WM_USER + 0x2FF,
+enum {
+ CFM_FIRST_MGS = WM_USER + 0x2FF,
CFM_SETFRAMEPAINTPROC,
CFM_ADDFRAME,
@@ -58,34 +58,34 @@ enum { #define CLM_PROCESS( msg, proc ) case msg: result = proc( wParam, lParam); break;
-BOOL CALLBACK ProcessCLUIFrameInternalMsg(HWND hwnd, UINT msg, WPARAM wParam, LPARAM lParam, LRESULT& result )
+BOOL CALLBACK ProcessCLUIFrameInternalMsg(HWND, UINT msg, WPARAM wParam, LPARAM lParam, LRESULT& result)
{
- if ( msg <= CFM_FIRST_MGS || msg >= CFM_LAST_MSG )
+ if (msg <= CFM_FIRST_MGS || msg >= CFM_LAST_MSG)
return FALSE;
- switch ( msg ) {
- CLM_PROCESS( CFM_SETFRAMEPAINTPROC, _us_DoSetFramePaintProc );
- CLM_PROCESS( CFM_ADDFRAME, _us_DoAddFrame );
- CLM_PROCESS( CFM_REMOVEFRAME, _us_DoRemoveFrame );
- CLM_PROCESS( CFM_SETFRAMEOPTIONS, _us_DoSetFrameOptions );
- CLM_PROCESS( CFM_GETFRAMEOPTIONS, _us_DoGetFrameOptions );
- CLM_PROCESS( CFM_UPDATEFRAME, _us_DoUpdateFrame );
- CLM_PROCESS( CFM_SHOWHIDEFRAMETITLE, _us_DoShowHideFrameTitle );
- CLM_PROCESS( CFM_SHOWTITLES, _us_DoShowTitles );
- CLM_PROCESS( CFM_HIDETITLES, _us_DoHideTitles );
- CLM_PROCESS( CFM_SHOWHIDEFRAME, _us_DoShowHideFrame );
- CLM_PROCESS( CFM_SHOWALL, _us_DoShowAllFrames );
- CLM_PROCESS( CFM_LOCKFRAME, _us_DoLockFrame );
- CLM_PROCESS( CFM_COLLAPSEFRAME, _us_DoCollapseFrame );
- CLM_PROCESS( CFM_SETFRAMEBORDER, _us_DoSetFrameBorder );
- CLM_PROCESS( CFM_SETFRAMEALIGN, _us_DoSetFrameAlign );
- CLM_PROCESS( CFM_MOVEFRAME, _us_DoMoveFrame );
- CLM_PROCESS( CFM_MOVEFRAMEUP, _us_DoMoveFrameUp );
- CLM_PROCESS( CFM_MOVEFRAMEDOWN, _us_DoMoveFrameDown );
- CLM_PROCESS( CFM_ALIGNFRAMETOP, _us_DoAlignFrameTop );
- CLM_PROCESS( CFM_ALIGNFRAMEBOTTOM, _us_DoAlignFrameClient );
- CLM_PROCESS( CFM_ALIGNFRAMECLIENT, _us_DoAlignFrameBottom );
- CLM_PROCESS( CFM_SETFRAMEFLOAT, _us_DoSetFrameFloat );
+ switch (msg) {
+ CLM_PROCESS(CFM_SETFRAMEPAINTPROC, _us_DoSetFramePaintProc);
+ CLM_PROCESS(CFM_ADDFRAME, _us_DoAddFrame);
+ CLM_PROCESS(CFM_REMOVEFRAME, _us_DoRemoveFrame);
+ CLM_PROCESS(CFM_SETFRAMEOPTIONS, _us_DoSetFrameOptions);
+ CLM_PROCESS(CFM_GETFRAMEOPTIONS, _us_DoGetFrameOptions);
+ CLM_PROCESS(CFM_UPDATEFRAME, _us_DoUpdateFrame);
+ CLM_PROCESS(CFM_SHOWHIDEFRAMETITLE, _us_DoShowHideFrameTitle);
+ CLM_PROCESS(CFM_SHOWTITLES, _us_DoShowTitles);
+ CLM_PROCESS(CFM_HIDETITLES, _us_DoHideTitles);
+ CLM_PROCESS(CFM_SHOWHIDEFRAME, _us_DoShowHideFrame);
+ CLM_PROCESS(CFM_SHOWALL, _us_DoShowAllFrames);
+ CLM_PROCESS(CFM_LOCKFRAME, _us_DoLockFrame);
+ CLM_PROCESS(CFM_COLLAPSEFRAME, _us_DoCollapseFrame);
+ CLM_PROCESS(CFM_SETFRAMEBORDER, _us_DoSetFrameBorder);
+ CLM_PROCESS(CFM_SETFRAMEALIGN, _us_DoSetFrameAlign);
+ CLM_PROCESS(CFM_MOVEFRAME, _us_DoMoveFrame);
+ CLM_PROCESS(CFM_MOVEFRAMEUP, _us_DoMoveFrameUp);
+ CLM_PROCESS(CFM_MOVEFRAMEDOWN, _us_DoMoveFrameDown);
+ CLM_PROCESS(CFM_ALIGNFRAMETOP, _us_DoAlignFrameTop);
+ CLM_PROCESS(CFM_ALIGNFRAMEBOTTOM, _us_DoAlignFrameClient);
+ CLM_PROCESS(CFM_ALIGNFRAMECLIENT, _us_DoAlignFrameBottom);
+ CLM_PROCESS(CFM_SETFRAMEFLOAT, _us_DoSetFrameFloat);
default:
return FALSE; // Not Handled
}
@@ -93,99 +93,143 @@ BOOL CALLBACK ProcessCLUIFrameInternalMsg(HWND hwnd, UINT msg, WPARAM wParam, LP }
static INT_PTR CLUIFrames_SetFramePaintProc(WPARAM wParam, LPARAM lParam)
-{ return ( pcli->hwndContactList ) ? SendMessage( pcli->hwndContactList, CFM_SETFRAMEPAINTPROC, wParam,lParam) : 0; }
+{
+ return (pcli->hwndContactList) ? SendMessage(pcli->hwndContactList, CFM_SETFRAMEPAINTPROC, wParam, lParam) : 0;
+}
static INT_PTR CLUIFrames_AddFrame(WPARAM wParam, LPARAM lParam)
-{ return ( pcli->hwndContactList ) ? SendMessage( pcli->hwndContactList, CFM_ADDFRAME, wParam, lParam) : 0; }
+{
+ return (pcli->hwndContactList) ? SendMessage(pcli->hwndContactList, CFM_ADDFRAME, wParam, lParam) : 0;
+}
static INT_PTR CLUIFrames_RemoveFrame(WPARAM wParam, LPARAM lParam)
-{ return ( pcli->hwndContactList ) ? SendMessage( pcli->hwndContactList, CFM_REMOVEFRAME, wParam, lParam) : 0; }
+{
+ return (pcli->hwndContactList) ? SendMessage(pcli->hwndContactList, CFM_REMOVEFRAME, wParam, lParam) : 0;
+}
static INT_PTR CLUIFrames_SetFrameOptions(WPARAM wParam, LPARAM lParam)
-{ return ( pcli->hwndContactList ) ? SendMessage( pcli->hwndContactList, CFM_SETFRAMEOPTIONS, wParam, lParam) : 0; }
+{
+ return (pcli->hwndContactList) ? SendMessage(pcli->hwndContactList, CFM_SETFRAMEOPTIONS, wParam, lParam) : 0;
+}
static INT_PTR CLUIFrames_GetFrameOptions(WPARAM wParam, LPARAM lParam)
-{ return ( pcli->hwndContactList ) ? SendMessage( pcli->hwndContactList, CFM_GETFRAMEOPTIONS, wParam, lParam) : 0; }
+{
+ return (pcli->hwndContactList) ? SendMessage(pcli->hwndContactList, CFM_GETFRAMEOPTIONS, wParam, lParam) : 0;
+}
static INT_PTR CLUIFrames_UpdateFrame(WPARAM wParam, LPARAM lParam)
-{ return ( pcli->hwndContactList ) ? SendMessage( pcli->hwndContactList, CFM_UPDATEFRAME, wParam, lParam) : 0; }
+{
+ return (pcli->hwndContactList) ? SendMessage(pcli->hwndContactList, CFM_UPDATEFRAME, wParam, lParam) : 0;
+}
static INT_PTR CLUIFrames_ShowHideFrameTitle(WPARAM wParam, LPARAM lParam)
-{ return ( pcli->hwndContactList ) ? SendMessage( pcli->hwndContactList, CFM_SHOWHIDEFRAMETITLE, wParam, lParam) : 0; }
+{
+ return (pcli->hwndContactList) ? SendMessage(pcli->hwndContactList, CFM_SHOWHIDEFRAMETITLE, wParam, lParam) : 0;
+}
static INT_PTR CLUIFrames_ShowTitles(WPARAM wParam, LPARAM lParam)
-{ return ( pcli->hwndContactList ) ? SendMessage( pcli->hwndContactList, CFM_SHOWTITLES, wParam, lParam) : 0; }
+{
+ return (pcli->hwndContactList) ? SendMessage(pcli->hwndContactList, CFM_SHOWTITLES, wParam, lParam) : 0;
+}
static INT_PTR CLUIFrames_HideTitles(WPARAM wParam, LPARAM lParam)
-{ return ( pcli->hwndContactList ) ? SendMessage( pcli->hwndContactList, CFM_HIDETITLES, wParam, lParam) : 0; }
+{
+ return (pcli->hwndContactList) ? SendMessage(pcli->hwndContactList, CFM_HIDETITLES, wParam, lParam) : 0;
+}
static INT_PTR CLUIFrames_ShowHideFrame(WPARAM wParam, LPARAM lParam)
-{ return ( pcli->hwndContactList ) ? SendMessage( pcli->hwndContactList, CFM_SHOWHIDEFRAME, wParam, lParam) : 0; }
+{
+ return (pcli->hwndContactList) ? SendMessage(pcli->hwndContactList, CFM_SHOWHIDEFRAME, wParam, lParam) : 0;
+}
static INT_PTR CLUIFrames_ShowAllFrames(WPARAM wParam, LPARAM lParam)
-{ return ( pcli->hwndContactList ) ? SendMessage( pcli->hwndContactList, CFM_SHOWALL, wParam, lParam) : 0; }
+{
+ return (pcli->hwndContactList) ? SendMessage(pcli->hwndContactList, CFM_SHOWALL, wParam, lParam) : 0;
+}
static INT_PTR CLUIFrames_LockFrame(WPARAM wParam, LPARAM lParam)
-{ return ( pcli->hwndContactList ) ? SendMessage( pcli->hwndContactList, CFM_LOCKFRAME, wParam, lParam) : 0; }
+{
+ return (pcli->hwndContactList) ? SendMessage(pcli->hwndContactList, CFM_LOCKFRAME, wParam, lParam) : 0;
+}
static INT_PTR CLUIFrames_CollapseFrame(WPARAM wParam, LPARAM lParam)
-{ return ( pcli->hwndContactList ) ? SendMessage( pcli->hwndContactList, CFM_COLLAPSEFRAME, wParam, lParam) : 0; }
+{
+ return (pcli->hwndContactList) ? SendMessage(pcli->hwndContactList, CFM_COLLAPSEFRAME, wParam, lParam) : 0;
+}
static INT_PTR CLUIFrames_SetFrameBorder(WPARAM wParam, LPARAM lParam)
-{ return ( pcli->hwndContactList ) ? SendMessage( pcli->hwndContactList, CFM_SETFRAMEBORDER, wParam, lParam) : 0; }
+{
+ return (pcli->hwndContactList) ? SendMessage(pcli->hwndContactList, CFM_SETFRAMEBORDER, wParam, lParam) : 0;
+}
static INT_PTR CLUIFrames_SetFrameAlign(WPARAM wParam, LPARAM lParam)
-{ return ( pcli->hwndContactList ) ? SendMessage( pcli->hwndContactList, CFM_SETFRAMEALIGN, wParam, lParam) : 0; }
+{
+ return (pcli->hwndContactList) ? SendMessage(pcli->hwndContactList, CFM_SETFRAMEALIGN, wParam, lParam) : 0;
+}
static INT_PTR CLUIFrames_MoveFrame(WPARAM wParam, LPARAM lParam)
-{ return ( pcli->hwndContactList ) ? SendMessage( pcli->hwndContactList, CFM_MOVEFRAME, wParam, lParam) : 0; }
+{
+ return (pcli->hwndContactList) ? SendMessage(pcli->hwndContactList, CFM_MOVEFRAME, wParam, lParam) : 0;
+}
static INT_PTR CLUIFrames_MoveFrameUp(WPARAM wParam, LPARAM lParam)
-{ return ( pcli->hwndContactList ) ? SendMessage( pcli->hwndContactList, CFM_MOVEFRAMEUP, wParam, lParam) : 0; }
+{
+ return (pcli->hwndContactList) ? SendMessage(pcli->hwndContactList, CFM_MOVEFRAMEUP, wParam, lParam) : 0;
+}
static INT_PTR CLUIFrames_MoveFrameDown(WPARAM wParam, LPARAM lParam)
-{ return ( pcli->hwndContactList ) ? SendMessage( pcli->hwndContactList, CFM_MOVEFRAMEDOWN, wParam, lParam) : 0; }
+{
+ return (pcli->hwndContactList) ? SendMessage(pcli->hwndContactList, CFM_MOVEFRAMEDOWN, wParam, lParam) : 0;
+}
static INT_PTR CLUIFrames_AlignFrameTop(WPARAM wParam, LPARAM lParam)
-{ return ( pcli->hwndContactList ) ? SendMessage( pcli->hwndContactList, CFM_ALIGNFRAMETOP, wParam, lParam) : 0; }
+{
+ return (pcli->hwndContactList) ? SendMessage(pcli->hwndContactList, CFM_ALIGNFRAMETOP, wParam, lParam) : 0;
+}
static INT_PTR CLUIFrames_AlignFrameClient(WPARAM wParam, LPARAM lParam)
-{ return ( pcli->hwndContactList ) ? SendMessage( pcli->hwndContactList, CFM_ALIGNFRAMEBOTTOM, wParam, lParam) : 0; }
+{
+ return (pcli->hwndContactList) ? SendMessage(pcli->hwndContactList, CFM_ALIGNFRAMEBOTTOM, wParam, lParam) : 0;
+}
static INT_PTR CLUIFrames_AlignFrameBottom(WPARAM wParam, LPARAM lParam)
-{ return ( pcli->hwndContactList ) ? SendMessage( pcli->hwndContactList, CFM_ALIGNFRAMECLIENT, wParam, lParam) : 0; }
+{
+ return (pcli->hwndContactList) ? SendMessage(pcli->hwndContactList, CFM_ALIGNFRAMECLIENT, wParam, lParam) : 0;
+}
static INT_PTR CLUIFrames_SetFrameFloat(WPARAM wParam, LPARAM lParam)
-{ return ( pcli->hwndContactList ) ? SendMessage( pcli->hwndContactList, CFM_SETFRAMEFLOAT, wParam, lParam) : 0; }
+{
+ return (pcli->hwndContactList) ? SendMessage(pcli->hwndContactList, CFM_SETFRAMEFLOAT, wParam, lParam) : 0;
+}
static void CreateCluiFramesServices()
{
- CreateServiceFunction( MS_SKINENG_REGISTERPAINTSUB, CLUIFrames_SetFramePaintProc );
- CreateServiceFunction( MS_CLIST_FRAMES_ADDFRAME, CLUIFrames_AddFrame );
- CreateServiceFunction( MS_CLIST_FRAMES_REMOVEFRAME, CLUIFrames_RemoveFrame );
-
- CreateServiceFunction( MS_CLIST_FRAMES_SETFRAMEOPTIONS, CLUIFrames_SetFrameOptions );
- CreateServiceFunction( MS_CLIST_FRAMES_GETFRAMEOPTIONS, CLUIFrames_GetFrameOptions );
- CreateServiceFunction( MS_CLIST_FRAMES_UPDATEFRAME, CLUIFrames_UpdateFrame );
-
- CreateServiceFunction( MS_CLIST_FRAMES_SHFRAMETITLEBAR, CLUIFrames_ShowHideFrameTitle );
- CreateServiceFunction( MS_CLIST_FRAMES_SHOWALLFRAMESTB, CLUIFrames_ShowTitles );
- CreateServiceFunction( MS_CLIST_FRAMES_HIDEALLFRAMESTB, CLUIFrames_HideTitles );
- CreateServiceFunction( MS_CLIST_FRAMES_SHFRAME, CLUIFrames_ShowHideFrame );
- CreateServiceFunction( MS_CLIST_FRAMES_SHOWALLFRAMES, CLUIFrames_ShowAllFrames );
-
- CreateServiceFunction( MS_CLIST_FRAMES_ULFRAME, CLUIFrames_LockFrame );
- CreateServiceFunction( MS_CLIST_FRAMES_UCOLLFRAME, CLUIFrames_CollapseFrame );
- CreateServiceFunction( MS_CLIST_FRAMES_SETUNBORDER, CLUIFrames_SetFrameBorder );
-
- CreateServiceFunction( CLUIFRAMESSETALIGN, CLUIFrames_SetFrameAlign );
- CreateServiceFunction( CLUIFRAMESMOVEUPDOWN, CLUIFrames_MoveFrame );
- CreateServiceFunction( CLUIFRAMESMOVEUP, CLUIFrames_MoveFrameUp );
- CreateServiceFunction( CLUIFRAMESMOVEDOWN, CLUIFrames_MoveFrameDown );
-
- CreateServiceFunction( CLUIFRAMESSETALIGNALTOP, CLUIFrames_AlignFrameTop );
- CreateServiceFunction( CLUIFRAMESSETALIGNALCLIENT, CLUIFrames_AlignFrameClient );
- CreateServiceFunction( CLUIFRAMESSETALIGNALBOTTOM, CLUIFrames_AlignFrameBottom );
-
- CreateServiceFunction( CLUIFRAMESSETFLOATING, CLUIFrames_SetFrameFloat );
+ CreateServiceFunction(MS_SKINENG_REGISTERPAINTSUB, CLUIFrames_SetFramePaintProc);
+ CreateServiceFunction(MS_CLIST_FRAMES_ADDFRAME, CLUIFrames_AddFrame);
+ CreateServiceFunction(MS_CLIST_FRAMES_REMOVEFRAME, CLUIFrames_RemoveFrame);
+
+ CreateServiceFunction(MS_CLIST_FRAMES_SETFRAMEOPTIONS, CLUIFrames_SetFrameOptions);
+ CreateServiceFunction(MS_CLIST_FRAMES_GETFRAMEOPTIONS, CLUIFrames_GetFrameOptions);
+ CreateServiceFunction(MS_CLIST_FRAMES_UPDATEFRAME, CLUIFrames_UpdateFrame);
+
+ CreateServiceFunction(MS_CLIST_FRAMES_SHFRAMETITLEBAR, CLUIFrames_ShowHideFrameTitle);
+ CreateServiceFunction(MS_CLIST_FRAMES_SHOWALLFRAMESTB, CLUIFrames_ShowTitles);
+ CreateServiceFunction(MS_CLIST_FRAMES_HIDEALLFRAMESTB, CLUIFrames_HideTitles);
+ CreateServiceFunction(MS_CLIST_FRAMES_SHFRAME, CLUIFrames_ShowHideFrame);
+ CreateServiceFunction(MS_CLIST_FRAMES_SHOWALLFRAMES, CLUIFrames_ShowAllFrames);
+
+ CreateServiceFunction(MS_CLIST_FRAMES_ULFRAME, CLUIFrames_LockFrame);
+ CreateServiceFunction(MS_CLIST_FRAMES_UCOLLFRAME, CLUIFrames_CollapseFrame);
+ CreateServiceFunction(MS_CLIST_FRAMES_SETUNBORDER, CLUIFrames_SetFrameBorder);
+
+ CreateServiceFunction(CLUIFRAMESSETALIGN, CLUIFrames_SetFrameAlign);
+ CreateServiceFunction(CLUIFRAMESMOVEUPDOWN, CLUIFrames_MoveFrame);
+ CreateServiceFunction(CLUIFRAMESMOVEUP, CLUIFrames_MoveFrameUp);
+ CreateServiceFunction(CLUIFRAMESMOVEDOWN, CLUIFrames_MoveFrameDown);
+
+ CreateServiceFunction(CLUIFRAMESSETALIGNALTOP, CLUIFrames_AlignFrameTop);
+ CreateServiceFunction(CLUIFRAMESSETALIGNALCLIENT, CLUIFrames_AlignFrameClient);
+ CreateServiceFunction(CLUIFRAMESSETALIGNALBOTTOM, CLUIFrames_AlignFrameBottom);
+
+ CreateServiceFunction(CLUIFRAMESSETFLOATING, CLUIFrames_SetFrameFloat);
}
diff --git a/plugins/Clist_modern/src/hdr/modern_statusbar.h b/plugins/Clist_modern/src/hdr/modern_statusbar.h index 9291f2d2c3..2339ed2c51 100644 --- a/plugins/Clist_modern/src/hdr/modern_statusbar.h +++ b/plugins/Clist_modern/src/hdr/modern_statusbar.h @@ -9,35 +9,35 @@ int ModernDrawStatusBar(HWND hwnd, HDC hDC);
int ModernDrawStatusBarWorker(HWND hWnd, HDC hDC);
-typedef struct tagSTATUSBARDATA
+typedef struct tagSTATUSBARDATA
{
- BOOL sameWidth;
- RECT rectBorders;
- BYTE extraspace;
- BYTE Align;
- BYTE VAlign;
- bool bShowProtoIcon;
- bool bShowProtoName;
- bool bShowStatusName;
- bool bConnectingIcon;
- HFONT BarFont;
- DWORD fontColor;
- BYTE TextEffectID;
- DWORD TextEffectColor1;
- DWORD TextEffectColor2;
- BYTE xStatusMode; // 0-only main, 1-xStatus, 2-main as overlay
- BYTE nProtosPerLine;
- bool bShowProtoEmails;
-
- HBITMAP hBmpBackground;
- COLORREF bkColour;
- DWORD backgroundBmpUse;
- BOOL bkUseWinColors;
-
- XPTHANDLE hTheme;
-
- BOOL perProtoConfig;
- BYTE SBarRightClk;
+ BOOL sameWidth;
+ RECT rectBorders;
+ BYTE extraspace;
+ BYTE Align;
+ BYTE VAlign;
+ bool bShowProtoIcon;
+ bool bShowProtoName;
+ bool bShowStatusName;
+ bool bConnectingIcon;
+ HFONT BarFont;
+ DWORD fontColor;
+ BYTE TextEffectID;
+ DWORD TextEffectColor1;
+ DWORD TextEffectColor2;
+ BYTE xStatusMode; // 0-only main, 1-xStatus, 2-main as overlay
+ BYTE nProtosPerLine;
+ bool bShowProtoEmails;
+
+ HBITMAP hBmpBackground;
+ COLORREF bkColour;
+ DWORD backgroundBmpUse;
+ BOOL bkUseWinColors;
+
+ XPTHANDLE hTheme;
+
+ BOOL perProtoConfig;
+ BYTE SBarRightClk;
} STATUSBARDATA;
diff --git a/plugins/Clist_modern/src/hdr/modern_sync.h b/plugins/Clist_modern/src/hdr/modern_sync.h index afa11a1002..0b5a827f11 100644 --- a/plugins/Clist_modern/src/hdr/modern_sync.h +++ b/plugins/Clist_modern/src/hdr/modern_sync.h @@ -1,38 +1,38 @@ #ifndef modern_sync_h__
#define modern_sync_h__
-typedef INT_PTR (*PSYNCCALLBACKPROC)(WPARAM,LPARAM);
+typedef INT_PTR(*PSYNCCALLBACKPROC)(WPARAM, LPARAM);
-int SyncCall(void * vproc, int count, ... );
+int SyncCall(void * vproc, int count, ...);
// Experimental sync caller
-int DoCall( PSYNCCALLBACKPROC pfnProc, WPARAM wParam, LPARAM lParam);
+int DoCall(PSYNCCALLBACKPROC pfnProc, WPARAM wParam, LPARAM lParam);
// Have to be here due to MS Visual C++ does not support 'export' keyword
// 3 params
template<class RET, class A, class B, class C> class PARAMS3
-{
+{
typedef RET(*proc_t)(A, B, C);
- proc_t _proc; A _a; B _b; C _c; RET _ret;
+ proc_t _proc; A _a; B _b; C _c; RET _ret;
public:
- PARAMS3( proc_t __proc, A __a, B __b, C __c ): _proc( __proc), _a (__a), _b(__b), _c(__c){};
- static int DoSyncCall(WPARAM wParam, LPARAM lParam)
+ PARAMS3(proc_t __proc, A __a, B __b, C __c) : _proc(__proc), _a(__a), _b(__b), _c(__c){};
+ static int DoSyncCall(WPARAM, LPARAM lParam)
{
- PARAMS3 * params = (PARAMS3 *) lParam;
- params->_ret = params->_proc( params->_a, params->_b, params->_c );
+ PARAMS3 * params = (PARAMS3 *)lParam;
+ params->_ret = params->_proc(params->_a, params->_b, params->_c);
return 0;
};
RET GetResult() { return _ret; }
};
-template< class RET, class Ap, class Bp, class Cp, class A, class B, class C> RET Sync( RET(*proc)(Ap, Bp, Cp), A a, B b, C c )
+template< class RET, class Ap, class Bp, class Cp, class A, class B, class C> RET Sync(RET(*proc)(Ap, Bp, Cp), A a, B b, C c)
{
- PARAMS3<RET, Ap, Bp, Cp> params( proc, a, b, c );
- DoCall((PSYNCCALLBACKPROC) PARAMS3<RET, Ap, Bp, Cp>::DoSyncCall, 0, (LPARAM) ¶ms );
+ PARAMS3<RET, Ap, Bp, Cp> params(proc, a, b, c);
+ DoCall((PSYNCCALLBACKPROC)PARAMS3<RET, Ap, Bp, Cp>::DoSyncCall, 0, (LPARAM)¶ms);
return params.GetResult();
};
@@ -40,50 +40,50 @@ template< class RET, class Ap, class Bp, class Cp, class A, class B, class C> RE // 2 params
template<class RET, class A, class B> class PARAMS2
-{
+{
typedef RET(*proc_t)(A, B);
- proc_t _proc; A _a; B _b; RET _ret;
+ proc_t _proc; A _a; B _b; RET _ret;
public:
- PARAMS2( proc_t __proc, A __a, B __b ): _proc( __proc), _a (__a), _b(__b){};
- static int DoSyncCall(WPARAM wParam, LPARAM lParam)
+ PARAMS2(proc_t __proc, A __a, B __b) : _proc(__proc), _a(__a), _b(__b){};
+ static int DoSyncCall(WPARAM, LPARAM lParam)
{
- PARAMS2 * params = (PARAMS2 *) lParam;
- params->_ret = params->_proc( params->_a, params->_b );
+ PARAMS2 * params = (PARAMS2 *)lParam;
+ params->_ret = params->_proc(params->_a, params->_b);
return 0;
};
RET GetResult() { return _ret; }
};
-template< class RET, class Ap, class Bp, class A, class B> RET Sync( RET(*proc)(Ap, Bp), A a, B b )
+template< class RET, class Ap, class Bp, class A, class B> RET Sync(RET(*proc)(Ap, Bp), A a, B b)
{
- PARAMS2<RET, Ap, Bp> params( proc, a, b );
- DoCall((PSYNCCALLBACKPROC) PARAMS2<RET, Ap, Bp>::DoSyncCall, 0, (LPARAM) ¶ms );
+ PARAMS2<RET, Ap, Bp> params(proc, a, b);
+ DoCall((PSYNCCALLBACKPROC)PARAMS2<RET, Ap, Bp>::DoSyncCall, 0, (LPARAM)¶ms);
return params.GetResult();
};
// 1 param
template<class RET, class A> class PARAMS1
-{
+{
typedef RET(*proc_t)(A);
- proc_t _proc; A _a; RET _ret;
+ proc_t _proc; A _a; RET _ret;
public:
- PARAMS1( proc_t __proc, A __a): _proc( __proc), _a (__a){};
+ PARAMS1(proc_t __proc, A __a) : _proc(__proc), _a(__a){};
static int DoSyncCall(WPARAM, LPARAM lParam)
{
- PARAMS1 * params = (PARAMS1 *) lParam;
- params->_ret = params->_proc( params->_a );
+ PARAMS1 * params = (PARAMS1 *)lParam;
+ params->_ret = params->_proc(params->_a);
return 0;
};
RET GetResult() { return _ret; }
};
-template< class RET, class Ap, class A> RET Sync( RET(*proc)(Ap), A a )
+template< class RET, class Ap, class A> RET Sync(RET(*proc)(Ap), A a)
{
- PARAMS1<RET, Ap> params( proc, a );
- DoCall((PSYNCCALLBACKPROC) PARAMS1<RET, Ap>::DoSyncCall, 0, (LPARAM) ¶ms );
+ PARAMS1<RET, Ap> params(proc, a);
+ DoCall((PSYNCCALLBACKPROC)PARAMS1<RET, Ap>::DoSyncCall, 0, (LPARAM)¶ms);
return params.GetResult();
};
diff --git a/plugins/Clist_modern/src/hdr/modern_tstring.h b/plugins/Clist_modern/src/hdr/modern_tstring.h index 00948179d8..36d7e30ad3 100644 --- a/plugins/Clist_modern/src/hdr/modern_tstring.h +++ b/plugins/Clist_modern/src/hdr/modern_tstring.h @@ -11,20 +11,20 @@ class mbstring : public astring {
// It is prohibited to initialize by char* outside, use L"xxx"
private:
- mbstring( const char * pChar ) : astring( pChar ) {};
- mbstring& operator=( const char * pChar ) { this->operator =( pChar ); return *this; }
+ mbstring(const char * pChar) : astring(pChar) {};
+ mbstring& operator=(const char * pChar) { this->operator =(pChar); return *this; }
public:
- mbstring() : astring() {};
- mbstring( const mbstring& uStr ) : astring( uStr ) {};
+ mbstring() : astring() {};
+ mbstring(const mbstring& uStr) : astring(uStr) {};
-
- mbstring( const wstring& tStr ) { *this = tStr.c_str(); }
- mbstring& operator=( const wstring& tStr ) { this->operator =( tStr.c_str()); return *this; }
- mbstring( const wchar_t * wChar );
- mbstring& operator=( const astring& aStr );
- mbstring& operator=( const wchar_t * wChar );
+ mbstring(const wstring& tStr) { *this = tStr.c_str(); }
+ mbstring& operator=(const wstring& tStr) { this->operator =(tStr.c_str()); return *this; }
+
+ mbstring(const wchar_t * wChar);
+ mbstring& operator=(const astring& aStr);
+ mbstring& operator=(const wchar_t * wChar);
operator wstring();
operator astring();
};
@@ -33,18 +33,18 @@ public: class tstring : public wstring
{
public:
- tstring() : wstring() {};
- tstring(const wchar_t * pwChar) : wstring( pwChar ) {};
-
-
- tstring(const astring& aStr) { *this = aStr.c_str(); }
- tstring(const mbstring& utfStr) { *this = utfStr; }
+ tstring() : wstring() {};
+ tstring(const wchar_t * pwChar) : wstring(pwChar) {};
+
+
+ tstring(const astring& aStr) { *this = aStr.c_str(); }
+ tstring(const mbstring& utfStr) { *this = utfStr; }
tstring(const char * pChar);
- tstring& operator=( const char * pChar );
- tstring& operator=( const astring& aStr );
- tstring& operator=( const mbstring& uStr );
+ tstring& operator=(const char * pChar);
+ tstring& operator=(const astring& aStr);
+ tstring& operator=(const mbstring& uStr);
operator astring();
- operator mbstring() { return mbstring( this->c_str()); }
+ operator mbstring() { return mbstring(this->c_str()); }
};
|