ReactOS 0.4.17-dev-1190-g4c812f4
CTooltips Class Reference

#include <rosctrls.h>

Inheritance diagram for CTooltips:
Collaboration diagram for CTooltips:

Public Member Functions

HWND Create (HWND hWndParent, DWORD dwStyles=WS_POPUP|TTS_NOPREFIX, DWORD dwExStyles=WS_EX_TOPMOST)
 
VOID RelayEvent (MSG *pMsg, WPARAM extraInfo=0)
 
INT GetToolCount ()
 
BOOL AddTool (IN CONST TTTOOLINFOW *pInfo)
 
VOID DelTool (IN HWND hwndToolOwner, IN UINT uId)
 
VOID NewToolRect (IN HWND hwndToolOwner, IN UINT uId, IN RECT rect)
 
BOOL GetToolInfo (IN HWND hwndToolOwner, IN UINT uId, IN OUT TTTOOLINFOW *pInfo)
 
VOID SetToolInfo (IN CONST TTTOOLINFOW *pInfo)
 
BOOL HitTest (IN CONST TTHITTESTINFOW *pInfo)
 
VOID GetText (IN HWND hwndToolOwner, IN UINT uId, OUT PWSTR pBuffer, IN DWORD cchBuffer)
 
VOID UpdateTipText (IN HWND hwndToolOwner, IN UINT uId, IN PCWSTR szText, IN HINSTANCE hinstResourceOwner=NULL)
 
BOOL EnumTools (IN CONST TTTOOLINFOW *pInfo)
 
BOOL GetCurrentTool (OUT OPTIONAL TTTOOLINFOW *pInfo=NULL)
 
VOID GetTitle (TTGETTITLE *pTitleInfo)
 
BOOL SetTitle (PCWSTR szTitleText, WPARAM icon=0)
 
VOID TrackActivate (IN HWND hwndToolOwner, IN UINT uId)
 
VOID TrackDeactivate ()
 
VOID TrackPosition (IN WORD x, IN WORD y)
 
VOID Popup ()
 
VOID Pop ()
 
INT GetDelayTime (UINT which)
 
VOID SetDelayTime (UINT which, WORD time)
 
VOID Activate (IN BOOL bActivate=TRUE)
 
VOID AdjustRect (IN BOOL bTextToWindow, IN OUT RECT *pRect)
 
SIZE GetBubbleSize (IN TTTOOLINFOW *pInfo)
 
VOID GetMargin (OUT RECT *pRect)
 
VOID SetMargin (IN RECT *pRect)
 
INT GetMaxTipWidth ()
 
INT SetMaxTipWidth (IN OPTIONAL INT width=-1)
 
COLORREF GetTipTextColor ()
 
VOID SetTipTextColor (IN COLORREF textColor)
 
COLORREF GetTipBkColor ()
 
VOID SetTipBkColor (IN COLORREF textColor)
 
VOID SetWindowTheme (IN PCWSTR szThemeName)
 
VOID Update ()
 
HWND WindowFromPoint (IN POINT *pPoint)
 

Detailed Description

Definition at line 626 of file rosctrls.h.

Member Function Documentation

◆ Activate()

VOID CTooltips::Activate ( IN BOOL  bActivate = TRUE)
inline

Definition at line 772 of file rosctrls.h.

773 {
774 SendMessageW(TTM_ACTIVATE, bActivate);
775 }
#define TTM_ACTIVATE
Definition: commctrl.h:1789
LRESULT WINAPI SendMessageW(_In_ HWND, _In_ UINT, _In_ WPARAM, _In_ LPARAM)

◆ AddTool()

BOOL CTooltips::AddTool ( IN CONST TTTOOLINFOW *  pInfo)
inline

Definition at line 652 of file rosctrls.h.

653 {
654 return SendMessageW(TTM_ADDTOOL, 0, reinterpret_cast<LPARAM>(pInfo));
655 }
LONG_PTR LPARAM
Definition: minwindef.h:175
#define TTM_ADDTOOL
Definition: commctrl.h:1844

Referenced by CTrayShowDesktopButton::DoCreate(), CSysPagerWnd::OnCreate(), and CTrayClockWnd::OnCreate().

◆ AdjustRect()

VOID CTooltips::AdjustRect ( IN BOOL  bTextToWindow,
IN OUT RECT *  pRect 
)
inline

Definition at line 778 of file rosctrls.h.

779 {
780 SendMessageW(TTM_ADJUSTRECT, bTextToWindow, reinterpret_cast<LPARAM>(pRect));
781 }
#define TTM_ADJUSTRECT
Definition: commctrl.h:1831

◆ Create()

HWND CTooltips::Create ( HWND  hWndParent,
DWORD  dwStyles = WS_POPUP | TTS_NOPREFIX,
DWORD  dwExStyles = WS_EX_TOPMOST 
)
inline

