Kirix Support Forums

Problem with CloseButton(false), when window is floating

Please post all general questions, comments, bug reports, and any other wxAUI feedback here.

Problem with CloseButton(false), when window is floating

Postby rs on Mon Jul 24, 2006 4:20 am

I create new pane with next code:
Code: Select all
   wxPaneInfo pi;
   pi.Caption(wxT("Project"));
   pi.Right();
   pi.CloseButton(false);
   wxFrameManager_.AddPane(project_tree, pi);


and when it just created, all ok (the Close button is not showed). But when pane become floating the close button is present and I can close the pane.
rs
Registered User
 
Posts: 2
Joined: Mon Jul 24, 2006 4:12 am

Postby Ben on Mon Jul 24, 2006 11:00 am

Hi,

I have a fix for you.

1) Edit manager.cpp (or floatpane.cpp if you are using the wxWidgets CVS version)

2) Find the constructor for wxFloatingPane

3) Change "wxCLOSE_BOX" to "(pane.HasCloseButton()?wxCLOSE_BOX:0)"


This fix is already in the wxWidgets CVS version, and will be in the upcoming 0.9.3 backport release.

All the best,
Ben
User avatar
Ben
Kirix Support Team
 
Posts: 522
Joined: Mon Dec 19, 2005 6:29 am

Postby rs on Tue Jul 25, 2006 5:25 am

thanks
rs
Registered User
 
Posts: 2
Joined: Mon Jul 24, 2006 4:12 am

Return to wxAUI Questions, Thoughts & Feedback