summaryrefslogtreecommitdiff
path: root/plugins/Clist_nicer
diff options
context:
space:
mode:
authorGeorge Hazan <george.hazan@gmail.com>2012-06-08 21:02:06 +0000
committerGeorge Hazan <george.hazan@gmail.com>2012-06-08 21:02:06 +0000
commit2840393bf5378c012577c4764dc4cbd162f85d4e (patch)
tree257a83be6f650415d8b47bb982b0bc700e6c9f8c /plugins/Clist_nicer
parentd0ffabed30e05f6dc56e2e5231637f333bc16003 (diff)
GetWindowLong -> GetWindowLongPtr
git-svn-id: http://svn.miranda-ng.org/main/trunk@364 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c
Diffstat (limited to 'plugins/Clist_nicer')
-rw-r--r--plugins/Clist_nicer/CLUIFrames/cluiframes.cpp44
-rw-r--r--plugins/Clist_nicer/CLUIFrames/groupmenu.cpp8
-rw-r--r--plugins/Clist_nicer/INCLUDE/rowheight_funcs.h2
-rw-r--r--plugins/Clist_nicer/SRC/CLCButton.cpp2
-rw-r--r--plugins/Clist_nicer/SRC/Docking.cpp2
-rw-r--r--plugins/Clist_nicer/SRC/clc.cpp6
-rw-r--r--plugins/Clist_nicer/SRC/clcitems.cpp2
-rw-r--r--plugins/Clist_nicer/SRC/clcopts.cpp4
-rw-r--r--plugins/Clist_nicer/SRC/clcpaint.cpp2
-rw-r--r--plugins/Clist_nicer/SRC/clcutils.cpp6
-rw-r--r--plugins/Clist_nicer/SRC/clui.cpp20
-rw-r--r--plugins/Clist_nicer/SRC/cluiopts.cpp28
-rw-r--r--plugins/Clist_nicer/SRC/extBackg.cpp2
-rw-r--r--plugins/Clist_nicer/SRC/rowheight_funcs.cpp4
-rw-r--r--plugins/Clist_nicer/SRC/statusfloater.cpp4
-rw-r--r--plugins/Clist_nicer/coolsb/coolsblib.cpp18
-rw-r--r--plugins/Clist_nicer/coolsb/coolscroll.cpp16
17 files changed, 85 insertions, 85 deletions
diff --git a/plugins/Clist_nicer/CLUIFrames/cluiframes.cpp b/plugins/Clist_nicer/CLUIFrames/cluiframes.cpp
index 79fa14dc85..f260db6058 100644
--- a/plugins/Clist_nicer/CLUIFrames/cluiframes.cpp
+++ b/plugins/Clist_nicer/CLUIFrames/cluiframes.cpp
@@ -996,7 +996,7 @@ INT_PTR CLUIFramesGetFrameOptions(WPARAM wParam, LPARAM lParam)
if (Frames[pos].TitleBar.ShowTitleBar) retval |= F_SHOWTB;
if (Frames[pos].TitleBar.ShowTitleBarTip) retval |= F_SHOWTBTIP;
if (Frames[pos].Skinned) retval |= F_SKINNED;
- if (!(GetWindowLong(Frames[pos].hWnd, GWL_STYLE)&WS_BORDER)) retval |= F_NOBORDER;
+ if (!(GetWindowLongPtr(Frames[pos].hWnd, GWL_STYLE)&WS_BORDER)) retval |= F_NOBORDER;
break;
case FO_NAME:
@@ -1012,11 +1012,11 @@ INT_PTR CLUIFramesGetFrameOptions(WPARAM wParam, LPARAM lParam)
break;
case FO_TBSTYLE:
- retval = GetWindowLong(Frames[pos].TitleBar.hwnd, GWL_STYLE);
+ retval = GetWindowLongPtr(Frames[pos].TitleBar.hwnd, GWL_STYLE);
break;
case FO_TBEXSTYLE:
- retval = GetWindowLong(Frames[pos].TitleBar.hwnd, GWL_EXSTYLE);
+ retval = GetWindowLongPtr(Frames[pos].TitleBar.hwnd, GWL_EXSTYLE);
break;
case FO_ICON:
@@ -1082,7 +1082,7 @@ INT_PTR CLUIFramesSetFrameOptions(WPARAM wParam, LPARAM lParam)
SendMessage(Frames[pos].TitleBar.hwndTip, TTM_ACTIVATE, (WPARAM)Frames[pos].TitleBar.ShowTitleBarTip, 0);
- style = (int)GetWindowLong(Frames[pos].hWnd, GWL_STYLE);
+ style = (int)GetWindowLongPtr(Frames[pos].hWnd, GWL_STYLE);
style |= WS_BORDER;
style |= CLS_SKINNEDFRAME;
@@ -1096,8 +1096,8 @@ INT_PTR CLUIFramesSetFrameOptions(WPARAM wParam, LPARAM lParam)
if (!(flag & F_SKINNED))
style &= ~CLS_SKINNEDFRAME;
- SetWindowLong(Frames[pos].hWnd, GWL_STYLE, (LONG)style);
- SetWindowLong(Frames[pos].TitleBar.hwnd, GWL_STYLE, (LONG)style & ~(WS_VSCROLL | WS_HSCROLL));
+ SetWindowLongPtr(Frames[pos].hWnd, GWL_STYLE, (LONG)style);
+ SetWindowLongPtr(Frames[pos].TitleBar.hwnd, GWL_STYLE, (LONG)style & ~(WS_VSCROLL | WS_HSCROLL));
ulockfrm();
CLUIFramesOnClistResize((WPARAM)pcli->hwndContactList, (LPARAM)0);
@@ -1139,12 +1139,12 @@ INT_PTR CLUIFramesSetFrameOptions(WPARAM wParam, LPARAM lParam)
return 0;
case FO_TBSTYLE:
- SetWindowLong(Frames[pos].TitleBar.hwnd, GWL_STYLE, lParam);
+ SetWindowLongPtr(Frames[pos].TitleBar.hwnd, GWL_STYLE, lParam);
ulockfrm();
return 0;
case FO_TBEXSTYLE:
- SetWindowLong(Frames[pos].TitleBar.hwnd, GWL_EXSTYLE, lParam);
+ SetWindowLongPtr(Frames[pos].TitleBar.hwnd, GWL_EXSTYLE, lParam);
ulockfrm();
return 0;
@@ -1727,7 +1727,7 @@ int FrameNCPaint(HWND hwnd, WNDPROC oldWndProc, WPARAM wParam, LPARAM lParam, BO
result = 0;
if (pcli && pcli->hwndContactList && GetParent(hwnd) == pcli->hwndContactList) {
- if (GetWindowLong(hwnd, GWL_STYLE) & CLS_SKINNEDFRAME) {
+ if (GetWindowLongPtr(hwnd, GWL_STYLE) & CLS_SKINNEDFRAME) {
StatusItems_t *item = StatusItems ? (hasTitleBar ? &StatusItems[ID_EXTBKOWNEDFRAMEBORDERTB - ID_STATUS_OFFLINE] : &StatusItems[ID_EXTBKOWNEDFRAMEBORDER - ID_STATUS_OFFLINE]) : 0;
HDC realDC;
HBITMAP hbmDraw, hbmOld;
@@ -1762,7 +1762,7 @@ int FrameNCPaint(HWND hwnd, WNDPROC oldWndProc, WPARAM wParam, LPARAM lParam, BO
}
ReleaseDC(hwnd, hdc);
return 0;
- } else if (GetWindowLong(hwnd, GWL_STYLE) & WS_BORDER) {
+ } else if (GetWindowLongPtr(hwnd, GWL_STYLE) & WS_BORDER) {
HPEN hPenOld;
HBRUSH brold;
@@ -1788,7 +1788,7 @@ int FrameNCCalcSize(HWND hwnd, WNDPROC oldWndProc, WPARAM wParam, LPARAM lParam,
StatusItems_t *item = StatusItems ? (hasTitleBar ? &StatusItems[ID_EXTBKOWNEDFRAMEBORDERTB - ID_STATUS_OFFLINE] : &StatusItems[ID_EXTBKOWNEDFRAMEBORDER - ID_STATUS_OFFLINE]) : 0;
LRESULT orig = oldWndProc ? CallWindowProc(oldWndProc, hwnd, WM_NCCALCSIZE, wParam, lParam) : 0;
NCCALCSIZE_PARAMS *nccp = (NCCALCSIZE_PARAMS *)lParam;
- DWORD dwStyle = GetWindowLong(hwnd, GWL_STYLE);
+ DWORD dwStyle = GetWindowLongPtr(hwnd, GWL_STYLE);
if (item == 0 || pcli == 0)
return orig;
@@ -1912,7 +1912,7 @@ INT_PTR CLUIFramesAddFrame(WPARAM wParam, LPARAM lParam)
Frames[nFramescount].OwnerWindow = pcli->hwndContactList;
SetClassLong(clfrm->hWnd, GCL_STYLE, GetClassLong(clfrm->hWnd, GCL_STYLE) & ~(CS_VREDRAW | CS_HREDRAW));
- SetWindowLong(clfrm->hWnd, GWL_STYLE, GetWindowLong(clfrm->hWnd, GWL_STYLE) | WS_CLIPCHILDREN);
+ SetWindowLongPtr(clfrm->hWnd, GWL_STYLE, GetWindowLongPtr(clfrm->hWnd, GWL_STYLE) | WS_CLIPCHILDREN);
if (GetCurrentThreadId() == GetWindowThreadProcessId(clfrm->hWnd, NULL)) {
if (clfrm->hWnd != pcli->hwndContactTree && clfrm->hWnd != g_hwndViewModeFrame && clfrm->hWnd != g_hwndEventArea) {
@@ -1981,8 +1981,8 @@ INT_PTR CLUIFramesAddFrame(WPARAM wParam, LPARAM lParam)
SendMessage(Frames[nFramescount].TitleBar.hwndTip, TTM_ACTIVATE, (WPARAM)Frames[nFramescount].TitleBar.ShowTitleBarTip, 0);
- Frames[nFramescount].oldstyles = GetWindowLong(Frames[nFramescount].hWnd, GWL_STYLE);
- Frames[nFramescount].TitleBar.oldstyles = GetWindowLong(Frames[nFramescount].TitleBar.hwnd, GWL_STYLE);
+ Frames[nFramescount].oldstyles = GetWindowLongPtr(Frames[nFramescount].hWnd, GWL_STYLE);
+ Frames[nFramescount].TitleBar.oldstyles = GetWindowLongPtr(Frames[nFramescount].TitleBar.hwnd, GWL_STYLE);
//Frames[nFramescount].FloatingPos.x=
retval = Frames[nFramescount].id;
@@ -1990,14 +1990,14 @@ INT_PTR CLUIFramesAddFrame(WPARAM wParam, LPARAM lParam)
nFramescount++;
CLUIFramesLoadFrameSettings(id2pos(retval));
- style = GetWindowLong(Frames[nFramescount-1].hWnd, GWL_STYLE);
+ style = GetWindowLongPtr(Frames[nFramescount-1].hWnd, GWL_STYLE);
style &= ~(WS_BORDER);
style |= ((Frames[nFramescount-1].UseBorder) ? WS_BORDER : 0);
style |= Frames[nFramescount-1].Skinned ? CLS_SKINNEDFRAME : 0;
- SetWindowLong(Frames[nFramescount-1].hWnd, GWL_STYLE, style);
- SetWindowLong(Frames[nFramescount-1].TitleBar.hwnd, GWL_STYLE, style & ~(WS_VSCROLL | WS_HSCROLL));
+ SetWindowLongPtr(Frames[nFramescount-1].hWnd, GWL_STYLE, style);
+ SetWindowLongPtr(Frames[nFramescount-1].TitleBar.hwnd, GWL_STYLE, style & ~(WS_VSCROLL | WS_HSCROLL));
if (Frames[nFramescount-1].order == 0) {
Frames[nFramescount-1].order = nFramescount;
@@ -3047,7 +3047,7 @@ LRESULT CALLBACK CLUIFrameTitleBarProc(HWND hwnd, UINT msg, WPARAM wParam, LPARA
}
break;
case WM_NCPAINT: {
- if (GetWindowLong(hwnd, GWL_STYLE) & WS_BORDER) {
+ if (GetWindowLongPtr(hwnd, GWL_STYLE) & WS_BORDER) {
HDC hdc = GetWindowDC(hwnd);
HPEN hPenOld = reinterpret_cast<HPEN>(SelectObject(hdc, g_hPenCLUIFrames));
RECT rcWindow, rc;
@@ -3286,8 +3286,8 @@ INT_PTR CLUIFrameSetFloat(WPARAM wParam, LPARAM lParam)
int neww, newh;
BOOLEAN locked;
- Frames[wParam].oldstyles = GetWindowLong(Frames[wParam].hWnd, GWL_STYLE);
- Frames[wParam].TitleBar.oldstyles = GetWindowLong(Frames[wParam].TitleBar.hwnd, GWL_STYLE);
+ Frames[wParam].oldstyles = GetWindowLongPtr(Frames[wParam].hWnd, GWL_STYLE);
+ Frames[wParam].TitleBar.oldstyles = GetWindowLongPtr(Frames[wParam].TitleBar.hwnd, GWL_STYLE);
locked = Frames[wParam].Locked;
Frames[wParam].Locked = FALSE;
Frames[wParam].minmaxenabled = FALSE;
@@ -3335,9 +3335,9 @@ INT_PTR CLUIFrameSetFloat(WPARAM wParam, LPARAM lParam)
SetWindowPos(Frames[wParam].ContainerWnd, HWND_TOPMOST, Frames[wParam].FloatingPos.x, Frames[wParam].FloatingPos.y, neww, newh, SWP_HIDEWINDOW);
}
SetWindowText(Frames[wParam].ContainerWnd, Frames[wParam].TitleBar.tbname);
- temp = GetWindowLong(Frames[wParam].ContainerWnd, GWL_EXSTYLE);
+ temp = GetWindowLongPtr(Frames[wParam].ContainerWnd, GWL_EXSTYLE);
temp |= WS_EX_TOOLWINDOW | WS_EX_TOPMOST ;
- SetWindowLong(Frames[wParam].ContainerWnd, GWL_EXSTYLE, temp);
+ SetWindowLongPtr(Frames[wParam].ContainerWnd, GWL_EXSTYLE, temp);
Frames[wParam].floating = TRUE;
Frames[wParam].Locked = locked;
diff --git a/plugins/Clist_nicer/CLUIFrames/groupmenu.cpp b/plugins/Clist_nicer/CLUIFrames/groupmenu.cpp
index 6689c277b9..82786d9a45 100644
--- a/plugins/Clist_nicer/CLUIFrames/groupmenu.cpp
+++ b/plugins/Clist_nicer/CLUIFrames/groupmenu.cpp
@@ -226,7 +226,7 @@ INT_PTR FreeOwnerDataGroupMenu (WPARAM wParam,LPARAM lParam)
INT_PTR HideGroupsHelper(WPARAM wParam,LPARAM lParam)
{
- int newVal=!(GetWindowLong((HWND)CallService(MS_CLUI_GETHWNDTREE,0,0),GWL_STYLE)&CLS_HIDEEMPTYGROUPS);
+ int newVal=!(GetWindowLongPtr((HWND)CallService(MS_CLUI_GETHWNDTREE,0,0),GWL_STYLE)&CLS_HIDEEMPTYGROUPS);
cfg::writeByte("CList","HideEmptyGroups",(BYTE)newVal);
SendMessage((HWND)CallService(MS_CLUI_GETHWNDTREE,0,0),CLM_SETHIDEEMPTYGROUPS,newVal,0);
return 0;
@@ -234,7 +234,7 @@ INT_PTR HideGroupsHelper(WPARAM wParam,LPARAM lParam)
INT_PTR UseGroupsHelper(WPARAM wParam,LPARAM lParam)
{
- int newVal=!(GetWindowLong((HWND)CallService(MS_CLUI_GETHWNDTREE,0,0),GWL_STYLE)&CLS_USEGROUPS);
+ int newVal=!(GetWindowLongPtr((HWND)CallService(MS_CLUI_GETHWNDTREE,0,0),GWL_STYLE)&CLS_USEGROUPS);
cfg::writeByte("CList","UseGroups",(BYTE)newVal);
SendMessage((HWND)CallService(MS_CLUI_GETHWNDTREE,0,0),CLM_SETUSEGROUPS,newVal,0);
return 0;
@@ -267,12 +267,12 @@ static int OnBuildGroupMenu(WPARAM wParam,LPARAM lParam)
ZeroMemory(&mi,sizeof(mi));
mi.cbSize = sizeof(mi);
- mi.flags = CMIM_FLAGS | (GetWindowLong(pcli->hwndContactTree,GWL_STYLE)&CLS_HIDEEMPTYGROUPS?CMIF_CHECKED:0);
+ mi.flags = CMIM_FLAGS | (GetWindowLongPtr(pcli->hwndContactTree,GWL_STYLE)&CLS_HIDEEMPTYGROUPS?CMIF_CHECKED:0);
CallService(MS_CLIST_MODIFYMENUITEM, (WPARAM)hHideEmptyGroupsMenuItem, (LPARAM)&mi);
ZeroMemory(&mi,sizeof(mi));
mi.cbSize = sizeof(mi);
- mi.flags = CMIM_FLAGS | (GetWindowLong(pcli->hwndContactTree,GWL_STYLE)&CLS_USEGROUPS?0:CMIF_CHECKED);
+ mi.flags = CMIM_FLAGS | (GetWindowLongPtr(pcli->hwndContactTree,GWL_STYLE)&CLS_USEGROUPS?0:CMIF_CHECKED);
CallService(MS_CLIST_MODIFYMENUITEM, (WPARAM)hDisableGroupsMenuItem, (LPARAM)&mi);
ZeroMemory(&mi,sizeof(mi));
diff --git a/plugins/Clist_nicer/INCLUDE/rowheight_funcs.h b/plugins/Clist_nicer/INCLUDE/rowheight_funcs.h
index d3fb618d19..383db5b592 100644
--- a/plugins/Clist_nicer/INCLUDE/rowheight_funcs.h
+++ b/plugins/Clist_nicer/INCLUDE/rowheight_funcs.h
@@ -20,7 +20,7 @@ public:
static int getRowHeight (ClcData *dat, const HWND hwnd, ClcContact* contact, int item, DWORD style)
{
int height = 0;
- //DWORD style=GetWindowLong(hwnd,GWL_STYLE);
+ //DWORD style=GetWindowLongPtr(hwnd,GWL_STYLE);
//if(contact->iRowHeight == item)
// return(dat->row_heights[item]);
diff --git a/plugins/Clist_nicer/SRC/CLCButton.cpp b/plugins/Clist_nicer/SRC/CLCButton.cpp
index 3eedad8d28..5b3401f068 100644
--- a/plugins/Clist_nicer/SRC/CLCButton.cpp
+++ b/plugins/Clist_nicer/SRC/CLCButton.cpp
@@ -350,7 +350,7 @@ static LRESULT CALLBACK TSButtonWndProc(HWND hwndDlg, UINT msg, WPARAM wParam, L
switch (msg) {
case WM_NCCREATE:
{
- SetWindowLong(hwndDlg, GWL_STYLE, GetWindowLong(hwndDlg, GWL_STYLE) | BS_OWNERDRAW);
+ SetWindowLongPtr(hwndDlg, GWL_STYLE, GetWindowLongPtr(hwndDlg, GWL_STYLE) | BS_OWNERDRAW);
bct = reinterpret_cast<MButtonCtrl *>(malloc(sizeof(MButtonCtrl)));
if (bct == NULL)
return FALSE;
diff --git a/plugins/Clist_nicer/SRC/Docking.cpp b/plugins/Clist_nicer/SRC/Docking.cpp
index b51d5237a1..42feed1bee 100644
--- a/plugins/Clist_nicer/SRC/Docking.cpp
+++ b/plugins/Clist_nicer/SRC/Docking.cpp
@@ -152,7 +152,7 @@ int Docking_ProcessWindowMessage(WPARAM wParam, LPARAM lParam)
Docking_GetMonitorRectFromPoint(ptCursor, &rcMonitor);
if ((ptCursor.x < rcMonitor.left + EDGESENSITIVITY) || (ptCursor.x >= rcMonitor.right - EDGESENSITIVITY)) {
- if (!(GetWindowLong(msg->hwnd, GWL_EXSTYLE) & WS_EX_TOOLWINDOW)) {
+ if (!(GetWindowLongPtr(msg->hwnd, GWL_EXSTYLE) & WS_EX_TOOLWINDOW)) {
SendMessage(msg->hwnd, CLUIINTM_REDRAW, 0, 0);
MessageBox(0, TranslateT("The clist cannot be docked when using the default title bar and border. Use a toolwindow or borderless style instead."),
TranslateT("Clist docking"), MB_OK);
diff --git a/plugins/Clist_nicer/SRC/clc.cpp b/plugins/Clist_nicer/SRC/clc.cpp
index 788eccb7fd..466f6a8e52 100644
--- a/plugins/Clist_nicer/SRC/clc.cpp
+++ b/plugins/Clist_nicer/SRC/clc.cpp
@@ -350,7 +350,7 @@ LBL_Def:
flags = contact->flags;
}
pcli->pfnDeleteItemFromTree(hwnd, (HANDLE) wParam);
- if (GetWindowLong(hwnd, GWL_STYLE) & CLS_SHOWHIDDEN || !CLVM_GetContactHiddenStatus((HANDLE)wParam, NULL, dat)) {
+ if (GetWindowLongPtr(hwnd, GWL_STYLE) & CLS_SHOWHIDDEN || !CLVM_GetContactHiddenStatus((HANDLE)wParam, NULL, dat)) {
NMCLISTCONTROL nm;
pcli->pfnAddContactToTree(hwnd, dat, (HANDLE) wParam, 1, 1);
if (FindItem(hwnd, dat, (HANDLE) wParam, &contact, NULL, NULL)) {
@@ -386,7 +386,7 @@ LBL_Def:
else
status = cfg::getWord((HANDLE) wParam, szProto, "Status", ID_STATUS_OFFLINE);
- shouldShow = (GetWindowLong(hwnd, GWL_STYLE) & CLS_SHOWHIDDEN || !CLVM_GetContactHiddenStatus((HANDLE)wParam, szProto, dat)) && ((cfg::dat.bFilterEffective ? TRUE : !pcli->pfnIsHiddenMode(dat, status)) || CallService(MS_CLIST_GETCONTACTICON, wParam, 0) != lParam);// XXX CLVM changed - this means an offline msg is flashing, so the contact should be shown
+ shouldShow = (GetWindowLongPtr(hwnd, GWL_STYLE) & CLS_SHOWHIDDEN || !CLVM_GetContactHiddenStatus((HANDLE)wParam, szProto, dat)) && ((cfg::dat.bFilterEffective ? TRUE : !pcli->pfnIsHiddenMode(dat, status)) || CallService(MS_CLIST_GETCONTACTICON, wParam, 0) != lParam);// XXX CLVM changed - this means an offline msg is flashing, so the contact should be shown
if (!FindItem(hwnd, dat, (HANDLE) wParam, &contact, &group, NULL)) {
if (shouldShow && CallService(MS_DB_CONTACT_IS, wParam, 0)) {
if (dat->selection >= 0 && pcli->pfnGetRowByIndex(dat, dat->selection, &selcontact, NULL) != -1)
@@ -401,7 +401,7 @@ LBL_Def:
}
} else {
//item in list already
- DWORD style = GetWindowLong(hwnd, GWL_STYLE);
+ DWORD style = GetWindowLongPtr(hwnd, GWL_STYLE);
if (contact->iImage == (WORD) lParam)
break;
if (!shouldShow && !(style & CLS_NOHIDEOFFLINE) && (style & CLS_HIDEOFFLINE || group->hideOffline || cfg::dat.bFilterEffective)) { // CLVM changed
diff --git a/plugins/Clist_nicer/SRC/clcitems.cpp b/plugins/Clist_nicer/SRC/clcitems.cpp
index 0f918be17e..34b3a66405 100644
--- a/plugins/Clist_nicer/SRC/clcitems.cpp
+++ b/plugins/Clist_nicer/SRC/clcitems.cpp
@@ -178,7 +178,7 @@ int AddContactToGroup(struct ClcData *dat, struct ClcGroup *group, HANDLE hConta
void RebuildEntireList(HWND hwnd, struct ClcData *dat)
{
char *szProto;
- DWORD style = GetWindowLong(hwnd, GWL_STYLE);
+ DWORD style = GetWindowLongPtr(hwnd, GWL_STYLE);
HANDLE hContact;
struct ClcGroup *group;
DBVARIANT dbv = {0};
diff --git a/plugins/Clist_nicer/SRC/clcopts.cpp b/plugins/Clist_nicer/SRC/clcopts.cpp
index aeb999bfa5..5dbe0d7ceb 100644
--- a/plugins/Clist_nicer/SRC/clcopts.cpp
+++ b/plugins/Clist_nicer/SRC/clcopts.cpp
@@ -922,7 +922,7 @@ static INT_PTR CALLBACK DlgProcXIcons(HWND hwndDlg, UINT msg, WPARAM wParam, LPA
case WM_INITDIALOG:
{
TranslateDialogDefault(hwndDlg);
- SetWindowLong(GetDlgItem(hwndDlg, IDC_EXTRAORDER), GWL_STYLE, GetWindowLong(GetDlgItem(hwndDlg,IDC_EXTRAORDER),GWL_STYLE)|TVS_NOHSCROLL);
+ SetWindowLongPtr(GetDlgItem(hwndDlg, IDC_EXTRAORDER), GWL_STYLE, GetWindowLongPtr(GetDlgItem(hwndDlg,IDC_EXTRAORDER),GWL_STYLE)|TVS_NOHSCROLL);
{
if(himlCheckBoxes == 0) {
CreateStateImageList();
@@ -1463,7 +1463,7 @@ static INT_PTR CALLBACK DlgProcClcMainOpts(HWND hwndDlg, UINT msg, WPARAM wParam
case WM_INITDIALOG:
TranslateDialogDefault(hwndDlg);
opt_clc_main_changed = 0;
- SetWindowLong(GetDlgItem(hwndDlg, IDC_GREYOUTOPTS), GWL_STYLE, GetWindowLong(GetDlgItem(hwndDlg, IDC_GREYOUTOPTS), GWL_STYLE) | TVS_NOHSCROLL | TVS_CHECKBOXES);
+ SetWindowLongPtr(GetDlgItem(hwndDlg, IDC_GREYOUTOPTS), GWL_STYLE, GetWindowLongPtr(GetDlgItem(hwndDlg, IDC_GREYOUTOPTS), GWL_STYLE) | TVS_NOHSCROLL | TVS_CHECKBOXES);
{
int i;
diff --git a/plugins/Clist_nicer/SRC/clcpaint.cpp b/plugins/Clist_nicer/SRC/clcpaint.cpp
index 0943c3d846..7d3d799992 100644
--- a/plugins/Clist_nicer/SRC/clcpaint.cpp
+++ b/plugins/Clist_nicer/SRC/clcpaint.cpp
@@ -1386,7 +1386,7 @@ void PaintClc(HWND hwnd, struct ClcData *dat, HDC hdc, RECT *rcPaint)
struct ClcGroup *group;
HBITMAP hBmpOsb, hOldBitmap;
HFONT hOldFont;
- DWORD style = GetWindowLong(hwnd, GWL_STYLE);
+ DWORD style = GetWindowLongPtr(hwnd, GWL_STYLE);
int grey = 0,groupCountsFontTopShift;
BOOL bFirstNGdrawn = FALSE;
int line_num = -1;
diff --git a/plugins/Clist_nicer/SRC/clcutils.cpp b/plugins/Clist_nicer/SRC/clcutils.cpp
index b158a4394b..e4aee0fda9 100644
--- a/plugins/Clist_nicer/SRC/clcutils.cpp
+++ b/plugins/Clist_nicer/SRC/clcutils.cpp
@@ -88,7 +88,7 @@ int RTL_HitTest(HWND hwnd, struct ClcData *dat, int testx, int testy, struct Clc
{
RECT clRect;
int right, checkboxWidth, cxSmIcon, i, width;
- DWORD style = GetWindowLong(hwnd, GWL_STYLE);
+ DWORD style = GetWindowLongPtr(hwnd, GWL_STYLE);
SIZE textSize;
HDC hdc;
HFONT hFont;
@@ -198,7 +198,7 @@ int HitTest(HWND hwnd, struct ClcData *dat, int testx, int testy, struct ClcCont
HDC hdc;
RECT clRect;
HFONT hFont;
- DWORD style = GetWindowLong(hwnd, GWL_STYLE);
+ DWORD style = GetWindowLongPtr(hwnd, GWL_STYLE);
BYTE mirror_mode = cfg::dat.bUseDCMirroring;
if (flags)
@@ -420,7 +420,7 @@ void RecalcScrollBar(HWND hwnd, struct ClcData *dat)
si.nPage = clRect.bottom;
si.nPos = dat->yScroll;
- if (GetWindowLong(hwnd, GWL_STYLE) & CLS_CONTACTLIST) {
+ if (GetWindowLongPtr(hwnd, GWL_STYLE) & CLS_CONTACTLIST) {
if (dat->noVScrollbar == 0) {
if(cfg::dat.bSkinnedScrollbar && !dat->bisEmbedded)
CoolSB_SetScrollInfo(hwnd, SB_VERT, &si, TRUE);
diff --git a/plugins/Clist_nicer/SRC/clui.cpp b/plugins/Clist_nicer/SRC/clui.cpp
index 94e9829838..93fdd989d4 100644
--- a/plugins/Clist_nicer/SRC/clui.cpp
+++ b/plugins/Clist_nicer/SRC/clui.cpp
@@ -163,7 +163,7 @@ static struct IconDesc myIcons[] = {
static void Tweak_It(COLORREF clr)
{
- SetWindowLong(pcli->hwndContactList, GWL_EXSTYLE, GetWindowLong(pcli->hwndContactList, GWL_EXSTYLE) | WS_EX_LAYERED);
+ SetWindowLongPtr(pcli->hwndContactList, GWL_EXSTYLE, GetWindowLongPtr(pcli->hwndContactList, GWL_EXSTYLE) | WS_EX_LAYERED);
API::pfnSetLayeredWindowAttributes(pcli->hwndContactList, clr, 0, LWA_COLORKEY);
cfg::dat.colorkey = clr;
}
@@ -924,7 +924,7 @@ static void sttProcessResize(HWND hwnd, NMCLISTCONTROL *nmc)
GetWindowRect(hwnd, &rcWindow);
GetWindowRect(pcli->hwndContactTree, &rcTree);
- winstyle = GetWindowLong(pcli->hwndContactTree, GWL_STYLE);
+ winstyle = GetWindowLongPtr(pcli->hwndContactTree, GWL_STYLE);
SystemParametersInfo(SPI_GETWORKAREA, 0, &rcWorkArea, FALSE);
if (API::pfnMonitorFromWindow)
@@ -1119,8 +1119,8 @@ LRESULT CALLBACK ContactListWndProc(HWND hwnd, UINT msg, WPARAM wParam, LPARAM l
g_oldSize.cx = g_oldSize.cy = 0;
old_cliststate = cfg::getByte("CList", "State", SETTING_STATE_NORMAL);
cfg::writeByte("CList", "State", SETTING_STATE_HIDDEN);
- SetWindowLong(hwnd, GWL_STYLE, GetWindowLong(hwnd, GWL_STYLE) & ~WS_VISIBLE);
- SetWindowLong(hwnd, GWL_STYLE, GetWindowLong(hwnd, GWL_STYLE) | WS_CLIPCHILDREN);
+ SetWindowLongPtr(hwnd, GWL_STYLE, GetWindowLongPtr(hwnd, GWL_STYLE) & ~WS_VISIBLE);
+ SetWindowLongPtr(hwnd, GWL_STYLE, GetWindowLongPtr(hwnd, GWL_STYLE) | WS_CLIPCHILDREN);
if (!cfg::dat.bFirstRun)
ConfigureEventArea(hwnd);
CluiProtocolStatusChanged(0, 0);
@@ -1131,12 +1131,12 @@ LRESULT CALLBACK ContactListWndProc(HWND hwnd, UINT msg, WPARAM wParam, LPARAM l
//delay creation of CLC so that it can get the status icons right the first time (needs protocol modules loaded)
if (cfg::dat.bLayeredHack) {
- SetWindowLong(hwnd, GWL_EXSTYLE, GetWindowLong(hwnd, GWL_EXSTYLE) | (WS_EX_LAYERED));
+ SetWindowLongPtr(hwnd, GWL_EXSTYLE, GetWindowLongPtr(hwnd, GWL_EXSTYLE) | (WS_EX_LAYERED));
API::SetLayeredWindowAttributes(hwnd, RGB(0, 0, 0), 255, LWA_ALPHA);
}
if (cfg::dat.isTransparent) {
- SetWindowLong(hwnd, GWL_EXSTYLE, GetWindowLong(hwnd, GWL_EXSTYLE) | WS_EX_LAYERED);
+ SetWindowLongPtr(hwnd, GWL_EXSTYLE, GetWindowLongPtr(hwnd, GWL_EXSTYLE) | WS_EX_LAYERED);
API::SetLayeredWindowAttributes(hwnd, cfg::dat.bFullTransparent ? cfg::dat.colorkey : RGB(0, 0, 0), cfg::dat.alpha, LWA_ALPHA | (cfg::dat.bFullTransparent ? LWA_COLORKEY : 0));
}
transparentFocus = 1;
@@ -1161,7 +1161,7 @@ LRESULT CALLBACK ContactListWndProc(HWND hwnd, UINT msg, WPARAM wParam, LPARAM l
LONG style;
BYTE windowStyle = cfg::getByte("CLUI", "WindowStyle", SETTING_WINDOWSTYLE_TOOLWINDOW);
ShowWindow(pcli->hwndContactList, SW_HIDE);
- style = GetWindowLong(pcli->hwndContactList, GWL_EXSTYLE);
+ style = GetWindowLongPtr(pcli->hwndContactList, GWL_EXSTYLE);
if (windowStyle != SETTING_WINDOWSTYLE_DEFAULT)
{
style |= WS_EX_TOOLWINDOW | WS_EX_WINDOWEDGE;
@@ -1176,7 +1176,7 @@ LRESULT CALLBACK ContactListWndProc(HWND hwnd, UINT msg, WPARAM wParam, LPARAM l
style |= WS_EX_APPWINDOW;
}
- SetWindowLong(pcli->hwndContactList, GWL_EXSTYLE, style);
+ SetWindowLongPtr(pcli->hwndContactList, GWL_EXSTYLE, style);
ApplyCLUIBorderStyle(pcli->hwndContactList);
SetWindowPos(pcli->hwndContactList, 0, 0, 0, 0, 0, SWP_NOZORDER | SWP_NOMOVE | SWP_NOSIZE | SWP_FRAMECHANGED | SWP_NOACTIVATE);
@@ -1887,14 +1887,14 @@ buttons_done:
SendMessage(pcli->hwndContactTree, CLM_SETHIDEOFFLINEROOT, !SendMessage(pcli->hwndContactTree, CLM_GETHIDEOFFLINEROOT, 0, 0), 0);
break;
case POPUP_HIDEEMPTYGROUPS: {
- int newVal = !(GetWindowLong(pcli->hwndContactTree, GWL_STYLE) & CLS_HIDEEMPTYGROUPS);
+ int newVal = !(GetWindowLongPtr(pcli->hwndContactTree, GWL_STYLE) & CLS_HIDEEMPTYGROUPS);
cfg::writeByte("CList", "HideEmptyGroups", (BYTE) newVal);
SendMessage(pcli->hwndContactTree, CLM_SETHIDEEMPTYGROUPS, newVal, 0);
break;
}
case POPUP_DISABLEGROUPS:
case IDC_TBHIDEGROUPS: {
- int newVal = !(GetWindowLong(pcli->hwndContactTree, GWL_STYLE) & CLS_USEGROUPS);
+ int newVal = !(GetWindowLongPtr(pcli->hwndContactTree, GWL_STYLE) & CLS_USEGROUPS);
cfg::writeByte("CList", "UseGroups", (BYTE) newVal);
SendMessage(pcli->hwndContactTree, CLM_SETUSEGROUPS, newVal, 0);
CheckDlgButton(hwnd, IDC_TBHIDEGROUPS, newVal ? BST_CHECKED : BST_UNCHECKED);
diff --git a/plugins/Clist_nicer/SRC/cluiopts.cpp b/plugins/Clist_nicer/SRC/cluiopts.cpp
index 79ad2efcb3..843925d5dd 100644
--- a/plugins/Clist_nicer/SRC/cluiopts.cpp
+++ b/plugins/Clist_nicer/SRC/cluiopts.cpp
@@ -212,10 +212,10 @@ INT_PTR CALLBACK DlgProcCluiOpts(HWND hwndDlg, UINT msg, WPARAM wParam, LPARAM l
GetWindowPlacement(pcli->hwndContactList, &p);
ShowWindow(pcli->hwndContactList, SW_HIDE);
- style = GetWindowLong(pcli->hwndContactList, GWL_EXSTYLE);
+ style = GetWindowLongPtr(pcli->hwndContactList, GWL_EXSTYLE);
style |= WS_EX_TOOLWINDOW | WS_EX_WINDOWEDGE;
style &= ~WS_EX_APPWINDOW;
- SetWindowLong(pcli->hwndContactList, GWL_EXSTYLE, style);
+ SetWindowLongPtr(pcli->hwndContactList, GWL_EXSTYLE, style);
SetWindowPlacement(pcli->hwndContactList, &p);
ShowWindow(pcli->hwndContactList, SW_SHOW);
@@ -223,7 +223,7 @@ INT_PTR CALLBACK DlgProcCluiOpts(HWND hwndDlg, UINT msg, WPARAM wParam, LPARAM l
else
{
LONG style;
- style = GetWindowLong(pcli->hwndContactList, GWL_EXSTYLE);
+ style = GetWindowLongPtr(pcli->hwndContactList, GWL_EXSTYLE);
style &= ~(WS_EX_TOOLWINDOW | WS_EX_WINDOWEDGE);
if (cfg::getByte("CList", "AlwaysHideOnTB", 1))
style &= ~WS_EX_APPWINDOW;
@@ -232,7 +232,7 @@ INT_PTR CALLBACK DlgProcCluiOpts(HWND hwndDlg, UINT msg, WPARAM wParam, LPARAM l
style |= WS_EX_APPWINDOW;
AddToTaskBar(pcli->hwndContactList);
}
- SetWindowLong(pcli->hwndContactList, GWL_EXSTYLE, style);
+ SetWindowLongPtr(pcli->hwndContactList, GWL_EXSTYLE, style);
}
cfg::dat.bClipBorder = (BYTE)GetDlgItemInt(hwndDlg, IDC_CLIPBORDER, &translated, FALSE);
@@ -288,7 +288,7 @@ INT_PTR CALLBACK DlgProcCluiOpts(HWND hwndDlg, UINT msg, WPARAM wParam, LPARAM l
cfg::writeByte("CLUI", "fulltransparent", (BYTE)cfg::dat.bFullTransparent);
if (cfg::dat.bLayeredHack)
- SetWindowLong(pcli->hwndContactList, GWL_EXSTYLE, GetWindowLong(pcli->hwndContactList, GWL_EXSTYLE) | WS_EX_LAYERED);
+ SetWindowLongPtr(pcli->hwndContactList, GWL_EXSTYLE, GetWindowLongPtr(pcli->hwndContactList, GWL_EXSTYLE) | WS_EX_LAYERED);
if(g_CLUISkinnedBkColorRGB)
cfg::dat.colorkey = g_CLUISkinnedBkColorRGB;
@@ -300,8 +300,8 @@ INT_PTR CALLBACK DlgProcCluiOpts(HWND hwndDlg, UINT msg, WPARAM wParam, LPARAM l
}
if (cfg::dat.isTransparent || cfg::dat.bFullTransparent) {
if(API::sysConfig.isWin2KPlus) {
- SetWindowLong(pcli->hwndContactList, GWL_EXSTYLE, GetWindowLong(pcli->hwndContactList, GWL_EXSTYLE) & ~WS_EX_LAYERED);
- SetWindowLong(pcli->hwndContactList, GWL_EXSTYLE, GetWindowLong(pcli->hwndContactList, GWL_EXSTYLE) | WS_EX_LAYERED);
+ SetWindowLongPtr(pcli->hwndContactList, GWL_EXSTYLE, GetWindowLongPtr(pcli->hwndContactList, GWL_EXSTYLE) & ~WS_EX_LAYERED);
+ SetWindowLongPtr(pcli->hwndContactList, GWL_EXSTYLE, GetWindowLongPtr(pcli->hwndContactList, GWL_EXSTYLE) | WS_EX_LAYERED);
API::SetLayeredWindowAttributes(pcli->hwndContactList, 0, 255, LWA_ALPHA | LWA_COLORKEY);
API::SetLayeredWindowAttributes(pcli->hwndContactList,
(COLORREF)(cfg::dat.bFullTransparent ? cfg::dat.colorkey : 0),
@@ -311,7 +311,7 @@ INT_PTR CALLBACK DlgProcCluiOpts(HWND hwndDlg, UINT msg, WPARAM wParam, LPARAM l
} else {
API::SetLayeredWindowAttributes(pcli->hwndContactList, RGB(0, 0, 0), (BYTE)255, LWA_ALPHA);
if (!cfg::dat.bLayeredHack)
- SetWindowLong(pcli->hwndContactList, GWL_EXSTYLE, GetWindowLong(pcli->hwndContactList, GWL_EXSTYLE) & ~WS_EX_LAYERED);
+ SetWindowLongPtr(pcli->hwndContactList, GWL_EXSTYLE, GetWindowLongPtr(pcli->hwndContactList, GWL_EXSTYLE) & ~WS_EX_LAYERED);
}
ConfigureCLUIGeometry(1);
@@ -456,18 +456,18 @@ void ApplyCLUIBorderStyle(HWND hwnd)
ShowWindow(pcli->hwndContactList, SW_HIDE);
if (windowStyle == SETTING_WINDOWSTYLE_DEFAULT || windowStyle == SETTING_WINDOWSTYLE_TOOLWINDOW) {
- SetWindowLong(pcli->hwndContactList, GWL_STYLE, GetWindowLong(pcli->hwndContactList, GWL_STYLE) | WS_CAPTION | WS_SYSMENU | WS_MINIMIZEBOX | WS_POPUPWINDOW | WS_THICKFRAME);
+ SetWindowLongPtr(pcli->hwndContactList, GWL_STYLE, GetWindowLongPtr(pcli->hwndContactList, GWL_STYLE) | WS_CAPTION | WS_SYSMENU | WS_MINIMIZEBOX | WS_POPUPWINDOW | WS_THICKFRAME);
if(SETTING_WINDOWSTYLE_DEFAULT == windowStyle) {
- SetWindowLong(pcli->hwndContactList, GWL_STYLE, GetWindowLong(pcli->hwndContactList, GWL_STYLE) & ~(WS_MAXIMIZEBOX/* | WS_MINIMIZEBOX*/));
+ SetWindowLongPtr(pcli->hwndContactList, GWL_STYLE, GetWindowLongPtr(pcli->hwndContactList, GWL_STYLE) & ~(WS_MAXIMIZEBOX/* | WS_MINIMIZEBOX*/));
minToTray = FALSE;
}
} else if(windowStyle == SETTING_WINDOWSTYLE_THINBORDER) {
- SetWindowLong(pcli->hwndContactList, GWL_STYLE, GetWindowLong(pcli->hwndContactList, GWL_STYLE) & ~(WS_CAPTION | WS_SYSMENU | WS_MINIMIZEBOX | WS_POPUPWINDOW | WS_THICKFRAME));
- SetWindowLong(pcli->hwndContactList, GWL_STYLE, GetWindowLong(pcli->hwndContactList, GWL_STYLE) | WS_BORDER | WS_CLIPCHILDREN);
+ SetWindowLongPtr(pcli->hwndContactList, GWL_STYLE, GetWindowLongPtr(pcli->hwndContactList, GWL_STYLE) & ~(WS_CAPTION | WS_SYSMENU | WS_MINIMIZEBOX | WS_POPUPWINDOW | WS_THICKFRAME));
+ SetWindowLongPtr(pcli->hwndContactList, GWL_STYLE, GetWindowLongPtr(pcli->hwndContactList, GWL_STYLE) | WS_BORDER | WS_CLIPCHILDREN);
}
else {
- SetWindowLong(pcli->hwndContactList, GWL_STYLE, GetWindowLong(pcli->hwndContactList, GWL_STYLE) & ~(WS_CAPTION | WS_SYSMENU | WS_MINIMIZEBOX | WS_POPUPWINDOW | WS_THICKFRAME));
- SetWindowLong(pcli->hwndContactList, GWL_STYLE, GetWindowLong(pcli->hwndContactList, GWL_STYLE) | WS_CLIPCHILDREN);
+ SetWindowLongPtr(pcli->hwndContactList, GWL_STYLE, GetWindowLongPtr(pcli->hwndContactList, GWL_STYLE) & ~(WS_CAPTION | WS_SYSMENU | WS_MINIMIZEBOX | WS_POPUPWINDOW | WS_THICKFRAME));
+ SetWindowLongPtr(pcli->hwndContactList, GWL_STYLE, GetWindowLongPtr(pcli->hwndContactList, GWL_STYLE) | WS_CLIPCHILDREN);
}
p.showCmd = SW_HIDE;
SetWindowPlacement(pcli->hwndContactList, &p);
diff --git a/plugins/Clist_nicer/SRC/extBackg.cpp b/plugins/Clist_nicer/SRC/extBackg.cpp
index 4851622bbe..f5af31a2fb 100644
--- a/plugins/Clist_nicer/SRC/extBackg.cpp
+++ b/plugins/Clist_nicer/SRC/extBackg.cpp
@@ -1322,7 +1322,7 @@ void IMG_LoadItems()
cfg::writeByte("CLUI", "fulltransparent", (BYTE)cfg::dat.bFullTransparent);
cfg::writeByte("CLUI", "WindowStyle", SETTING_WINDOWSTYLE_NOBORDER);
ApplyCLUIBorderStyle(pcli->hwndContactList);
- SetWindowLong(pcli->hwndContactList, GWL_EXSTYLE, GetWindowLong(pcli->hwndContactList, GWL_EXSTYLE) | WS_EX_LAYERED);
+ SetWindowLongPtr(pcli->hwndContactList, GWL_EXSTYLE, GetWindowLongPtr(pcli->hwndContactList, GWL_EXSTYLE) | WS_EX_LAYERED);
API::SetLayeredWindowAttributes(pcli->hwndContactList, cfg::dat.colorkey, 0, LWA_COLORKEY);
}
CoolSB_SetupScrollBar();
diff --git a/plugins/Clist_nicer/SRC/rowheight_funcs.cpp b/plugins/Clist_nicer/SRC/rowheight_funcs.cpp
index 3fe3c311a2..8328d3f7bb 100644
--- a/plugins/Clist_nicer/SRC/rowheight_funcs.cpp
+++ b/plugins/Clist_nicer/SRC/rowheight_funcs.cpp
@@ -99,7 +99,7 @@ BOOL RowHeight::Alloc(ClcData *dat, int size)
int RowHeight::getMaxRowHeight(ClcData *dat, const HWND hwnd)
{
int max_height = 0, i;
- DWORD style=GetWindowLong(hwnd,GWL_STYLE);
+ DWORD style=GetWindowLongPtr(hwnd,GWL_STYLE);
int contact_fonts[] = {FONTID_CONTACTS, FONTID_INVIS, FONTID_OFFLINE, FONTID_NOTONLIST, FONTID_OFFINVIS};
int other_fonts[] = {FONTID_GROUPS, FONTID_GROUPCOUNTS, FONTID_DIVIDERS};
@@ -144,7 +144,7 @@ void RowHeight::calcRowHeights(ClcData *dat, HWND hwnd)
int indent, subindex, line_num;
struct ClcContact *Drawing;
struct ClcGroup *group;
- DWORD dwStyle = GetWindowLong(hwnd, GWL_STYLE);
+ DWORD dwStyle = GetWindowLongPtr(hwnd, GWL_STYLE);
// Draw lines
group=&dat->list;
diff --git a/plugins/Clist_nicer/SRC/statusfloater.cpp b/plugins/Clist_nicer/SRC/statusfloater.cpp
index 06c088da45..860241afa6 100644
--- a/plugins/Clist_nicer/SRC/statusfloater.cpp
+++ b/plugins/Clist_nicer/SRC/statusfloater.cpp
@@ -927,7 +927,7 @@ void SFL_Create()
else
return;
- SetWindowLong(g_hwndSFL, GWL_STYLE, GetWindowLong(g_hwndSFL, GWL_STYLE) & ~(WS_CAPTION | WS_SYSMENU | WS_THICKFRAME | WS_OVERLAPPEDWINDOW | WS_POPUPWINDOW));
+ SetWindowLongPtr(g_hwndSFL, GWL_STYLE, GetWindowLongPtr(g_hwndSFL, GWL_STYLE) & ~(WS_CAPTION | WS_SYSMENU | WS_THICKFRAME | WS_OVERLAPPEDWINDOW | WS_POPUPWINDOW));
Utils_RestoreWindowPosition(g_hwndSFL, 0, "CLUI", "sfl");
SFL_SetSize();
@@ -989,7 +989,7 @@ void FLT_Create(int iEntry)
return;
}
- SetWindowLong(centry->floater->hwnd, GWL_STYLE, GetWindowLong(centry->floater->hwnd, GWL_STYLE) & ~(WS_CAPTION | WS_SYSMENU | WS_THICKFRAME | WS_OVERLAPPEDWINDOW | WS_POPUPWINDOW));
+ SetWindowLongPtr(centry->floater->hwnd, GWL_STYLE, GetWindowLongPtr(centry->floater->hwnd, GWL_STYLE) & ~(WS_CAPTION | WS_SYSMENU | WS_THICKFRAME | WS_OVERLAPPEDWINDOW | WS_POPUPWINDOW));
if(Utils_RestoreWindowPosition(centry->floater->hwnd, centry->hContact, "CList", "flt"))
if(Utils_RestoreWindowPositionNoMove(centry->floater->hwnd, centry->hContact, "CList", "flt"))
diff --git a/plugins/Clist_nicer/coolsb/coolsblib.cpp b/plugins/Clist_nicer/coolsb/coolsblib.cpp
index b8c986b120..3a90d0d070 100644
--- a/plugins/Clist_nicer/coolsb/coolsblib.cpp
+++ b/plugins/Clist_nicer/coolsb/coolsblib.cpp
@@ -202,12 +202,12 @@ BOOL WINAPI InitializeCoolSB(HWND hwnd)
GetScrollInfo(hwnd, SB_VERT, si);
//check to see if the window has left-aligned scrollbars
- if(GetWindowLong(hwnd, GWL_EXSTYLE) & WS_EX_LEFTSCROLLBAR)
+ if(GetWindowLongPtr(hwnd, GWL_EXSTYLE) & WS_EX_LEFTSCROLLBAR)
sw->fLeftScrollbar = TRUE;
else
sw->fLeftScrollbar = FALSE;
- dwCurStyle = GetWindowLong(hwnd, GWL_STYLE);
+ dwCurStyle = GetWindowLongPtr(hwnd, GWL_STYLE);
SetProp(hwnd, szPropStr, (HANDLE)sw);
@@ -518,7 +518,7 @@ BOOL WINAPI CoolSB_ShowScrollBar (HWND hwnd, int wBar, BOOL fShow)
{
SCROLLBAR *sbar;
BOOL bFailed = FALSE;
- DWORD dwStyle = GetWindowLong(hwnd, GWL_STYLE);
+ DWORD dwStyle = GetWindowLongPtr(hwnd, GWL_STYLE);
if (!CoolSB_IsCoolScrollEnabled(hwnd))
return ShowScrollBar(hwnd, wBar, fShow);
@@ -530,8 +530,8 @@ BOOL WINAPI CoolSB_ShowScrollBar (HWND hwnd, int wBar, BOOL fShow)
sbar->fScrollFlags |= (fShow == TRUE ? CSBS_VISIBLE : 0);
//bFailed = TRUE;
- if(fShow) SetWindowLong(hwnd, GWL_STYLE, dwStyle | WS_HSCROLL);
- else SetWindowLong(hwnd, GWL_STYLE, dwStyle & ~WS_HSCROLL);
+ if(fShow) SetWindowLongPtr(hwnd, GWL_STYLE, dwStyle | WS_HSCROLL);
+ else SetWindowLongPtr(hwnd, GWL_STYLE, dwStyle & ~WS_HSCROLL);
}
if ((wBar == SB_VERT || wBar == SB_BOTH) &&
@@ -541,8 +541,8 @@ BOOL WINAPI CoolSB_ShowScrollBar (HWND hwnd, int wBar, BOOL fShow)
sbar->fScrollFlags |= (fShow == TRUE ? CSBS_VISIBLE : 0);
//bFailed = TRUE;
- if(fShow) SetWindowLong(hwnd, GWL_STYLE, dwStyle | WS_VSCROLL);
- else SetWindowLong(hwnd, GWL_STYLE, dwStyle & ~WS_VSCROLL);
+ if(fShow) SetWindowLongPtr(hwnd, GWL_STYLE, dwStyle | WS_VSCROLL);
+ else SetWindowLongPtr(hwnd, GWL_STYLE, dwStyle & ~WS_VSCROLL);
}
if(bFailed)
@@ -551,11 +551,11 @@ BOOL WINAPI CoolSB_ShowScrollBar (HWND hwnd, int wBar, BOOL fShow)
}
else
{
- //DWORD style = GetWindowLong(hwnd, GWL_STYLE);
+ //DWORD style = GetWindowLongPtr(hwnd, GWL_STYLE);
//style |= WS_VSCROLL;
//if(s
- //SetWindowLong(hwnd, GWL_STYLE, style);
+ //SetWindowLongPtr(hwnd, GWL_STYLE, style);
SetWindowPos(hwnd, 0, 0, 0, 0, 0,
SWP_NOMOVE | SWP_NOSIZE | SWP_NOZORDER |
diff --git a/plugins/Clist_nicer/coolsb/coolscroll.cpp b/plugins/Clist_nicer/coolsb/coolscroll.cpp
index ae31ec3e47..7f4dbf95b5 100644
--- a/plugins/Clist_nicer/coolsb/coolscroll.cpp
+++ b/plugins/Clist_nicer/coolsb/coolscroll.cpp
@@ -1539,7 +1539,7 @@ static LRESULT NCPaint(SCROLLWND *sw, HWND hwnd, WPARAM wParam, LPARAM lParam)
//Call the default window procedure for WM_NCPAINT, with the
//new window region. ** region must be in SCREEN coordinates **
- dwStyle = GetWindowLong(hwnd, GWL_STYLE);
+ dwStyle = GetWindowLongPtr(hwnd, GWL_STYLE);
// If the window has WS_(H-V)SCROLL bits set, we should reset them
// to avoid windows taking the scrollbars into account.
@@ -1549,14 +1549,14 @@ static LRESULT NCPaint(SCROLLWND *sw, HWND hwnd, WPARAM wParam, LPARAM lParam)
if ( dwStyle & (WS_VSCROLL|WS_HSCROLL) )
{
sw->bPreventStyleChange = TRUE;
- SetWindowLong(hwnd, GWL_STYLE, dwStyle & ~(WS_VSCROLL|WS_HSCROLL));
+ SetWindowLongPtr(hwnd, GWL_STYLE, dwStyle & ~(WS_VSCROLL|WS_HSCROLL));
}
ret = CallWindowProc(sw->oldproc, hwnd, WM_NCPAINT, (WPARAM)hrgn, lParam);
if ( dwStyle & (WS_VSCROLL|WS_HSCROLL) )
{
- SetWindowLong(hwnd, GWL_STYLE, dwStyle);
+ SetWindowLongPtr(hwnd, GWL_STYLE, dwStyle);
sw->bPreventStyleChange = FALSE;
}
@@ -2683,13 +2683,13 @@ static LRESULT NCCalcSize(SCROLLWND *sw, HWND hwnd, WPARAM wParam, LPARAM lParam
rect = &nccsp->rgrc[0];
oldrect = *rect;
- dwStyle = GetWindowLong(hwnd, GWL_STYLE);
+ dwStyle = GetWindowLongPtr(hwnd, GWL_STYLE);
// TURN OFF SCROLL-STYLES.
if ( dwStyle & (WS_VSCROLL|WS_HSCROLL) )
{
sw->bPreventStyleChange = TRUE;
- SetWindowLong(hwnd, GWL_STYLE, dwStyle & ~(WS_VSCROLL|WS_HSCROLL));
+ SetWindowLongPtr(hwnd, GWL_STYLE, dwStyle & ~(WS_VSCROLL|WS_HSCROLL));
}
//call the default procedure to get the borders allocated
@@ -2698,7 +2698,7 @@ static LRESULT NCCalcSize(SCROLLWND *sw, HWND hwnd, WPARAM wParam, LPARAM lParam
// RESTORE PREVIOUS STYLES (if present at all)
if ( dwStyle & (WS_VSCROLL|WS_HSCROLL) )
{
- SetWindowLong(hwnd, GWL_STYLE, dwStyle);
+ SetWindowLongPtr(hwnd, GWL_STYLE, dwStyle);
sw->bPreventStyleChange = FALSE;
}
@@ -2900,7 +2900,7 @@ static LRESULT CoolSB_Timer(SCROLLWND *swnd, HWND hwnd, WPARAM wTimerId, LPARAM
}
//
-// We must intercept any calls to SetWindowLong, to check if
+// We must intercept any calls to SetWindowLongPtr, to check if
// left-scrollbars are taking effect or not
//
static LRESULT CoolSB_StyleChange(SCROLLWND *swnd, HWND hwnd, UINT msg, WPARAM wParam, LPARAM lParam)
@@ -2956,7 +2956,7 @@ static LRESULT SendToolTipMessage0(HWND hwndTT, UINT message, WPARAM wParam, LPA
//
-// We must intercept any calls to SetWindowLong, to make sure that
+// We must intercept any calls to SetWindowLongPtr, to make sure that
// the user does not set the WS_VSCROLL or WS_HSCROLL styles
//
static LRESULT CoolSB_SetCursor(SCROLLWND *swnd, HWND hwnd, WPARAM wParam, LPARAM lParam)