Definition at line 631 of file rosctrls.h.

632 {
633 RECT r = { 0 };
634 return CWindow::Create(TOOLTIPS_CLASS, hWndParent, r, L"", dwStyles, dwExStyles);
635 }
#define L(x)
Definition: resources.c:13
GLdouble GLdouble GLdouble r
Definition: gl.h:2055
#define TOOLTIPS_CLASS
Definition: commctrl.h:1710
Definition: dcommon.idl:28

Referenced by CTrayShowDesktopButton::DoCreate(), CSysPagerWnd::OnCreate(), and CTrayClockWnd::OnCreate().

◆ DelTool()

VOID CTooltips::DelTool ( IN HWND  hwndToolOwner,
IN UINT  uId 
)
inline

Definition at line 657 of file rosctrls.h.

658 {
659 TTTOOLINFOW info = { sizeof(TTTOOLINFOW), 0 };
660 info.hwnd = hwndToolOwner;
661 info.uId = uId;
662 SendMessageW(TTM_DELTOOL, 0, reinterpret_cast<LPARAM>(&info));
663 }
struct tagTOOLINFOW TTTOOLINFOW
#define TTM_DELTOOL
Definition: commctrl.h:1845

◆ EnumTools()

BOOL CTooltips::EnumTools ( IN CONST TTTOOLINFOW *  pInfo)
inline

Definition at line 710 of file rosctrls.h.

711 {
712 return SendMessageW(TTM_ENUMTOOLS, 0, reinterpret_cast<LPARAM>(pInfo));
713 }
#define TTM_ENUMTOOLS
Definition: commctrl.h:1852

◆ GetBubbleSize()

SIZE CTooltips::GetBubbleSize ( IN TTTOOLINFOW *  pInfo)
inline

Definition at line 784 of file rosctrls.h.

785 {
786 DWORD ret = SendMessageW(TTM_GETBUBBLESIZE, 0, reinterpret_cast<LPARAM>(pInfo));
787 const SIZE sz = { LOWORD(ret), HIWORD(ret) };
788 return sz;
789 }
return ret
Definition: mutex.c:147
unsigned long DWORD
Definition: ntddk_ex.h:95
#define LOWORD(l)
Definition: pedump.c:82
#define TTM_GETBUBBLESIZE
Definition: commctrl.h:1830
#define HIWORD(l)
Definition: typedefs.h:247

◆ GetCurrentTool()

BOOL CTooltips::GetCurrentTool ( OUT OPTIONAL TTTOOLINFOW *  pInfo = NULL)
inline

Definition at line 715 of file rosctrls.h.

716 {
717 return SendMessageW(TTM_GETCURRENTTOOL, 0, reinterpret_cast<LPARAM>(pInfo));
718 }
#define TTM_GETCURRENTTOOL
Definition: commctrl.h:1853

◆ GetDelayTime()

INT CTooltips::GetDelayTime ( UINT  which)
inline

Definition at line 761 of file rosctrls.h.

762 {
764 }
#define TTM_GETDELAYTIME
Definition: commctrl.h:1821
static GLenum which
Definition: wgl_font.c:159

◆ GetMargin()

VOID CTooltips::GetMargin ( OUT RECT *  pRect)
inline

Definition at line 792 of file rosctrls.h.

793 {
794 SendMessageW(TTM_GETMARGIN, 0, reinterpret_cast<LPARAM>(pRect));
795 }
#define TTM_GETMARGIN
Definition: commctrl.h:1827

◆ GetMaxTipWidth()

INT CTooltips::GetMaxTipWidth ( )
inline

Definition at line 803 of file rosctrls.h.

804 {
806 }
#define TTM_GETMAXTIPWIDTH
Definition: commctrl.h:1825

◆ GetText()

VOID CTooltips::GetText ( IN HWND  hwndToolOwner,
IN UINT  uId,
OUT PWSTR  pBuffer,
IN DWORD  cchBuffer 
)
inline

Definition at line 691 of file rosctrls.h.

692 {
693 TTTOOLINFOW info = { sizeof(TTTOOLINFOW), 0 };
694 info.hwnd = hwndToolOwner;
695 info.uId = uId;
696 info.lpszText = pBuffer;
697 SendMessageW(TTM_GETTEXT, cchBuffer, reinterpret_cast<LPARAM>(&info));
698 }
static DWORD cchBuffer
Definition: fusion.c:85
#define TTM_GETTEXT
Definition: commctrl.h:1850
PVOID pBuffer

◆ GetTipBkColor()

COLORREF CTooltips::GetTipBkColor ( )
inline

Definition at line 824 of file rosctrls.h.

