News:

When registered with our forums, feel free to send a "here I am" post here to differ human beings from SPAM bots.

Main Menu

wxSmith deletes initialisation of dialog objects

Started by geronet, October 22, 2007, 07:30:58 PM

Previous topic - Next topic

geronet

Hello out there,
got a little problem with the newest CodeBlocks, i update it often to the latest nightly but with svn version 4540 and 4545 wxSmith deletes the code at the initialize-section:

// Constructor of Dialog
//(*Initialize(Boilerdlg)
wxXmlResource::Get()->LoadObject(this,parent,_T("Boilerdlg"),_T("wxDialog"));
Solltemperatur = (wxTextCtrl*)FindWindow(XRCID("ID_TEXTCTRL1"));
Connect(XRCID("ID_TEXTCTRL1"),wxEVT_COMMAND_TEXT_UPDATED,(wxObjectEventFunction)&Boilerdlg::OnText);
Connect(XRCID("ID_TEXTCTRL1"),wxEVT_COMMAND_TEXT_ENTER,(wxObjectEventFunction)&Boilerdlg::OnTextEnter);
//*)


These lines were made from previos versions of wxSmith, but if i open the dialog in the resource editor the line with "Solltemperatur" and "FindWindow" dissapears and the object is not initialised, resulting to an access violation on runtime if i want to read or write the textcontrol. Even if i create a new control the line with "FindWindow" doesn't show up.

In the header file the object is always there, no matter if "Is member" is checked or not.

// Class deklaration of Dialog
//(*Declarations(Boilerdlg)
wxTextCtrl* Solltemperatur;
//*)


I hope someone can help, Codeblocks is really the best IDE i've ever seen, i have mostly multiple projects opened up (great!) but could not find any solution with the samples or with the search function.
PS: wxWidgets 2.8.6
WinXP
Greetings, Stefan

byo

Ok, it looks like some wxSmith bug. I'll see what could be wrong, probably it's some small bug so hopefully it will be fixed today.

Thanks for the feedback.


   BYO