]> git.saurik.com Git - wxWidgets.git/blobdiff - include/wx/gtk/combobox.h
No real changes, just cleanup week days handling in wxGenericCalendarCtrl.
[wxWidgets.git] / include / wx / gtk / combobox.h
index 430a3c0fa8df173d4114180dcadb237526babed5..fb718013c5f136c1cf5bc4807ef176aba63ad17c 100644 (file)
@@ -23,7 +23,11 @@ class WXDLLIMPEXP_CORE wxComboBox : public wxChoice,
                                     public wxTextEntry
 {
 public:
-    wxComboBox() { m_strings = NULL; }
+    wxComboBox()
+        : wxChoice(), wxTextEntry()
+    {
+        Init();
+    }
     wxComboBox(wxWindow *parent,
                wxWindowID id,
                const wxString& value = wxEmptyString,
@@ -33,7 +37,9 @@ public:
                long style = 0,
                const wxValidator& validator = wxDefaultValidator,
                const wxString& name = wxComboBoxNameStr)
+        : wxChoice(), wxTextEntry()
     {
+        Init();
         Create(parent, id, value, pos, size, n, choices, style, validator, name);
     }
 
@@ -45,7 +51,9 @@ public:
                long style = 0,
                const wxValidator& validator = wxDefaultValidator,
                const wxString& name = wxComboBoxNameStr)
+        : wxChoice(), wxTextEntry()
     {
+        Init();
         Create(parent, id, value, pos, size, choices, style, validator, name);
     }
 
@@ -80,6 +88,8 @@ public:
     {
         return wxItemContainer::GetStringSelection();
     }
+    virtual void Popup();
+    virtual void Dismiss();
 
     virtual void Clear()
     {
@@ -91,6 +101,8 @@ public:
 
     void OnChar( wxKeyEvent &event );
 
+    virtual void SetValue(const wxString& value);
+
     // Standard event handling
     void OnCut(wxCommandEvent& event);
     void OnCopy(wxCommandEvent& event);
@@ -108,8 +120,8 @@ public:
     void OnUpdateDelete(wxUpdateUIEvent& event);
     void OnUpdateSelectAll(wxUpdateUIEvent& event);
 
-    virtual void DisableEvents();
-    virtual void EnableEvents();
+    virtual void GTKDisableEvents();
+    virtual void GTKEnableEvents();
     GtkWidget* GetConnectWidget();
 
     static wxVisualAttributes
@@ -123,20 +135,22 @@ protected:
     // override this and return true.
     virtual bool UseGTKStyleBase() const { return true; }
 
-    // return the GtkEntry part of the combobox
-    GtkEntry *GetEntry() const;
+    // Override in derived classes to create combo box widgets with
+    // custom list stores.
+    virtual void GTKCreateComboBoxWidget();
+
+    virtual GtkEntry *GetEntry() const
+        { return m_entry; }
+
+    GtkEntry*   m_entry;
 
 private:
     // From wxTextEntry:
-    virtual const wxWindow *GetEditableWindow() const { return this; }
+    virtual wxWindow *GetEditableWindow() { return this; }
     virtual GtkEditable *GetEditable() const;
-    virtual void EnableTextChangedEvents(bool enable)
-    {
-        if ( enable )
-            EnableEvents();
-        else
-            DisableEvents();
-    }
+    virtual void EnableTextChangedEvents(bool enable);
+
+    void Init();
 
     DECLARE_DYNAMIC_CLASS_NO_COPY(wxComboBox)
     DECLARE_EVENT_TABLE()