]> git.saurik.com Git - wxWidgets.git/blobdiff - src/common/treebase.cpp
modified wxEncodingConverter API to report failures
[wxWidgets.git] / src / common / treebase.cpp
index 0096e023eae53595b861f5e76733e42ed00d33ad..54b9c28d4ae1091c545761e889906da67176939f 100644 (file)
@@ -17,7 +17,7 @@
 // headers
 // -----------------------------------------------------------------------------
 
-#ifdef __GNUG__
+#if defined(__GNUG__) && !defined(NO_GCC_PRAGMA)
   #pragma implementation "treebase.h"
 #endif
 
 #include "wx/wxprec.h"
 
 #ifdef __BORLANDC__
-#pragma hdrstop
+    #pragma hdrstop
 #endif
 
+#if wxUSE_TREECTRL
+
 #include "wx/treebase.h"
 #include "wx/settings.h"
 #include "wx/log.h"
@@ -35,7 +37,6 @@
 #include "wx/dynarray.h"
 #include "wx/arrimpl.cpp"
 #include "wx/dcclient.h"
-#include "wx/msgdlg.h"
 
 
 // ----------------------------------------------------------------------------
@@ -60,6 +61,8 @@ DEFINE_EVENT_TYPE(wxEVT_COMMAND_TREE_ITEM_ACTIVATED)
 DEFINE_EVENT_TYPE(wxEVT_COMMAND_TREE_ITEM_RIGHT_CLICK)
 DEFINE_EVENT_TYPE(wxEVT_COMMAND_TREE_ITEM_MIDDLE_CLICK)
 DEFINE_EVENT_TYPE(wxEVT_COMMAND_TREE_END_DRAG)
+DEFINE_EVENT_TYPE(wxEVT_COMMAND_TREE_STATE_IMAGE_CLICK)
+DEFINE_EVENT_TYPE(wxEVT_COMMAND_TREE_ITEM_GETTOOLTIP)
 
 // ----------------------------------------------------------------------------
 // Tree event
@@ -67,10 +70,24 @@ DEFINE_EVENT_TYPE(wxEVT_COMMAND_TREE_END_DRAG)
 
 IMPLEMENT_DYNAMIC_CLASS(wxTreeEvent, wxNotifyEvent)
 
+
 wxTreeEvent::wxTreeEvent(wxEventType commandType, int id)
            : wxNotifyEvent(commandType, id)
 {
-    m_code = 0;
     m_itemOld = 0l;
+    m_editCancelled = false;
+}
+
+wxTreeEvent::wxTreeEvent(const wxTreeEvent & event)
+           : wxNotifyEvent(event)
+{
+    m_evtKey = event.m_evtKey;
+    m_item = event.m_item;
+    m_itemOld = event.m_itemOld;
+    m_pointDrag = event.m_pointDrag;
+    m_label = event.m_label;
+    m_editCancelled = event.m_editCancelled;
 }
 
+#endif // wxUSE_TREECTRL
+