Why does context.SetCurrent(&canvas); compile?
Luca Cappa
luca.cappa at sequoia.it
Wed Jan 30 07:28:52 PST 2008
Hello,
On Wed, 30 Jan 2008 16:17:03 +0100, Luca Cappa <luca.cappa at sequoia.it>
wrote:
> Hello,
>
> On Wed, 30 Jan 2008 13:19:27 +0100, Carsten Fuchs
> <CarstenFuchs at T-Online.de> wrote:
>> context.SetCurrent(&canvas); // Why does this line compile???
>>
>> Problem is that there is no overload of wxGLContext::SetCurrent() whose
>> signature matches a pointer to a canvas (the reference overload is OK
>> of course). Am I overlooking something?
>
> just a guess, in the file include\wx\glcanvas.h I see:
>
> #ifdef __WXUNIVERSAL__
> // resolve the conflict with wxWindowUniv::SetCurrent()
> virtual bool SetCurrent(bool doit) { return
> wxWindow::SetCurrent(doit); };
> #endif
That SetCurrent(bool) method belongs to wxGLCanvasBase and not to
wxGLContext, nor to any of its base classes, so just disregard my comment
:)
Luca
More information about the wx-users
mailing list