90#define INITIAL_DELAY 500
91#define REPEAT_DELAY 50
104 *prcTopLeft = *prcBottomRight = rcWindow;
184 return infoPtr->
nPos;
205 return infoPtr->
clrBk;
235 int nPos = infoPtr->
nPos;
246 if (infoPtr->
nWidth < wndSize)
247 infoPtr->
nWidth = wndSize;
259 if (infoPtr->
nHeight < wndSize)
281 INT wndSize, childSize;
290 childSize = infoPtr->
nWidth;
298 TRACE(
"childSize = %d, wndSize = %d\n", childSize, wndSize);
299 if (childSize > wndSize)
300 scrollRange = childSize - wndSize + infoPtr->
nButtonSize;
315 RECT rcTopLeft, rcBottomRight;
324 if (infoPtr->
nPos > 0)
329 else if (!hideGrayBtns &&
PtInRect(&rcTopLeft,
pt))
334 if (scrollRange <= 0)
339 else if (infoPtr->
nPos < scrollRange)
344 else if (!hideGrayBtns &&
PtInRect(&rcBottomRight,
pt))
360 repaintBtns = (oldTLbtnState != infoPtr->
TLbtnState) ||
372 if ((scrollRange <= 0) || (newPos < 0))
374 else if (newPos > scrollRange)
375 infoPtr->
nPos = scrollRange;
377 infoPtr->
nPos = newPos;
381 if (infoPtr->
nPos != oldPos)
412 if (scrollRange <= 0)
430 infoPtr->
clrBk = clrBk;
523 TRACE(
"[%p] PGN_SCROLL returns iScroll=%d\n", infoPtr->
hwndSelf, nmpgScroll.iScroll);
525 if (nmpgScroll.iScroll > 0)
560 infoPtr = heap_alloc_zero (
sizeof(*infoPtr));
561 if (!infoPtr)
return -1;
582 FIXME(
"[%p] Drag and Drop style is not implemented yet.\n", infoPtr->
hwndSelf);
599 RECT rcChild, rcWindow;
645 RECT rcBottomRight, rcTopLeft;
670 RECT clientRect, rcTopLeft, rcBottomRight;
686 TRACE(
"PGB_TOPORLEFT\n");
691 TRACE(
"PGB_BOTTOMORRIGHT\n");
756 TRACE(
"[%p] draw btn (%s), Capture %s, style %08x\n",
758 (infoPtr->
bCapture) ?
"TRUE" :
"FALSE",
923 TRACE(
"[%p] TIMERID1: style=%08x, dir=%d\n",
986 TRACE(
"(styletype=%lx, styleOld=0x%08x, styleNew=0x%08x)\n",
1066 case WM_STYLECHANGED:
static BOOL heap_free(void *mem)
#define WINE_DEFAULT_DEBUG_CHANNEL(t)
GLint GLint GLint GLint GLint x
GLuint GLuint GLsizei GLenum type
GLint GLint GLint GLint GLint GLint y
#define NM_RELEASEDCAPTURE
#define PGM_GETBUTTONSTATE
#define PGM_SETBUTTONSIZE
#define PGB_BOTTOMORRIGHT
#define PGM_GETBUTTONSIZE
static __inline const char * wine_dbgstr_rect(const RECT *rect)
BOOL WINAPI SetWindowOrgEx(_In_ HDC, _In_ int, _In_ int, _Out_opt_ LPPOINT)
BOOL WINAPI OffsetWindowOrgEx(_In_ HDC, _In_ int, _In_ int, _Out_opt_ LPPOINT)
HWND WINAPI SetCapture(_In_ HWND hWnd)
int WINAPI ReleaseDC(_In_opt_ HWND, _In_ HDC)
DWORD WINAPI GetSysColor(_In_ int)
BOOL WINAPI IsWindow(_In_opt_ HWND)
BOOL WINAPI RedrawWindow(_In_opt_ HWND, _In_opt_ LPCRECT, _In_opt_ HRGN, _In_ UINT)
#define GetWindowLongPtrW
HDC WINAPI GetWindowDC(_In_opt_ HWND)
BOOL WINAPI ReleaseCapture(void)
LRESULT WINAPI DefWindowProcW(_In_ HWND, _In_ UINT, _In_ WPARAM, _In_ LPARAM)
BOOL WINAPI PostMessageW(_In_opt_ HWND, _In_ UINT, _In_ WPARAM, _In_ LPARAM)
BOOL WINAPI GetWindowRect(_In_ HWND, _Out_ LPRECT)
BOOL WINAPI DrawFrameControl(_In_ HDC, _Inout_ LPRECT, _In_ UINT, _In_ UINT)
BOOL WINAPI SetWindowPos(_In_ HWND, _In_opt_ HWND, _In_ int, _In_ int, _In_ int, _In_ int, _In_ UINT)
ATOM WINAPI RegisterClassW(_In_ CONST WNDCLASSW *)
BOOL WINAPI GetCursorPos(_Out_ LPPOINT)
HDC WINAPI GetDCEx(_In_opt_ HWND, _In_opt_ HRGN, _In_ DWORD)
HWND WINAPI GetCapture(void)
HCURSOR WINAPI LoadCursorW(_In_opt_ HINSTANCE, _In_ LPCWSTR)
int WINAPI MapWindowPoints(_In_opt_ HWND hWndFrom, _In_opt_ HWND hWndTo, _Inout_updates_(cPoints) LPPOINT lpPoints, _In_ UINT cPoints)
BOOL WINAPI ClientToScreen(_In_ HWND, _Inout_ LPPOINT)
UINT_PTR WINAPI SetTimer(_In_opt_ HWND, _In_ UINT_PTR, _In_ UINT, _In_opt_ TIMERPROC)
BOOL WINAPI PtInRect(_In_ LPCRECT, _In_ POINT)
BOOL WINAPI GetClientRect(_In_ HWND, _Out_ LPRECT)
HWND WINAPI GetParent(_In_ HWND)
HWND WINAPI WindowFromPoint(_In_ POINT)
BOOL WINAPI OffsetRect(_Inout_ LPRECT, _In_ int, _In_ int)
BOOL WINAPI UnregisterClassW(_In_ LPCWSTR, HINSTANCE)
BOOL WINAPI InvalidateRect(_In_opt_ HWND, _In_opt_ LPCRECT, _In_ BOOL)
BOOL WINAPI KillTimer(_In_opt_ HWND, _In_ UINT_PTR)
#define SetWindowLongPtrW
LRESULT WINAPI SendMessageW(_In_ HWND, _In_ UINT, _In_ WPARAM, _In_ LPARAM)
BOOL WINAPI ScreenToClient(_In_ HWND, _Inout_ LPPOINT)