Re: Adding page dynamically does not work on Windows

Vadim Zeitlin <[email protected]> Tue, 16 Jun 2026 14:33:13 +0200
Newsgroups gmane.comp.lib.wxwindows.general
Message-ID <[email protected]>
--8323329-630668850-1781613193=:2040883
Content-Type: TEXT/PLAIN; CHARSET=UTF-8
Content-Transfer-Encoding: QUOTED-PRINTABLE
Content-Disposition: INLINE

On Tue, 16 Jun 2026 12:06:05 +0000 Gatti Gianluca wrote:

GG> This is the line of code (I think it is not necessary share all the sou=
rce code):

 Hello,

 In general it's really best to provide a full, self-contained example
reproducing the problem, please see our bug reporting guidelines for detail=
s:

=09https://wxwidgets.org/develop/how-to-report-issues/

GG> =E2=80=82=E2=80=82=E2=80=82=E2=80=82_my_dialog->m_auinotebook1->AddPage=
(new MyPanel(_my_dialog), "");

 But in this case this line is indeed enough to show the problem: MyPanel
must use wxAuiNotebook as its parent, not the dialog. It's actually strange
that using a wrong parent doesn't result in an assert failure, I think it
should.

GG> As I said before, on Linux (Ubuntu 24) it does work

 The promise of wxWidgets is that correct code will work on all the
supported platforms, it's too difficult to guarantee that wrong code fails
in the same way everywhere.

 Regards,
VZ

--=20
TT-Solutions: wxWidgets consultancy and technical support
               https://www.tt-solutions.com/

--8323329-630668850-1781613193=:2040883
Content-Type: APPLICATION/PGP-SIGNATURE

-----BEGIN PGP SIGNATURE-----

iF0EABECAB0WIQQx+vLQdOwioQqkxtoG6kHeT2wehgUCajFCiQAKCRAG6kHeT2we
htP/AJwM91lHApwUhowlVYvY9OhvCyVFugCfXrMWTAEsKmrhtew3l4PrBqFHzxs=
=hl8s
-----END PGP SIGNATURE-----

--8323329-630668850-1781613193=:2040883--