]> git.saurik.com Git - wxWidgets.git/commitdiff
Make some wxDataViewCustomRenderer virtuals consistent across platforms.
authorRobin Dunn <robin@alldunn.com>
Mon, 17 Mar 2008 21:00:06 +0000 (21:00 +0000)
committerRobin Dunn <robin@alldunn.com>
Mon, 17 Mar 2008 21:00:06 +0000 (21:00 +0000)
Add missing WXDLLIMPEXP_ADV.
Add missing impl for wxDataViewEvent::GetPosition

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

include/wx/dataview.h
include/wx/generic/dataview.h
include/wx/mac/carbon/dataview.h
interface/dataview.h

index fc800bcea4247f1284958e5b66a27ceab29fb78a..5e50b0a00e3c60220a7326d8da75f3bbed6b04ee 100644 (file)
@@ -725,7 +725,7 @@ public:
     wxDataViewColumn *GetDataViewColumn() const { return m_column; }
 
     // for wxEVT_DATAVIEW_CONTEXT_MENU only
-    wxPoint GetPosition() const;
+    wxPoint GetPosition() const { return m_pos; }
     void SetPosition( int x, int y ) { m_pos.x = x; m_pos.y = y; }
 
     virtual wxEvent *Clone() const { return new wxDataViewEvent(*this); }
index eecad6d6eb83b17c3d64a758fdaab52ebe4ce37b..d48a6f050efc73ffd809e6ba353d17611d1636a3 100644 (file)
@@ -243,7 +243,7 @@ protected:
 // wxDataViewIconTextRenderer
 // --------------------------------------------------------- 
 
-class wxDataViewIconTextRenderer: public wxDataViewCustomRenderer
+class WXDLLIMPEXP_ADV wxDataViewIconTextRenderer: public wxDataViewCustomRenderer
 {
 public:
     wxDataViewIconTextRenderer( const wxString &varianttype = wxT("wxDataViewIconText"), 
index 01bcffc4fe72b140f755ca36ee0daa2227757129..6dcf5aa7aafb1b239c0ae173b2db635b851fcd80 100644 (file)
@@ -123,26 +123,33 @@ public:
 // 
   virtual bool Render(wxRect cell, wxDC* dc, int state) = 0;
 
-  virtual bool Activate(wxRect WXUNUSED(cell), wxDataViewModel *WXUNUSED(model), unsigned int WXUNUSED(col), unsigned int WXUNUSED(row))
-  {
-    return false;
-  }
-
-  virtual bool LeftClick(wxPoint WXUNUSED(cursor), wxRect WXUNUSED(cell), wxDataViewModel *WXUNUSED(model), unsigned int WXUNUSED(col), unsigned int WXUNUSED(row))
-  {
-    return false;
-  }
-
-  virtual bool RightClick(wxPoint WXUNUSED(cursor), wxRect WXUNUSED(cell), wxDataViewModel *WXUNUSED(model), unsigned int WXUNUSED(col), unsigned int WXUNUSED(row))
-  {
-    return false;
-  }
-
-  virtual bool StartDrag(wxPoint WXUNUSED(cursor), wxRect WXUNUSED(cell), wxDataViewModel *WXUNUSED(model), unsigned int WXUNUSED(col), unsigned int WXUNUSED(row))
-  {
-    return false;
-  }
-
+  virtual bool Activate( wxRect WXUNUSED(cell),
+                         wxDataViewModel *WXUNUSED(model),
+                         const wxDataViewItem & WXUNUSED(item), 
+                         unsigned int WXUNUSED(col) )
+                         { return false; }
+
+  virtual bool LeftClick( wxPoint WXUNUSED(cursor),
+                          wxRect WXUNUSED(cell),
+                          wxDataViewModel *WXUNUSED(model),
+                          const wxDataViewItem & WXUNUSED(item), 
+                          unsigned int WXUNUSED(col) )
+                          { return false; }
+  
+  virtual bool RightClick( wxPoint WXUNUSED(cursor),
+                           wxRect WXUNUSED(cell),
+                           wxDataViewModel *WXUNUSED(model),
+                           const wxDataViewItem & WXUNUSED(item), 
+                           unsigned int WXUNUSED(col) )
+                           { return false; }
+  
+  virtual bool StartDrag( wxPoint WXUNUSED(cursor),
+                          wxRect WXUNUSED(cell),
+                          wxDataViewModel *WXUNUSED(model),
+                          const wxDataViewItem & WXUNUSED(item), 
+                          unsigned int WXUNUSED(col) )
+                          { return false; }
+    
 //
 // device context handling
 //
index 30454f221ce6eccd2a7847b4994d846a16f792cf..5e92e6aefadef0e3f91947f4b69185603b5b7219 100644 (file)
@@ -582,9 +582,10 @@ public:
     /**
         Override this to react to double clicks or ENTER.
     */
-    virtual bool Activate(wxRect cell, wxDataViewModel* model,
-                          unsigned int col,
-                          unsigned int row);
+    virtual bool Activate( wxRect cell,
+                           wxDataViewModel* model,
+                           const wxDataViewItem & item, 
+                           unsigned int col );
 
     /**
         Override this to create the actual editor control once editing
@@ -622,10 +623,11 @@ public:
     /**
         Overrride this to react to a left click.
     */
-    virtual bool LeftClick(wxPoint cursor, wxRect cell,
-                           wxDataViewModel* model,
-                           unsigned int col,
-                           unsigned int row);
+    virtual bool LeftClick( wxPoint cursor,
+                            wxRect cell,
+                            wxDataViewModel * model,
+                            const wxDataViewItem & item, 
+                            unsigned int col );
 
     /**
         Override this to render the cell. Before this is called,
@@ -646,18 +648,19 @@ public:
     /**
         Overrride this to react to a right click.
     */
-    virtual bool RightClick(wxPoint cursor, wxRect cell,
+    virtual bool RightClick(wxPoint cursor,
+                            wxRect cell,
                             wxDataViewModel* model,
-                            unsigned int col,
-                            unsigned int row);
+                            const wxDataViewItem & item, 
+                            unsigned int col);
 
     /**
         Overrride this to start a drag operation.
     */
     virtual bool StartDrag(wxPoint cursor, wxRect cell,
                            wxDataViewModel* model,
-                           unsigned int col,
-                           unsigned int row);
+                           const wxDataViewItem & item, 
+                           unsigned int col);
 };