case WM_LBUTTONDOWN:
{
Experement[1]++;
move = true;
SetCapture(hWnd);
xMove = LOWORD(lParam);
yMove = HIWORD(lParam);
break;
}
case WM_MOUSEMOVE: {
if (move)
{
RECT rect;
GetWindowRect(hWnd, &rect);
int width = rect.right - rect.left;
int height = rect.bottom - rect.top;
rect.left += LOWORD(lParam) - xMove;
rect.top += HIWORD(lParam) - yMove;
MoveWindow(hWnd, rect.left, rect.top, width, height, 1);
}
break;
}
case WM_MOUSEMOVE: {
if (move)
{
RECT rect;
GetWindowRect(hWnd, &rect);
int width = rect.right - rect.left;
int height = rect.bottom - rect.top;
rect.left += LOWORD(lParam) - xMove;
rect.top += HIWORD(lParam) - yMove;
MoveWindow(hWnd, rect.left, rect.top, width, height, 1);
xMove = LOWORD(lParam);
yMove = HIWORD(lParam);
}
break;
}
Иначе я бы уже написал))