]> git.saurik.com Git - wxWidgets.git/commitdiff
Improve documentation of wxDataViewCtrl mouse event handling.
authorVadim Zeitlin <vadim@wxwidgets.org>
Fri, 4 May 2012 20:35:52 +0000 (20:35 +0000)
committerVadim Zeitlin <vadim@wxwidgets.org>
Fri, 4 May 2012 20:35:52 +0000 (20:35 +0000)
Explain that catching mouse events directly doesn't work.

Also make it clear that double clicking an item can be caught by processing
wxEVT_COMMAND_DATAVIEW_ITEM_ACTIVATED.

See #14111.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@71361 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775

interface/wx/dataview.h

index c699896803df3f2adc2af692edfa7c8303ca5535..b17c22906091d1aac2d50c45d9de9a86f1d5dc80 100644 (file)
@@ -747,7 +747,9 @@ wxEventType wxEVT_COMMAND_DATAVIEW_ITEM_DROP;
     @event{EVT_DATAVIEW_SELECTION_CHANGED(id, func)}
            Process a @c wxEVT_COMMAND_DATAVIEW_SELECTION_CHANGED event.
     @event{EVT_DATAVIEW_ITEM_ACTIVATED(id, func)}
-           Process a @c wxEVT_COMMAND_DATAVIEW_ITEM_ACTIVATED event.
+           Process a @c wxEVT_COMMAND_DATAVIEW_ITEM_ACTIVATED event. This event
+           is triggered by double clicking an item or pressing some special key
+           (usually "Enter") when it is focused.
     @event{EVT_DATAVIEW_ITEM_START_EDITING(id, func)}
            Process a @c wxEVT_COMMAND_DATAVIEW_ITEM_START_EDITING event. This
            event can be vetoed in order to prevent editing on an item by item
@@ -788,6 +790,11 @@ wxEventType wxEVT_COMMAND_DATAVIEW_ITEM_DROP;
            Process a @c wxEVT_COMMAND_DATAVIEW_ITEM_DROP event.
     @endEventTable
 
+    Notice that this control doesn't allow to process generic mouse events such
+    as @c wxEVT_LEFT_DOWN in all ports (notably it doesn't work in wxGTK). If
+    you need to handle any mouse events not covered by the ones above, consider
+    using a custom renderer for the cells that must handle them.
+
     @library{wxadv}
     @category{ctrl,dvc}
     @appearance{dataviewctrl.png}