![]() |
blank popup window |
Post Reply ![]() |
Author | |
iftekhar ![]() Groupie ![]() Joined: 25 June 2007 Location: United Kingdom Status: Offline Points: 10 |
![]() ![]() ![]() ![]() ![]() Posted: 24 February 2010 at 5:05am |
Hi,
Whenever a popup is displayed with no controls in it a square shaped button like item (I guess the default popup window with no item) pops up. I would expect it to show nothing if there is no item in the popup bar. CAn anybody tell me is there any way to disable this behavior so that no popup is displayed when there is no controls in the popup bar.
The image with the most might show the problem.
Thanks in advence
|
|
IAT
|
|
![]() |
|
znakeeye ![]() Senior Member ![]() ![]() Joined: 26 July 2006 Status: Offline Points: 1672 |
![]() ![]() ![]() ![]() ![]() |
If you create the menu dynamically, then you can simply choose between CXTPControlPopup and CXTPControlButton:
Handle ON_XTP_CREATECONTROL...
if (icons.count() > 0)
pControl = new CXTPControlPopup(...);
else
pControl = new CXTPControlButton(...);
|
|
![]() |
|
iftekhar ![]() Groupie ![]() Joined: 25 June 2007 Location: United Kingdom Status: Offline Points: 10 |
![]() ![]() ![]() ![]() ![]() |
Hmm...
This partially solves the problem. Then I am not creating them dynamically all my menus.
Also I get similar window for context menu as well. If there is no item in the context menu then this empyt window pops up again. This can happen on CXTPCommandBars::TrackPopupMenu.
Any suggestion for this.
Ideally I would like this behavior to be turned off throughout the application.
|
|
IAT
|
|
![]() |
|
SuperMario ![]() Admin Group ![]() ![]() Joined: 14 February 2004 Status: Offline Points: 18057 |
![]() ![]() ![]() ![]() ![]() |
Maybe you would prefer some disabled button added by default to empty popups? The text can read "no items" or whatever you like. Or you can convert the popup to a label when no controls are added.
|
|
![]() |
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 |