Code::Blocks Forums

Developer forums (C::B DEVELOPMENT STRICTLY!) => Plugins development => Topic started by: sceedy on February 17, 2020, 09:39:35 pm

Title: wxSmith Generates incorrect code for time picker
Post by: sceedy on February 17, 2020, 09:39:35 pm
I am using Code::Blocks 17.12 on Windows 10

About Information Tab :-
Build: Dec 25 2017,08:45:27 - wx2.8.12 (Windows,unicode) - 32 bit
Name: Code::Blocks
Version: Release 17.12 rev 11256
SDK Version: 1.33.0
Author: The Code::Blocks Team
E-mail: [email protected]
Website: http://www.codeblocks.org

wxWidgets project wizard page 2 :-
wxWidgets 3.1.x selected
wxWidgets project wizard page 4 :-
Preferred GUI Builder : wxSmith
Application Type : Frame Based

Add wxFrame
Add wxTimePickerCtrl
Generates code :-
...
   Connect(ID_TIMEPICKERCTRL1,wxEVT_DATE_CHANGED,(wxObjectEventFunction)&NewFrame::OnTimePickerCtrl1Changed);
...

https://docs.wxwidgets.org/trunk/classwx_time_picker_ctrl.html says :-
...
Event macros for events emitted by this class:

    EVT_TIME_CHANGED(id, func):
...
i.e. not "wxEVT_DATE_CHANGED" as in the generated code
Title: Re: wxSmith Generates incorrect code for time picker
Post by: stahta01 on February 17, 2020, 11:09:45 pm
Does this problem result in a build error?
Or does it result in a run-time issue?

If build error, please post the error?

Tim S.
Title: Re: wxSmith Generates incorrect code for time picker
Post by: stahta01 on February 17, 2020, 11:27:09 pm
Looks like wxTimePickerCtrl was added to wxWidgets in 2.9.3.

wxSmith has a lot of 2.8 support; but, it is missing some/most support for after version 2.8 of wxWidgets.

Tim S.
Title: Re: wxSmith Generates incorrect code for time picker
Post by: Miguel Gimenez on February 18, 2020, 12:05:21 pm
This patch fixes the issue, I will create a ticket.