00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
#include "precomp.h"
00014
#pragma hdrstop
00015
00016
void CalcSBStuff(
00017
PWND pwnd,
00018
PSBCALC pSBCalc,
00019 BOOL fVert);
00020
00021 #define IsScrollBarControl(h) (GETFNID(h) == FNID_SCROLLBAR)
00022
00023
00024
00025
00026
00027
00028
00029 #define WSB_HORZ_LF 0x0001 // Represents the Left arrow of the horizontal scroll bar.
00030 #define WSB_HORZ_RT 0x0002 // Represents the Right arrow of the horizontal scroll bar.
00031 #define WSB_VERT_UP 0x0004 // Represents the Up arrow of the vert scroll bar.
00032 #define WSB_VERT_DN 0x0008 // Represents the Down arrow of the vert scroll bar.
00033
00034 #define WSB_VERT (WSB_VERT_UP | WSB_VERT_DN)
00035 #define WSB_HORZ (WSB_HORZ_LF | WSB_HORZ_RT)
00036
00037
void DrawCtlThumb(
PSBWND);
00038
00039
00040
00041
00042
00043
00044
00045
00046
00047
00048
00049
00050 #define RETURN_IF_PSBTRACK_INVALID(pSBTrack, pwnd) \
00051
if ((pSBTrack) != PWNDTOPSBTRACK(pwnd)) { \
00052
UserAssert(PWNDTOPSBTRACK(pwnd) == NULL); \
00053
return; \
00054
}
00055
00056
00057
00058
00059
00060
00061
00062
#if DBG
00063
#define REEVALUATE_PSBTRACK(pSBTrack, pwnd, str) \
00064
if ((pSBTrack) != PWNDTOPSBTRACK(pwnd)) { \
00065
RIPMSG3(RIP_WARNING, \
00066
"%s: pSBTrack changed from %#p to %#p", \
00067
(str), (pSBTrack), PWNDTOPSBTRACK(pwnd)); \
00068
} \
00069
(pSBTrack) = PWNDTOPSBTRACK(pwnd)
00070
#else
00071 #define REEVALUATE_PSBTRACK(pSBTrack, pwnd, str) \
00072
(pSBTrack) = PWNDTOPSBTRACK(pwnd)
00073
#endif
00074
00075
00076
00077
00078
00079
00080
00081 int HitTestScrollBar(