]> git.saurik.com Git - wxWidgets.git/commitdiff
new member functio of wxDbColInfo to allow two step creation , to be
authorRoger Gammans <rgammans@computer-surgery.co.uk>
Sun, 8 Dec 2002 16:04:36 +0000 (16:04 +0000)
committerRoger Gammans <rgammans@computer-surgery.co.uk>
Sun, 8 Dec 2002 16:04:36 +0000 (16:04 +0000)
descibed in the docs.

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

include/wx/dbgrid.h

index af4145e7b53bceb58c8a624354366442a79ae53b..e5c9fa6b08a55b6386f33fe2f56fcd473afad94e 100644 (file)
@@ -78,6 +78,18 @@ public:
     //Recurse to find length.
     int Length() { return (m_next ? m_next->Length() +1 :  1); }
 
+    // Adds a new column info (2 step creation)
+    void AddColInfo (int colNo,
+                    wxString type,
+                    wxString title)
+    {
+        GetLast()->m_next = new wxDbGridColInfo (colNo, type, title, NULL);
+    }
+
+    // Searches last
+    wxDbGridColInfo *GetLast() { return (m_next ? m_next->GetLast() : this); }
+
+
     protected:
     wxDbGridColInfoBase  m_data;
     wxDbGridColInfo     *m_next;