![]() |
SetCloseSubMenuOnClick - redraw problem |
Post Reply ![]() |
Author | |
znakeeye ![]() Senior Member ![]() ![]() Joined: 26 July 2006 Status: Offline Points: 1672 |
![]() ![]() ![]() ![]() ![]() Posted: 20 May 2009 at 7:53am |
Here's a popup-gallery (SetCloseSubMenuOnClick = FALSE):
![]() "Clear" has been pressed, but the list is not redrawn until I hover it with the mouse!
When I press "Clear" the following code is executed: void CMainFrame::OnGalleryClear()
{ for (int i = 0; i < m_pItems->GetItemCount(); ++i) { CControlGalleryItem *pItem = DYNAMIC_DOWNCAST(CControlGalleryItem, m_pItems->GetItem(i)); ASSERT(pItem); if (pItem) pItem->SetChecked(FALSE); } } Q: How do I enforce a redraw of the list here? |
|
PokerMemento - http://www.pokermemento.com/
|
|
![]() |
|
Oleg ![]() Admin Group ![]() Joined: 21 May 2003 Location: United States Status: Offline Points: 11234 |
![]() ![]() ![]() ![]() ![]() |
Hi,
We don't have SetChecked method - so its part of your code - add pGallery->InvalidateItems(); after.
|
|
Oleg, Support Team
CODEJOCK SOFTWARE SOLUTIONS |
|
![]() |
|
znakeeye ![]() Senior Member ![]() ![]() Joined: 26 July 2006 Status: Offline Points: 1672 |
![]() ![]() ![]() ![]() ![]() |
Is there a nice way of getting the gallery pointer?
Do I have to use pRibbon->Find...?
|
|
PokerMemento - http://www.pokermemento.com/
|
|
![]() |
|
Oleg ![]() Admin Group ![]() Joined: 21 May 2003 Location: United States Status: Offline Points: 11234 |
![]() ![]() ![]() ![]() ![]() |
hi, think best way is pCommandBars->GetActions()->GetAction(Id)->RedrawControls();
|
|
Oleg, Support Team
CODEJOCK SOFTWARE SOLUTIONS |
|
![]() |
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 |