applied patch to make wxGLCanvas derive from wxWindow, not wxScrolledWindow (Paul A. Thiessen)

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@12264 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
Vadim Zeitlin
2001-11-02 16:08:52 +00:00
parent 6f75447397
commit 4660d7e5d6
10 changed files with 23 additions and 21 deletions

View File

@@ -6,6 +6,8 @@ INCOMPATIBLE CHANGES SINCE 2.2.x
All (GUI): All (GUI):
- wxGLCanvas now derives directly from wxWindow, not wxScrolledWindow
- wxGridCellAttrProvider class API changed, you will need to update your code - wxGridCellAttrProvider class API changed, you will need to update your code
if you derived any classes from it if you derived any classes from it

View File

@@ -100,7 +100,7 @@ private:
// wxGLCanvas // wxGLCanvas
//--------------------------------------------------------------------------- //---------------------------------------------------------------------------
class WXDLLEXPORT wxGLCanvas: public wxScrolledWindow class WXDLLEXPORT wxGLCanvas: public wxWindow
{ {
public: public:
inline wxGLCanvas() { inline wxGLCanvas() {

View File

@@ -100,7 +100,7 @@ private:
// wxGLCanvas // wxGLCanvas
//--------------------------------------------------------------------------- //---------------------------------------------------------------------------
class WXDLLEXPORT wxGLCanvas: public wxScrolledWindow class WXDLLEXPORT wxGLCanvas: public wxWindow
{ {
public: public:
inline wxGLCanvas() { inline wxGLCanvas() {

View File

@@ -82,7 +82,7 @@ public:
wxWindow* m_window; wxWindow* m_window;
}; };
class WXDLLEXPORT wxGLCanvas: public wxScrolledWindow class WXDLLEXPORT wxGLCanvas: public wxWindow
{ {
DECLARE_CLASS(wxGLCanvas) DECLARE_CLASS(wxGLCanvas)
public: public:

View File

@@ -79,7 +79,7 @@ public:
wxWindow* m_window; wxWindow* m_window;
}; };
class WXDLLEXPORT wxGLCanvas: public wxScrolledWindow class WXDLLEXPORT wxGLCanvas: public wxWindow
{ {
DECLARE_CLASS(wxGLCanvas) DECLARE_CLASS(wxGLCanvas)
public: public:

View File

@@ -237,9 +237,9 @@ gtk_glcanvas_size_callback( GtkWidget *WXUNUSED(widget), GtkAllocation* alloc, w
// wxGlCanvas // wxGlCanvas
//--------------------------------------------------------------------------- //---------------------------------------------------------------------------
IMPLEMENT_CLASS(wxGLCanvas, wxScrolledWindow) IMPLEMENT_CLASS(wxGLCanvas, wxWindow)
BEGIN_EVENT_TABLE(wxGLCanvas, wxScrolledWindow) BEGIN_EVENT_TABLE(wxGLCanvas, wxWindow)
EVT_SIZE(wxGLCanvas::OnSize) EVT_SIZE(wxGLCanvas::OnSize)
END_EVENT_TABLE() END_EVENT_TABLE()
@@ -309,7 +309,7 @@ bool wxGLCanvas::Create( wxWindow *parent,
gtk_widget_push_colormap( colormap ); gtk_widget_push_colormap( colormap );
gtk_widget_push_visual( visual ); gtk_widget_push_visual( visual );
wxScrolledWindow::Create( parent, id, pos, size, style, name ); wxWindow::Create( parent, id, pos, size, style, name );
m_glWidget = m_wxwindow; m_glWidget = m_wxwindow;

View File

@@ -237,9 +237,9 @@ gtk_glcanvas_size_callback( GtkWidget *WXUNUSED(widget), GtkAllocation* alloc, w
// wxGlCanvas // wxGlCanvas
//--------------------------------------------------------------------------- //---------------------------------------------------------------------------
IMPLEMENT_CLASS(wxGLCanvas, wxScrolledWindow) IMPLEMENT_CLASS(wxGLCanvas, wxWindow)
BEGIN_EVENT_TABLE(wxGLCanvas, wxScrolledWindow) BEGIN_EVENT_TABLE(wxGLCanvas, wxWindow)
EVT_SIZE(wxGLCanvas::OnSize) EVT_SIZE(wxGLCanvas::OnSize)
END_EVENT_TABLE() END_EVENT_TABLE()
@@ -309,7 +309,7 @@ bool wxGLCanvas::Create( wxWindow *parent,
gtk_widget_push_colormap( colormap ); gtk_widget_push_colormap( colormap );
gtk_widget_push_visual( visual ); gtk_widget_push_visual( visual );
wxScrolledWindow::Create( parent, id, pos, size, style, name ); wxWindow::Create( parent, id, pos, size, style, name );
m_glWidget = m_wxwindow; m_glWidget = m_wxwindow;

View File

@@ -111,9 +111,9 @@ void wxGLContext::SetColour(const char *colour)
* wxGLCanvas implementation * wxGLCanvas implementation
*/ */
IMPLEMENT_CLASS(wxGLCanvas, wxScrolledWindow) IMPLEMENT_CLASS(wxGLCanvas, wxWindow)
BEGIN_EVENT_TABLE(wxGLCanvas, wxScrolledWindow) BEGIN_EVENT_TABLE(wxGLCanvas, wxWindow)
EVT_SIZE(wxGLCanvas::OnSize) EVT_SIZE(wxGLCanvas::OnSize)
END_EVENT_TABLE() END_EVENT_TABLE()
@@ -217,7 +217,7 @@ bool wxGLCanvas::Create(wxWindow *parent, const wxGLContext *shared, wxWindowID
int *attribList, const wxPalette& palette) int *attribList, const wxPalette& palette)
{ {
m_macEraseOnRedraw = false ; m_macEraseOnRedraw = false ;
wxScrolledWindow::Create( parent, id, pos, size, style, name ); wxWindow::Create( parent, id, pos, size, style, name );
AGLPixelFormat fmt = ChoosePixelFormat(attribList); AGLPixelFormat fmt = ChoosePixelFormat(attribList);
wxCHECK_MSG( fmt, false, wxT("Couldn't create OpenGl pixel format") ); wxCHECK_MSG( fmt, false, wxT("Couldn't create OpenGl pixel format") );

View File

@@ -111,9 +111,9 @@ void wxGLContext::SetColour(const char *colour)
* wxGLCanvas implementation * wxGLCanvas implementation
*/ */
IMPLEMENT_CLASS(wxGLCanvas, wxScrolledWindow) IMPLEMENT_CLASS(wxGLCanvas, wxWindow)
BEGIN_EVENT_TABLE(wxGLCanvas, wxScrolledWindow) BEGIN_EVENT_TABLE(wxGLCanvas, wxWindow)
EVT_SIZE(wxGLCanvas::OnSize) EVT_SIZE(wxGLCanvas::OnSize)
END_EVENT_TABLE() END_EVENT_TABLE()
@@ -217,7 +217,7 @@ bool wxGLCanvas::Create(wxWindow *parent, const wxGLContext *shared, wxWindowID
int *attribList, const wxPalette& palette) int *attribList, const wxPalette& palette)
{ {
m_macEraseOnRedraw = false ; m_macEraseOnRedraw = false ;
wxScrolledWindow::Create( parent, id, pos, size, style, name ); wxWindow::Create( parent, id, pos, size, style, name );
AGLPixelFormat fmt = ChoosePixelFormat(attribList); AGLPixelFormat fmt = ChoosePixelFormat(attribList);
wxCHECK_MSG( fmt, false, wxT("Couldn't create OpenGl pixel format") ); wxCHECK_MSG( fmt, false, wxT("Couldn't create OpenGl pixel format") );

View File

@@ -125,9 +125,9 @@ void wxGLContext::SetColour(const char *colour)
* wxGLCanvas implementation * wxGLCanvas implementation
*/ */
IMPLEMENT_CLASS(wxGLCanvas, wxScrolledWindow) IMPLEMENT_CLASS(wxGLCanvas, wxWindow)
BEGIN_EVENT_TABLE(wxGLCanvas, wxScrolledWindow) BEGIN_EVENT_TABLE(wxGLCanvas, wxWindow)
EVT_SIZE(wxGLCanvas::OnSize) EVT_SIZE(wxGLCanvas::OnSize)
EVT_PALETTE_CHANGED(wxGLCanvas::OnPaletteChanged) EVT_PALETTE_CHANGED(wxGLCanvas::OnPaletteChanged)
EVT_QUERY_NEW_PALETTE(wxGLCanvas::OnQueryNewPalette) EVT_QUERY_NEW_PALETTE(wxGLCanvas::OnQueryNewPalette)
@@ -135,7 +135,7 @@ END_EVENT_TABLE()
wxGLCanvas::wxGLCanvas(wxWindow *parent, wxWindowID id, wxGLCanvas::wxGLCanvas(wxWindow *parent, wxWindowID id,
const wxPoint& pos, const wxSize& size, long style, const wxString& name, const wxPoint& pos, const wxSize& size, long style, const wxString& name,
int *attribList, const wxPalette& palette) : wxScrolledWindow() int *attribList, const wxPalette& palette) : wxWindow()
{ {
m_glContext = (wxGLContext*) NULL; m_glContext = (wxGLContext*) NULL;
@@ -159,7 +159,7 @@ wxGLCanvas::wxGLCanvas( wxWindow *parent,
const wxGLContext *shared, wxWindowID id, const wxGLContext *shared, wxWindowID id,
const wxPoint& pos, const wxSize& size, long style, const wxString& name, const wxPoint& pos, const wxSize& size, long style, const wxString& name,
int *attribList, const wxPalette& palette ) int *attribList, const wxPalette& palette )
: wxScrolledWindow() : wxWindow()
{ {
m_glContext = (wxGLContext*) NULL; m_glContext = (wxGLContext*) NULL;
@@ -184,7 +184,7 @@ wxGLCanvas::wxGLCanvas( wxWindow *parent,
wxGLCanvas::wxGLCanvas( wxWindow *parent, const wxGLCanvas *shared, wxWindowID id, wxGLCanvas::wxGLCanvas( wxWindow *parent, const wxGLCanvas *shared, wxWindowID id,
const wxPoint& pos, const wxSize& size, long style, const wxString& name, const wxPoint& pos, const wxSize& size, long style, const wxString& name,
int *attribList, const wxPalette& palette ): int *attribList, const wxPalette& palette ):
wxScrolledWindow() wxWindow()
{ {
m_glContext = (wxGLContext*) NULL; m_glContext = (wxGLContext*) NULL;