]> git.saurik.com Git - wxWidgets.git/blobdiff - src/gtk/dataview.cpp
Make the app object be global in case it is run multiple times, such
[wxWidgets.git] / src / gtk / dataview.cpp
index 76be4d0a35cba5401d27e1dc721eb38abad029de..4b2c185b3fb9b42b87bef927ebbb7667f5856c0c 100644 (file)
 
 #ifndef WX_PRECOMP
     #include "wx/log.h"
 
 #ifndef WX_PRECOMP
     #include "wx/log.h"
+    #include "wx/dcclient.h"
 #endif
 
 #include "wx/stockitem.h"
 #endif
 
 #include "wx/stockitem.h"
-#include "wx/dcclient.h"
 #include "wx/calctrl.h"
 #include "wx/popupwin.h"
 #include "wx/sizer.h"
 #include "wx/calctrl.h"
 #include "wx/popupwin.h"
 #include "wx/sizer.h"
@@ -1438,6 +1438,12 @@ bool wxDataViewCtrl::Create(wxWindow *parent, wxWindowID id,
     m_treeview = gtk_tree_view_new();
     gtk_container_add (GTK_CONTAINER (m_widget), m_treeview);
 
     m_treeview = gtk_tree_view_new();
     gtk_container_add (GTK_CONTAINER (m_widget), m_treeview);
 
+    if (style & wxDV_MULTIPLE)
+    {
+        GtkTreeSelection *selection = gtk_tree_view_get_selection( GTK_TREE_VIEW(m_treeview) );
+        gtk_tree_selection_set_mode( selection, GTK_SELECTION_MULTIPLE );
+    }
+
     gtk_scrolled_window_set_policy (GTK_SCROLLED_WINDOW (m_widget),
         GTK_POLICY_AUTOMATIC, GTK_POLICY_ALWAYS);
     gtk_widget_show (m_treeview);
     gtk_scrolled_window_set_policy (GTK_SCROLLED_WINDOW (m_widget),
         GTK_POLICY_AUTOMATIC, GTK_POLICY_ALWAYS);
     gtk_widget_show (m_treeview);