I’m trying to create a static bitmap but the constructor only accepts wxGDIImages.
Here is the code from the FormBuilder:
wxStaticBitmap* tmtBitmap = new wxStaticBitmap( this, wxID_ANY, wxBitmap( wxT("directory"), wxBITMAP_TYPE_ANY ), wxDefaultPosition, wxDefaultSize, 0 );
Is there any way to convert the wxBitmap to a wxGDIImage? Or create a wxGDIImage given the directory?
Maybe there is another way to do this.
Thanks.
wxStaticBitmapdoes acceptwxBitmapin its constructor (wx API-Doc)The error message produced by the compiler might be a bit misleading
im guessing you see something like this:
Since it is the only thing context depending, there seems to be a problem with your
thispointer, either you are not “inside” awxWindowor your compiler can’t figure out the static type. You can use something like this to verify: (don’t do that in productive code)
or