825 {
827 }
#define TTM_GETTIPBKCOLOR
Definition: commctrl.h:1822

◆ GetTipTextColor()

COLORREF CTooltips::GetTipTextColor ( )
inline

Definition at line 814 of file rosctrls.h.

815 {
817 }
#define TTM_GETTIPTEXTCOLOR
Definition: commctrl.h:1823

◆ GetTitle()

VOID CTooltips::GetTitle ( TTGETTITLE *  pTitleInfo)
inline

Definition at line 720 of file rosctrls.h.

721 {
722 SendMessageW(TTM_GETTITLE, 0, reinterpret_cast<LPARAM>(pTitleInfo));
723 }
#define TTM_GETTITLE
Definition: commctrl.h:1836

◆ GetToolCount()

INT CTooltips::GetToolCount ( )
inline

Definition at line 647 of file rosctrls.h.

648 {
649 return SendMessageW(TTM_GETTOOLCOUNT, 0, 0);
650 }
#define TTM_GETTOOLCOUNT
Definition: commctrl.h:1811

◆ GetToolInfo()

BOOL CTooltips::GetToolInfo ( IN HWND  hwndToolOwner,
IN UINT  uId,
IN OUT TTTOOLINFOW *  pInfo 
)
inline

Definition at line 674 of file rosctrls.h.

675 {
676 pInfo->hwnd = hwndToolOwner;
677 pInfo->uId = uId;
678 return SendMessageW(TTM_GETTOOLINFO, 0, reinterpret_cast<LPARAM>(pInfo));
679 }
#define TTM_GETTOOLINFO
Definition: commctrl.h:1847

◆ HitTest()

BOOL CTooltips::HitTest ( IN CONST TTHITTESTINFOW *  pInfo)
inline

Definition at line 686 of file rosctrls.h.

687 {
688 return SendMessageW(TTM_HITTEST, 0, reinterpret_cast<LPARAM>(pInfo));
689 }
#define TTM_HITTEST
Definition: commctrl.h:1849

◆ NewToolRect()

VOID CTooltips::NewToolRect ( IN HWND  hwndToolOwner,
IN UINT  uId,
IN RECT  rect 
)
inline

Definition at line 665 of file rosctrls.h.

666 {
667 TTTOOLINFOW info = { sizeof(TTTOOLINFOW), 0 };
668 info.hwnd = hwndToolOwner;
669 info.uId = uId;
670 info.rect = rect;
671 SendMessageW(TTM_NEWTOOLRECT, 0, reinterpret_cast<LPARAM>(&info));
672 }
RECT rect
Definition: combotst.c:67
#define TTM_NEWTOOLRECT
Definition: commctrl.h:1846

◆ Pop()

VOID CTooltips::Pop ( )
inline

Definition at line 755 of file rosctrls.h.

756 {
758 }
#define TTM_POP
Definition: commctrl.h:1828

◆ Popup()

VOID CTooltips::Popup ( )
inline

Definition at line 749 of file rosctrls.h.

750 {
752 }
#define TTM_POPUP
Definition: commctrl.h:1835

◆ RelayEvent()

VOID CTooltips::RelayEvent ( MSG *  pMsg,
WPARAM  extraInfo = 0 
)
inline

Definition at line 640 of file rosctrls.h.

641 {
642 SendMessageW(TTM_RELAYEVENT, extraInfo, reinterpret_cast<LPARAM>(pMsg));
643 }
#define TTM_RELAYEVENT
Definition: commctrl.h:1797

◆ SetDelayTime()

VOID CTooltips::SetDelayTime ( UINT  which,
WORD  time 
)
inline

Definition at line 766 of file rosctrls.h.

767 {
769 }
__u16 time
Definition: mkdosfs.c:8
#define TTM_SETDELAYTIME
Definition: commctrl.h:1790
#define MAKELPARAM(l, h)
Definition: winuser.h:4116

◆ SetMargin()

VOID CTooltips::SetMargin ( IN RECT *  pRect)
inline

Definition at line 797 of file rosctrls.h.

798 {
799 SendMessageW(TTM_SETMARGIN, 0, reinterpret_cast<LPARAM>(pRect));
800 }
#define TTM_SETMARGIN
Definition: commctrl.h:1826

◆ SetMaxTipWidth()

INT CTooltips::SetMaxTipWidth ( IN OPTIONAL INT  width = -1)
inline

Definition at line 808 of file rosctrls.h.

809 {
811 }
GLint GLint GLsizei width
Definition: gl.h:1546
#define TTM_SETMAXTIPWIDTH
Definition: commctrl.h:1824

Referenced by CBalloonQueue::Show().

◆ SetTipBkColor()

VOID CTooltips::SetTipBkColor ( IN COLORREF  textColor)
inline

