[cardlib] Re-add changes that got lost due to an old version being used as base

svn path=/trunk/; revision=43375
This commit is contained in:
Gregor Schneider
2009-10-11 14:15:02 +00:00
parent 3002382fb4
commit 5fad423e37
4 changed files with 5 additions and 5 deletions
+1 -1
View File
@@ -326,7 +326,7 @@ int CardButton::OnLButtonUp(HWND hwnd, int x, int y)
else
{
HWND hwnd = (HWND)parentWnd;
SendMessage(GetParent(hwnd), WM_COMMAND, MAKEWPARAM(id, BN_CLICKED), (LONG)hwnd);
SendMessage(GetParent(hwnd), WM_COMMAND, MAKEWPARAM(id, BN_CLICKED), (LONG_PTR)hwnd);
}
}
}
+1 -1
View File
@@ -298,7 +298,7 @@ void CardRegion::Render(HDC hdc)
else
fDrawTips = TRUE;
if(yoffset != 0 && abs(xoffset) == 1 || xoffset != 0 && abs(yoffset) == 1)
if((yoffset != 0 && abs(xoffset) == 1) || (xoffset != 0 && abs(yoffset) == 1))
fDrawTips = TRUE;
//draw horizontal strips
+1 -1
View File
@@ -626,7 +626,7 @@ void CardRegion::ZoomCard(HDC hdc, int xpos, int ypos, CardRegion *pDestStack)
MoveDragCardTo(hdc, ix, iy);
if(attarget || ix == idestx && iy == idesty)
if(attarget || (ix == idestx && iy == idesty))
break;
oldx = (int)x;
+2 -2
View File
@@ -275,7 +275,7 @@ CardRegion* CardWindow::CardRegionFromPoint(int x, int y)
//
LRESULT CALLBACK CardWindow::CardWndProc(HWND hwnd, UINT iMsg, WPARAM wParam, LPARAM lParam)
{
CardWindow *cw = (CardWindow *)GetWindowLong(hwnd, 0);
CardWindow *cw = (CardWindow *)GetWindowLongPtr(hwnd, 0);
return cw->WndProc(hwnd, iMsg, wParam, lParam);
}
@@ -366,7 +366,7 @@ LRESULT CALLBACK CardWindow::WndProc(HWND hwnd, UINT iMsg, WPARAM wParam, LPARAM
//
// associate this class with the window
//
SetWindowLong(hwnd, 0, (LONG)cs->lpCreateParams);
SetWindowLongPtr(hwnd, 0, (LONG_PTR)cs->lpCreateParams);
return 1;