[ wxwindows-Bugs-1769662 ] wxAuiNotebook::InsertPage() does not change page parent

SourceForge.net noreply at sourceforge.net
Fri Aug 10 08:01:52 PDT 2007


Bugs item #1769662, was opened at 2007-08-07 17:14
Message generated for change (Comment added) made by andrey_yazhuk
You can respond by visiting: 
https://sourceforge.net/tracker/?func=detail&atid=109863&aid=1769662&group_id=9863

Please note that this message will contain a full copy of the comment thread,
including the initial issue submission, for this request,
not just the latest update.
Category: AUI
Group: None
Status: Open
Resolution: None
Priority: 5
Private: No
Submitted By: Andrey (andrey_yazhuk)
Assigned to: Benjamin I. Williams (biwillia76)
Summary: wxAuiNotebook::InsertPage() does not change page parent

Initial Comment:
If a window is not a child window of wxAuiNotebook then calling wxAuiNotebook::AddPage(window) / InsertPage(winbdow) results in inconsistent state – GetParent() for the child window will still return the old value, but the notebook will try to manage it as its own child.

Adding the following line
     
page->Reparent(this);

to wxAuiNotebook::InsertPage() should fix the problem.


----------------------------------------------------------------------

>Comment By: Andrey (andrey_yazhuk)
Date: 2007-08-10 11:01

Message:
Logged In: YES 
user_id=1817710
Originator: YES

I believe page->Reparent(this) should be the first line of
wxAuiNotebook::InsertPage() function.
wxAuiNotebook::AddPage() calls wxAuiNotebook::InsertPage(), so no other
changes needed.

----------------------------------------------------------------------

Comment By: Julian Smart (juliansmart)
Date: 2007-08-10 06:52

Message:
Logged In: YES 
user_id=59495
Originator: NO

Can you be more specific as to where the line should go? Thanks!


----------------------------------------------------------------------

You can respond by visiting: 
https://sourceforge.net/tracker/?func=detail&atid=109863&aid=1769662&group_id=9863




More information about the wx-dev mailing list