Definition at line 829 of file rosctrls.h.

830 {
832 }
#define TTM_SETTIPBKCOLOR
Definition: commctrl.h:1819

◆ SetTipTextColor()

VOID CTooltips::SetTipTextColor ( IN COLORREF  textColor)
inline

Definition at line 819 of file rosctrls.h.

820 {
822 }
#define TTM_SETTIPTEXTCOLOR
Definition: commctrl.h:1820

◆ SetTitle()

BOOL CTooltips::SetTitle ( PCWSTR  szTitleText,
WPARAM  icon = 0 
)
inline

Definition at line 725 of file rosctrls.h.

726 {
727 return SendMessageW(TTM_SETTITLE, icon, reinterpret_cast<LPARAM>(szTitleText));
728 }
#define TTM_SETTITLE
Definition: commctrl.h:1854

Referenced by CBalloonQueue::Show().

◆ SetToolInfo()

VOID CTooltips::SetToolInfo ( IN CONST TTTOOLINFOW *  pInfo)
inline

Definition at line 681 of file rosctrls.h.

682 {
683 SendMessageW(TTM_SETTOOLINFO, 0, reinterpret_cast<LPARAM>(pInfo));
684 }
#define TTM_SETTOOLINFO
Definition: commctrl.h:1848

◆ SetWindowTheme()

VOID CTooltips::SetWindowTheme ( IN PCWSTR  szThemeName)
inline

Definition at line 834 of file rosctrls.h.

835 {
836 SendMessageW(TTM_SETWINDOWTHEME, 0, reinterpret_cast<LPARAM>(szThemeName));
837 }
#define TTM_SETWINDOWTHEME
Definition: commctrl.h:1856

◆ TrackActivate()

VOID CTooltips::TrackActivate ( IN HWND  hwndToolOwner,
IN UINT  uId 
)
inline

Definition at line 730 of file rosctrls.h.

731 {
732 TTTOOLINFOW info = { sizeof(TTTOOLINFOW), 0 };
733 info.hwnd = hwndToolOwner;
734 info.uId = uId;
735 SendMessageW(TTM_TRACKACTIVATE, TRUE, reinterpret_cast<LPARAM>(&info));
736 }
#define TRUE
Definition: types.h:120
#define TTM_TRACKACTIVATE
Definition: commctrl.h:1817

Referenced by CBalloonQueue::Show().

◆ TrackDeactivate()

VOID CTooltips::TrackDeactivate ( )
inline

Definition at line 738 of file rosctrls.h.

739 {
741 }
#define NULL
Definition: types.h:112
#define FALSE
Definition: types.h:117

Referenced by CBalloonQueue::Close().

◆ TrackPosition()

VOID CTooltips::TrackPosition ( IN WORD  x,
IN WORD  y 
)
inline

Definition at line 743 of file rosctrls.h.

744 {
746 }
GLint GLint GLint GLint GLint x
Definition: gl.h:1548
GLint GLint GLint GLint GLint GLint y
Definition: gl.h:1548
#define TTM_TRACKPOSITION
Definition: commctrl.h:1818

Referenced by CBalloonQueue::Show().

◆ Update()

VOID CTooltips::Update ( )
inline

Definition at line 840 of file rosctrls.h.

841 {
843 }
#define TTM_UPDATE
Definition: commctrl.h:1829

◆ UpdateTipText()

VOID CTooltips::UpdateTipText ( IN HWND  hwndToolOwner,
IN UINT  uId,
IN PCWSTR  szText,
IN HINSTANCE  hinstResourceOwner = NULL 
)
inline

Definition at line 700 of file rosctrls.h.

701 {
702 TTTOOLINFOW info = { sizeof(TTTOOLINFOW), 0 };
703 info.hwnd = hwndToolOwner;
704 info.uId = uId;
705 info.lpszText = const_cast<PWSTR>(szText);
706 info.hinst = hinstResourceOwner;
707 SendMessageW(TTM_UPDATETIPTEXT, 0, reinterpret_cast<LPARAM>(&info));
708 }
#define TTM_UPDATETIPTEXT
Definition: commctrl.h:1851
uint16_t * PWSTR
Definition: typedefs.h:56

Referenced by CBalloonQueue::Show(), and CTrayClockWnd::UpdateWnd().

◆ WindowFromPoint()

HWND CTooltips::WindowFromPoint ( IN POINT *  pPoint)
inline

Definition at line 845 of file rosctrls.h.

846 {
847 return reinterpret_cast<HWND>(SendMessageW(TTM_WINDOWFROMPOINT, 0, reinterpret_cast<LPARAM>(pPoint)));
848 }
#define TTM_WINDOWFROMPOINT
Definition: commctrl.h:1816

The documentation for this class was generated from the following file: