]> git.saurik.com Git - wxWidgets.git/blobdiff - utils/serialize/serwnd.cpp
Added GLCanvas library (Win only at present).
[wxWidgets.git] / utils / serialize / serwnd.cpp
index 52914a0d89d72c6f0fc74348bbdb20d1e1ccb810..ebfa97b553888b448277dc8e86418f7e63d92cde 100644 (file)
@@ -3,9 +3,9 @@
 // Purpose:     Serialization: wxWindow classes
 // Author:      Guilhem Lavaux
 // Modified by:
-// Created:     11/07/98
+// Created:     July 1998
 // RCS-ID:      $Id$
-// Copyright:   (c) Guilhem Lavaux
+// Copyright:   (c) 1998 Guilhem Lavaux
 // Licence:     wxWindows license
 /////////////////////////////////////////////////////////////////////////////
 
@@ -20,6 +20,8 @@
 #include <wx/objstrm.h>
 #include <wx/utils.h>
 #include <wx/frame.h>
+#include <wx/panel.h>
+#include <wx/menu.h>
 #include <wx/serbase.h>
 #include "serwnd.h"
 
@@ -27,13 +29,12 @@ IMPLEMENT_SERIAL_CLASS(wxWindow, wxObject)
 IMPLEMENT_SERIAL_CLASS(wxIndividualLayoutConstraint, wxObject)
 IMPLEMENT_SERIAL_CLASS(wxLayoutConstraints, wxObject)
 IMPLEMENT_SERIAL_CLASS(wxFrame, wxWindow)
+IMPLEMENT_SERIAL_CLASS(wxPanel, wxWindow)
 //IMPLEMENT_SERIAL_CLASS(wxDialog, wxWindow)
 IMPLEMENT_SERIAL_CLASS(wxMenuBar, wxWindow)
 IMPLEMENT_SERIAL_CLASS(wxMenuItem, wxObject)
 IMPLEMENT_SERIAL_CLASS(wxMenu, wxObject)
 
-// IMPLEMENT_ALIAS_SERIAL_CLASS(wxPanel, wxWindow)
-
 void WXSERIAL(wxWindow)::StoreObject(wxObjectOutputStream& s)
 {
   wxWindow *win_object = (wxWindow *)Object();
@@ -322,3 +323,16 @@ void WXSERIAL(wxMenuItem)::LoadObject(wxObjectInputStream& s)
   item->Check( data_s.Read8() );
   item->SetSubMenu( (wxMenu *)s.GetChild(0) );
 }
+
+void WXSERIAL(wxPanel)::StoreObject(wxObjectOutputStream& s)
+{
+  WXSERIAL(wxWindow)::StoreObject(s);
+}
+
+void WXSERIAL(wxPanel)::LoadObject(wxObjectInputStream& s)
+{
+  WXSERIAL(wxWindow)::LoadObject(s);
+
+  ((wxPanel *)Object())->Create(m_parent, m_id, wxPoint(m_x, m_y),
+                                wxSize(m_w, m_h), m_style, m_name);
+}