]> git.saurik.com Git - wxWidgets.git/commitdiff
add Clone() to wxXXXbookEvent and copy ctor to wxBookCtrlBaseEvent
authorVadim Zeitlin <vadim@wxwidgets.org>
Thu, 10 Nov 2005 11:24:19 +0000 (11:24 +0000)
committerVadim Zeitlin <vadim@wxwidgets.org>
Thu, 10 Nov 2005 11:24:19 +0000 (11:24 +0000)
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@36147 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775

include/wx/bookctrl.h
include/wx/notebook.h
include/wx/treebook.h

index 9b4f51632bac9c801e49b0b1758c866a92897973..171366205fdf619a478779dc17ffdb6ce2bfe32c 100644 (file)
@@ -249,10 +249,17 @@ public:
     wxBookCtrlBaseEvent(wxEventType commandType = wxEVT_NULL, int winid = 0,
                         int nSel = -1, int nOldSel = -1)
         : wxNotifyEvent(commandType, winid)
-        {
-            m_nSel = nSel;
-            m_nOldSel = nOldSel;
-        }
+    {
+        m_nSel = nSel;
+        m_nOldSel = nOldSel;
+    }
+
+    wxBookCtrlBaseEvent(const wxBookCtrlBaseEvent& event)
+        : wxNotifyEvent(event)
+    {
+        m_nSel = event.m_nSel;
+        m_nOldSel = event.m_nOldSel;
+    }
 
     // accessors
         // the currently selected page (-1 if none)
index 74fcc220ccdd3bfe12336e2457c57a7b517dd1b6..7f6b719f63dea7a0db2e8469909aef12af4739db 100644 (file)
@@ -115,8 +115,15 @@ public:
     {
     }
 
+    wxNotebookEvent(const wxNotebookEvent& event)
+        : wxBookCtrlBaseEvent(event)
+    {
+    }
+
+    virtual wxEvent *Clone() const { return new wxNotebookEvent(*this); }
+
 private:
-    DECLARE_DYNAMIC_CLASS_NO_COPY(wxNotebookEvent)
+    DECLARE_DYNAMIC_CLASS_NO_ASSIGN(wxNotebookEvent)
 };
 
 BEGIN_DECLARE_EVENT_TYPES()
index 0b414e2ba9b8c24ba3ee7619b3c7ecf2fbcb535d..fc3fa7731ef429b839095052230075ac80b669cf 100644 (file)
@@ -240,8 +240,15 @@ public:
     {
     }
 
+    wxTreebookEvent(const wxTreebookEvent& event)
+        : wxBookCtrlBaseEvent(event)
+    {
+    }
+
+    virtual wxEvent *Clone() const { return new wxTreebookEvent(*this); }
+
 private:
-    DECLARE_DYNAMIC_CLASS_NO_COPY(wxTreebookEvent)
+    DECLARE_DYNAMIC_CLASS_NO_ASSIGN(wxTreebookEvent)
 };
 
 extern WXDLLIMPEXP_CORE const wxEventType wxEVT_COMMAND_TREEBOOK_PAGE_CHANGED;