Search found 18 matches

by vanarieleyen
Wed Sep 18, 2019 8:58 am
Forum: C++ Development
Topic: wxRearrangeCtrl: Howto catch button event
Replies: 4
Views: 59

Re: wxRearrangeCtrl: Howto catch button event

No I didn't miss your reply but was busy implementing it because it looks much cleaner as what I came up with.
Thank you :D
by vanarieleyen
Wed Sep 18, 2019 7:48 am
Forum: C++ Development
Topic: wxRearrangeCtrl: Howto catch button event
Replies: 4
Views: 59

Re: wxRearrangeCtrl: Howto catch button event

After reading and experimenting I got something that 'works' In the implementation of my inherited class I have added: void RenderList::connectButtonEvent(wxWindow* pclComponent) { if (pclComponent) { pclComponent->Connect(wxID_ANY, wxEVT_BUTTON, wxCommandEventHandler(RenderList::onButton), (wxObjec...
by vanarieleyen
Wed Sep 18, 2019 6:36 am
Forum: C++ Development
Topic: wxRearrangeCtrl: Howto catch button event
Replies: 4
Views: 59

wxRearrangeCtrl: Howto catch button event

The wxRearrangeCtrl has a list box with an up and down button that is used to rearrange the items in the list box. These buttons do their job fine. However in my application I would like to perform some extra functions when any of these buttons are pressed. My first attempt was to create my own clas...
by vanarieleyen
Thu Sep 05, 2019 9:14 am
Forum: C++ Development
Topic: wxPropertyGrid - button without toplevel?
Replies: 7
Views: 120

Re: wxPropertyGrid - button without toplevel?

I am running wxWidgets 3.1.*
and it happens with any file that I select or pressing the cancel button.

Yes, it should automatically be freed but apparently it isn't.

For the time being I leave it in the destructor of the frame until the issue is solved.
by vanarieleyen
Thu Sep 05, 2019 8:54 am
Forum: C++ Development
Topic: wxPropertyGrid - button without toplevel?
Replies: 7
Views: 120

Re: wxPropertyGrid - button without toplevel?

Just a small follow up:

I just did a test by first deleting 'pg' on program close.

This removes the error.

Could it be that the memory is not properly freed upon exit?
I thought that it would be automatically freed when the parent class is destroyed...
by vanarieleyen
Thu Sep 05, 2019 8:46 am
Forum: Compiler / Linking / IDE Related
Topic: 'wxGenericDirCtrl' does not name a type ?
Replies: 8
Views: 169

Re: 'wxGenericDirCtrl' does not name a type ?

That is a very good tip! I will remember this.
by vanarieleyen
Thu Sep 05, 2019 8:45 am
Forum: C++ Development
Topic: wxPropertyGrid - button without toplevel?
Replies: 7
Views: 120

Re: wxPropertyGrid - button without toplevel?

I have made a very minimal test case that also has this error: here is the cpp file: /*************************************************************** * Name: propgridMain.cpp * Purpose: Code for Application Frame * Author: Arie van Leyen () * Created: 2019-09-05 * Copyright: Arie van Leyen () * Lice...
by vanarieleyen
Thu Sep 05, 2019 6:54 am
Forum: C++ Development
Topic: wxPropertyGrid - button without toplevel?
Replies: 7
Views: 120

Re: wxPropertyGrid - button without toplevel?

I am not sure.

I would like to try it out but it is rather complicated when using mingw. Of course I can try it in Linux but that would not be of much use because the program I am making is for a win environment.
by vanarieleyen
Thu Sep 05, 2019 6:51 am
Forum: Compiler / Linking / IDE Related
Topic: 'wxGenericDirCtrl' does not name a type ?
Replies: 8
Views: 169

Re: 'wxGenericDirCtrl' does not name a type ?

Max, you are a genius!

I would never have come up with that solution.
However, I think that it shouldn't matter and if it does, it should be mentioned in the documentation...

But anyway, I am happy that it is working :D
by vanarieleyen
Thu Sep 05, 2019 2:33 am
Forum: C++ Development
Topic: wxPropertyGrid - button without toplevel?
Replies: 7
Views: 120

wxPropertyGrid - button without toplevel?

I have a wxPropertyGrid in a wxScrolledWindow, see below rightColumn = new wxSplitterWindow(this, wxID_ANY, wxDefaultPosition, wxSize(350, 400)); wxScrolledWindow* scrollerBottom = new wxScrolledWindow(rightColumn, wxID_ANY); wxBoxSizer* sizerBottom = new wxBoxSizer(wxVERTICAL); pg = new wxPropertyG...
by vanarieleyen
Thu Sep 05, 2019 12:31 am
Forum: C++ Development
Topic: strange call from event problem
Replies: 2
Views: 98

Re: strange call from event problem

Thank you for your tip, it works perfectly now

I have changed it and also moved to Bind() instead of Connect().
by vanarieleyen
Wed Sep 04, 2019 11:12 pm
Forum: Compiler / Linking / IDE Related
Topic: 'wxGenericDirCtrl' does not name a type ?
Replies: 8
Views: 169

Re: 'wxGenericDirCtrl' does not name a type ?

This is previewMain.h /*************************************************************** * Name: previewMain.h * Purpose: Defines Application Frame * Author: Arie van Leyen () * Created: 2019-09-05 * Copyright: Arie van Leyen () * License: **************************************************************...
by vanarieleyen
Wed Sep 04, 2019 6:13 am
Forum: Compiler / Linking / IDE Related
Topic: 'wxGenericDirCtrl' does not name a type ?
Replies: 8
Views: 169

Re: 'wxGenericDirCtrl' does not name a type ?

No, the include is wx/dirctrl.h I can open this file and it shows a line that includes wx/generic/dirctrlg.h This file I can also open and has the declaration of wxGenericDirCtrl, so I guess it should be no problem. However I now see that the constructor line is: class WXDLLIMPEXP_CORE wxGenericDirC...
by vanarieleyen
Wed Sep 04, 2019 3:58 am
Forum: Compiler / Linking / IDE Related
Topic: 'wxGenericDirCtrl' does not name a type ?
Replies: 8
Views: 169

'wxGenericDirCtrl' does not name a type ?

I have a problem with wxGenericDirCtrl. When I create a new project in codeblocks, add the control to the form and compile it I get the following error: ||=== Build: Debug in preview (compiler: GNU GCC Compiler) ===| C:\dev\preview\previewMain.h|185|error: 'wxGenericDirCtrl' does not name a type; di...
by vanarieleyen
Wed Sep 04, 2019 12:56 am
Forum: C++ Development
Topic: wxRearrangeCtrl: Howto catch select event
Replies: 2
Views: 116

Re: wxRearrangeCtrl: Howto catch select event

Just to tell you that your suggestion worked :D

I also wanted to do this so I had already made a class that inherits from wxRearrangeCtrl but I didn't know how to get the id from the list. I searched the wx doc's but nowhere is GetId() mentioned...