99#include "wine/unicode.h"
153#define ID_TIMERSHOW 1
155#define ID_TIMERLEAVE 3
158#define TOOLTIPS_GetInfoPtr(hWindow) ((TOOLTIPS_INFO *)GetWindowLongPtrW (hWindow, 0))
161#define NORMAL_TEXT_MARGIN 2
162#define BALLOON_TEXT_MARGIN (NORMAL_TEXT_MARGIN+8)
165#define BALLOON_ROUNDEDNESS 20
166#define BALLOON_STEMHEIGHT 13
167#define BALLOON_STEMWIDTH 10
168#define BALLOON_STEMINDENT 20
170#define BALLOON_ICON_TITLE_SPACING 8
171#define BALLOON_TITLE_TEXT_SPACING 8
172#define ICON_HEIGHT 16
175#define MAX_TEXT_SIZE_A 80
202 NONCLIENTMETRICSW nclm;
208 nclm.cbSize =
sizeof(nclm);
213 nclm.lfStatusFont.lfWeight =
FW_BOLD;
231 lpnmttcd->
nmcd.
rc = *rcBounds;
406 ERR(
"recursive text callback\n");
419 }
else if (ttnmdi.lpszText &&
462 ERR(
"recursive text callback\n");
475 }
else if (ttnmdi.lpszText &&
490 TRACE(
"load res string %p %x\n",
529 RECT rc = {0, 0, 0, 0};
543 RECT rcTitle = {0, 0, 0, 0};
604 if (infoPtr->
nTool == -1)
609 nTool = infoPtr->
nTool;
612 TRACE(
"Show tooltip pre %d, %p\n", nTool, infoPtr->
hwndSelf);
626 toolPtr = &infoPtr->
tools[nTool];
659 rcTool = toolPtr->
rect;
741 mon_info.
cbSize =
sizeof(mon_info);
823 hdr.idFrom = toolPtr->
uId;
837 TRACE(
"timer 2 started\n");
839 TRACE(
"timer 3 started\n");
859 hdr.idFrom = toolPtr->
uId;
891 hdr.idFrom = toolPtr->
uId;
907 for (nTool = 0; nTool < infoPtr->
uNumTools; nTool++) {
908 toolPtr = &infoPtr->
tools[nTool];
911 (lpToolInfo->
hwnd == toolPtr->
hwnd) &&
912 (lpToolInfo->
uId == toolPtr->
uId))
916 for (nTool = 0; nTool < infoPtr->
uNumTools; nTool++) {
917 toolPtr = &infoPtr->
tools[nTool];
920 (lpToolInfo->
uId == toolPtr->
uId))
934 for (nTool = 0; nTool < infoPtr->
uNumTools; nTool++) {
935 toolPtr = &infoPtr->
tools[nTool];
946 for (nTool = 0; nTool < infoPtr->
uNumTools; nTool++) {
947 toolPtr = &infoPtr->
tools[nTool];
994 if (hwndActive ==
hwnd)
1024 TRACE(
"not active: hwnd %p, parent %p, active %p\n",
1030 TRACE(
"tool %d\n", nTool);
1041 TRACE(
"activate %d\n", activate);
1056 if (!ti)
return FALSE;
1066 toolPtr = infoPtr->
tools;
1095 TRACE(
"add CALLBACK\n");
1126 TRACE(
"subclassing installed\n");
1133 TRACE(
" -- WM_NOTIFYFORMAT returns: NFR_ANSI\n");
1136 TRACE(
" -- WM_NOTIFYFORMAT returns: NFR_UNICODE\n");
1138 TRACE (
" -- WM_NOTIFYFORMAT returns: %d\n", nResult);
1167 TRACE(
"tool %d\n", nTool);
1176 toolPtr = &infoPtr->
tools[nTool];
1199 if (nTool < infoPtr->uNumTools - 1)
1200 memcpy (&infoPtr->
tools[nTool], &oldTools[nTool + 1],
1209 if (infoPtr->
nTool == nTool)
1211 infoPtr->
nTool = -1;
1212 else if (infoPtr->
nTool > nTool)
1241 TRACE(
"index=%u\n", uIndex);
1254 if (lpToolInfo ==
NULL)
1260 if (nTool == -1)
return 0;
1262 TRACE(
"tool %d\n", nTool);
1300 WARN(
"Invalid duration flag %x\n", duration);
1335 if (nTool == -1)
return 0;
1365 return infoPtr->
clrBk;
1389 if (!ti)
return FALSE;
1399 TRACE(
"tool %d\n", nTool);
1422 TRACE(
"tool %d\n", nTool);
1445 if (nTool == -1)
return 0;
1469 ERR(
"lpMsg == NULL\n");
1486 nOldTool = infoPtr->
nTool;
1493 if (infoPtr->
nTool != nOldTool) {
1494 if(infoPtr->
nTool == -1) {
1497 }
else if (nOldTool == -1) {
1500 TRACE(
"timer 1 started\n");
1507 TRACE(
"timer 1 started\n");
1513 TRACE(
"timer 2 restarted\n");
1517 TRACE(
"timer 1 started\n");
1557 WARN(
"Invalid duration flag %x\n", duration);
1589 infoPtr->
clrBk = clrBk;
1659 if (nTool == -1)
return 0;
1661 TRACE(
"tool %d\n", nTool);
1663 toolPtr = &infoPtr->
tools[nTool];
1723 if (track_activate) {
1732 TRACE(
"activated\n");
1744 TRACE(
"deactivated\n");
1792 TRACE(
"tool %d\n", nTool);
1794 toolPtr = &infoPtr->
tools[nTool];
1854 infoPtr->
nTool = -1;
1877 if (infoPtr->
tools) {
1879 toolPtr = &infoPtr->
tools[
i];
1956 TRACE(
" nTool=%d\n", nTool);
1958 if ((nTool > -1) && (nTool < infoPtr->
uNumTools)) {
1960 TRACE(
"-- in transparent mode\n");
1990 TRACE(
" -- WM_NOTIFYFORMAT returns: NFR_ANSI\n");
1993 TRACE(
" -- WM_NOTIFYFORMAT returns: NFR_UNICODE\n");
1995 TRACE (
" -- WM_NOTIFYFORMAT returns: error!\n");
2037 FIXME(
"full redraw needed\n");
2077 pszText[
res-1] =
'\0';
2086 TRACE(
"timer %d (%p) expired\n", iTimer, infoPtr->
hwndSelf);
2091 nOldTool = infoPtr->
nTool;
2101 nOldTool = infoPtr->
nTool;
2105 if (infoPtr->
nTool != nOldTool) {
2106 if(infoPtr->
nTool == -1) {
2109 }
else if (nOldTool == -1) {
2110 ERR(
"How did this happen?\n");
2116 TRACE(
"timer 1 started!\n");
2123 ERR(
"Unknown timer id %d\n", iTimer);
2325 case WM_NOTIFYFORMAT:
2347 ERR(
"unknown msg %04x wp=%08lx lp=%08lx\n",
#define WINE_DEFAULT_DEBUG_CHANNEL(t)
PVOID Alloc(IN DWORD dwFlags, IN SIZE_T dwBytes)
BOOL COMCTL32_IsReflectedMessage(UINT uMsg) DECLSPEC_HIDDEN
VOID COMCTL32_RefreshSysColors(void) DECLSPEC_HIDDEN
INT Str_GetPtrAtoW(LPCSTR lpSrc, LPWSTR lpDest, INT nMaxLen) DECLSPEC_HIDDEN
INT WINAPI Str_GetPtrW(LPCWSTR, LPWSTR, INT)
COMCTL32_SysColor comctl32_color
BOOL WINAPI SetWindowSubclass(HWND hWnd, SUBCLASSPROC pfnSubclass, UINT_PTR uIDSubclass, DWORD_PTR dwRef)
BOOL WINAPI RemoveWindowSubclass(HWND hWnd, SUBCLASSPROC pfnSubclass, UINT_PTR uID)
LRESULT WINAPI DefSubclassProc(HWND hWnd, UINT uMsg, WPARAM wParam, LPARAM lParam)
BOOL WINAPI Str_SetPtrW(LPWSTR *lppDest, LPCWSTR lpSrc)
#define WideCharToMultiByte
#define MultiByteToWideChar
unsigned short(__cdecl typeof(TIFFCurrentDirectory))(struct tiff *)
GLint GLint GLint GLint GLint x
GLint GLint GLsizei GLsizei height
GLint GLint GLsizei width
GLsizei GLenum const GLvoid GLsizei GLenum GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLint GLint GLint GLshort GLshort GLshort GLubyte GLubyte GLubyte GLuint GLuint GLuint GLushort GLushort GLushort GLbyte GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLfloat GLint GLint GLint GLint GLshort GLshort GLshort GLshort GLubyte GLubyte GLubyte GLubyte GLuint GLuint GLuint GLuint GLushort GLushort GLushort GLushort GLboolean const GLdouble const GLfloat const GLint const GLshort const GLbyte const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLdouble const GLfloat const GLfloat const GLint const GLint const GLshort const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort GLenum GLenum GLenum GLfloat GLenum GLint GLenum GLenum GLenum GLfloat GLenum GLenum GLint GLenum GLfloat GLenum GLint GLint GLushort GLenum GLenum GLfloat GLenum GLenum GLint GLfloat const GLubyte GLenum GLenum GLenum const GLfloat GLenum GLenum const GLint GLenum GLint GLint GLsizei GLsizei GLint GLenum GLenum const GLvoid GLenum GLenum const GLfloat GLenum GLenum const GLint GLenum GLenum const GLdouble GLenum GLenum const GLfloat GLenum GLenum const GLint GLsizei GLuint GLfloat GLuint GLbitfield GLfloat GLint GLuint GLboolean GLenum GLfloat GLenum GLbitfield GLenum GLfloat GLfloat GLint GLint const GLfloat GLenum GLfloat GLfloat GLint GLint GLfloat GLfloat GLint GLint const GLfloat GLint GLfloat GLfloat GLint GLfloat GLfloat GLint GLfloat GLfloat const GLdouble const GLfloat const GLdouble const GLfloat GLint i
#define memcpy(s1, s2, n)
struct task_struct * current
static DWORD *static HFONT(WINAPI *pCreateFontIndirectExA)(const ENUMLOGFONTEXDVA *)
unsigned __int3264 UINT_PTR
HMONITOR WINAPI MonitorFromRect(LPCRECT, DWORD)
INT WINAPI DrawTextW(HDC hdc, LPCWSTR str, INT count, LPRECT rect, UINT flags)
#define TTM_GETMAXTIPWIDTH
#define LPSTR_TEXTCALLBACKW
#define TTM_GETCURRENTTOOLW
#define TTM_GETTIPTEXTCOLOR
#define LPSTR_TEXTCALLBACKA
#define TTTOOLINFOW_V1_SIZE
#define CDRF_NOTIFYPOSTPAINT
#define TTTOOLINFOW_V3_SIZE
#define TTM_TRACKPOSITION
#define TTM_WINDOWFROMPOINT
#define TTM_UPDATETIPTEXTA
#define TTM_GETCURRENTTOOLA
#define TTM_GETTIPBKCOLOR
#define TTM_UPDATETIPTEXTW
#define TTM_SETTIPBKCOLOR
#define TTM_SETTIPTEXTCOLOR
#define TTM_TRACKACTIVATE
#define TTM_GETBUBBLESIZE
#define TTTOOLINFOA_V1_SIZE
#define TTTOOLINFOW_V2_SIZE
#define TTM_SETMAXTIPWIDTH
void redraw(int x, int y, int cx, int cy)
static __inline const char * wine_dbgstr_point(const POINT *pt)
static __inline const char * wine_dbgstr_rect(const RECT *rect)
TW_UINT32 TW_UINT16 TW_UINT16 MSG
int WINAPI GetObjectW(_In_ HANDLE h, _In_ int c, _Out_writes_bytes_opt_(c) LPVOID pv)
HRGN WINAPI CreateRectRgn(_In_ int, _In_ int, _In_ int, _In_ int)
BOOL WINAPI FrameRgn(_In_ HDC, _In_ HRGN, _In_ HBRUSH, _In_ int, _In_ int)
HRGN WINAPI CreatePolygonRgn(_In_reads_(cPoint) const POINT *pptl, _In_ int cPoint, _In_ int iMode)
HRGN WINAPI CreateRoundRectRgn(_In_ int, _In_ int, _In_ int, _In_ int, _In_ int, _In_ int)
HGDIOBJ WINAPI SelectObject(_In_ HDC, _In_ HGDIOBJ)
int WINAPI CombineRgn(_In_opt_ HRGN hrgnDest, _In_opt_ HRGN hrgnSrc1, _In_opt_ HRGN hrgnSrc2, _In_ int fnCombineMode)
int WINAPI FillRgn(_In_ HDC, _In_ HRGN, _In_ HBRUSH)
int WINAPI FillRect(HDC, LPCRECT, HBRUSH)
HFONT WINAPI CreateFontIndirectW(_In_ const LOGFONTW *)
int WINAPI SetBkMode(_In_ HDC, _In_ int)
COLORREF WINAPI SetTextColor(_In_ HDC, _In_ COLORREF)
HBRUSH WINAPI CreateSolidBrush(_In_ COLORREF)
int WINAPI ReleaseDC(_In_opt_ HWND, _In_ HDC)
HWND WINAPI GetActiveWindow(void)
HANDLE WINAPI LoadImageW(_In_opt_ HINSTANCE, _In_ LPCWSTR, _In_ UINT, _In_ int, _In_ int, _In_ UINT)
#define DT_EXTERNALLEADING
#define COLOR_WINDOWFRAME
LRESULT WINAPI DefWindowProcW(_In_ HWND, _In_ UINT, _In_ WPARAM, _In_ LPARAM)
BOOL WINAPI GetWindowRect(_In_ HWND, _Out_ LPRECT)
int WINAPI LoadStringW(_In_opt_ HINSTANCE hInstance, _In_ UINT uID, _Out_writes_to_(cchBufferMax, return+1) LPWSTR lpBuffer, _In_ int cchBufferMax)
BOOL WINAPI SetWindowPos(_In_ HWND, _In_opt_ HWND, _In_ int, _In_ int, _In_ int, _In_ int, _In_ UINT)
int WINAPI GetWindowRgn(_In_ HWND, _In_ HRGN)
int WINAPI SetWindowRgn(_In_ HWND, _In_opt_ HRGN, _In_ BOOL)
HBRUSH WINAPI GetSysColorBrush(_In_ int)
LONG WINAPI SetWindowLongW(_In_ HWND, _In_ int, _In_ LONG)
LONG WINAPI GetWindowLongW(_In_ HWND, _In_ int)
HICON WINAPI CopyIcon(_In_ HICON)
#define IS_INTRESOURCE(i)
ATOM WINAPI RegisterClassW(_In_ CONST WNDCLASSW *)
BOOL WINAPI GetCursorPos(_Out_ LPPOINT)
BOOL WINAPI AdjustWindowRectEx(_Inout_ LPRECT, _In_ DWORD, _In_ BOOL, _In_ DWORD)
#define WM_SYSCOLORCHANGE
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)
UINT WINAPI GetDoubleClickTime(void)
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)
#define MAKELRESULT(l, h)
BOOL WINAPI IsChild(_In_ HWND, _In_ HWND)
BOOL WINAPI EndPaint(_In_ HWND, _In_ const PAINTSTRUCT *)
BOOL WINAPI DrawIconEx(_In_ HDC, _In_ int, _In_ int, _In_ HICON, _In_ int, _In_ int, _In_ UINT, _In_opt_ HBRUSH, _In_ UINT)
BOOL WINAPI UpdateWindow(_In_ HWND)
HDC WINAPI GetDC(_In_opt_ HWND)
BOOL WINAPI SystemParametersInfoW(_In_ UINT uiAction, _In_ UINT uiParam, _Inout_opt_ PVOID pvParam, _In_ UINT fWinIni)
HWND WINAPI GetParent(_In_ HWND)
HWND WINAPI WindowFromPoint(_In_ POINT)
BOOL WINAPI UnregisterClassW(_In_ LPCWSTR, HINSTANCE)
BOOL WINAPI GetMonitorInfoW(_In_ HMONITOR, _Inout_ LPMONITORINFO)
BOOL WINAPI InvalidateRect(_In_opt_ HWND, _In_opt_ LPCRECT, _In_ BOOL)
HDC WINAPI BeginPaint(_In_ HWND, _Out_ LPPAINTSTRUCT)
BOOL WINAPI KillTimer(_In_opt_ HWND, _In_ UINT_PTR)
#define SetWindowLongPtrW
int WINAPI GetSystemMetrics(_In_ int)
LRESULT WINAPI SendMessageW(_In_ HWND, _In_ UINT, _In_ WPARAM, _In_ LPARAM)
BOOL WINAPI DestroyIcon(_In_ HICON)
BOOL WINAPI ScreenToClient(_In_ HWND, _Inout_ LPPOINT)
_In_opt_ PALLOCATE_FUNCTION _In_opt_ PFREE_FUNCTION Free