![]() |
tooltip on sysmenu icon |
Post Reply
|
| Author | |
GBrookman
Newbie
Joined: 14 November 2007 Location: United States Status: Offline Points: 4 |
Post Options
Thanks(0)
Quote Reply
Topic: tooltip on sysmenu iconPosted: 12 November 2010 at 6:25pm |
|
I had a request to add a tooltip to the sysmenu icon when in ribbon mode. This works but I suspect there's a better/smarter way:
LRESULT CMainFrame::OnControlSelected(WPARAM wParam, LPARAM lParam) { UNUSED_ALWAYS(lParam); if ( CXTPControl* pControl = (CXTPControl*)wParam ) { if ( 0 == pControl->GetIconId() ) { pControl->SetIconId(XTP_ID_MENUBAR_SYSMENU); pControl->SetTooltip(_T("MyApp Sysmenu")); pControl->SetDescription(_T("Click here to open, save or print \nand see everything else you can do with MyApp")); } } return 0; } I determined the zero icon ID empirically by debugging. Thanks, Gary |
|
![]() |
|
Oleg
Senior Member
Joined: 21 May 2003 Location: United States Status: Offline Points: 11234 |
Post Options
Thanks(0)
Quote Reply
Posted: 15 November 2010 at 4:19am |
|
Hi,
I'd recommend set these parameters in moment you create Ribbon - just use GetSystemButton method to retrieve pointer to this button.
|
|
|
Oleg, Support Team
CODEJOCK SOFTWARE SOLUTIONS |
|
![]() |
|
GBrookman
Newbie
Joined: 14 November 2007 Location: United States Status: Offline Points: 4 |
Post Options
Thanks(0)
Quote Reply
Posted: 15 November 2010 at 11:19am |
|
thanks, knew there must be a smarter way :)
|
|
![]() |
|
Post Reply
|
|
|
Tweet
|
| Forum Jump | Forum Permissions ![]() You cannot post new topics in this forum You cannot reply to topics in this forum You cannot delete your posts in this forum You cannot edit your posts in this forum You cannot create polls in this forum You cannot vote in polls in this forum |