]> git.saurik.com Git - wxWidgets.git/commitdiff
Add missing interface items for Phoenix
authorRobin Dunn <robin@alldunn.com>
Thu, 12 Apr 2012 05:33:29 +0000 (05:33 +0000)
committerRobin Dunn <robin@alldunn.com>
Thu, 12 Apr 2012 05:33:29 +0000 (05:33 +0000)
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@71190 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775

include/wx/pickerbase.h
interface/wx/clrpicker.h
interface/wx/filepicker.h
interface/wx/fontpicker.h
interface/wx/pickerbase.h

index 16afd715f084699cb548cc5cb88b5a2410fa8833..8b9be3dd0fece0e00846be0fb68b0e7a57bcf985 100644 (file)
@@ -106,6 +106,11 @@ public:     // public API
     wxControl *GetPickerCtrl()
         { return m_picker; }
 
+    void SetTextCtrl(wxTextCtrl* text)
+        { m_text = text; }
+    void SetPickerCtrl(wxControl* picker)
+        { m_picker = picker; }
+
     // methods that derived class must/may override
     virtual void UpdatePickerFromTextCtrl() = 0;
     virtual void UpdateTextCtrlFromPicker() = 0;
index 913c0fe8311f0cb512d18167668933fc399c98c1..be3c08ac8cda26ad1453292e8a7a0ac8fcc3b713 100644 (file)
@@ -6,6 +6,13 @@
 // Licence:     wxWindows licence
 /////////////////////////////////////////////////////////////////////////////
 
+#define wxCLRP_USE_TEXTCTRL       (wxPB_USE_TEXTCTRL)
+#define wxCLRP_DEFAULT_STYLE      0
+#define wxCLRP_SHOW_LABEL         0x0008
+
+wxEventType wxEVT_COMMAND_COLOURPICKER_CHANGED;
+
+
 /**
     @class wxColourPickerCtrl
 
@@ -46,6 +53,8 @@
 class wxColourPickerCtrl : public wxPickerBase
 {
 public:
+    wxColourPickerCtrl();
+    
     /**
         Initializes the object and calls Create() with all the parameters.
     */
@@ -122,6 +131,8 @@ public:
 class wxColourPickerEvent : public wxCommandEvent
 {
 public:
+    wxColourPickerEvent();
+
     /**
         The constructor is not normally used by the user code.
     */
index 3053fcefc38c3e32856293d9fb4b768242a16d00..40cd69a499da23e24d73259c193bafe155841d34 100644 (file)
@@ -6,6 +6,25 @@
 // Licence:     wxWindows licence
 /////////////////////////////////////////////////////////////////////////////
 
+#define wxFLP_OPEN                    0x0400
+#define wxFLP_SAVE                    0x0800
+#define wxFLP_OVERWRITE_PROMPT        0x1000
+#define wxFLP_FILE_MUST_EXIST         0x2000
+#define wxFLP_CHANGE_DIR              0x4000
+#define wxFLP_SMALL                   wxPB_SMALL
+#define wxFLP_USE_TEXTCTRL            (wxPB_USE_TEXTCTRL)
+#define wxFLP_DEFAULT_STYLE           (wxFLP_OPEN|wxFLP_FILE_MUST_EXIST)
+
+#define wxDIRP_DIR_MUST_EXIST         0x0008
+#define wxDIRP_CHANGE_DIR             0x0010
+#define wxDIRP_SMALL                  wxPB_SMALL
+#define wxDIRP_USE_TEXTCTRL           (wxPB_USE_TEXTCTRL)
+#define wxDIRP_DEFAULT_STYLE          (wxDIRP_DIR_MUST_EXIST)
+
+wxEventType wxEVT_COMMAND_FILEPICKER_CHANGED;
+wxEventType wxEVT_COMMAND_DIRPICKER_CHANGED;
+
+
 /**
     @class wxFilePickerCtrl
 
@@ -60,6 +79,8 @@
 class wxFilePickerCtrl : public wxPickerBase
 {
 public:
+    wxFilePickerCtrl();
+    
     /**
         Initializes the object and calls Create() with
         all the parameters.
@@ -201,6 +222,8 @@ public:
 class wxDirPickerCtrl : public wxPickerBase
 {
 public:
+    wxDirPickerCtrl();
+    
     /**
         Initializes the object and calls Create() with
         all the parameters.
@@ -311,6 +334,8 @@ public:
 class wxFileDirPickerEvent : public wxCommandEvent
 {
 public:
+    wxFileDirPickerEvent();
+
     /**
         The constructor is not normally used by the user code.
     */
index 0cbb18adeba7f79eb253716f83a98e1943c861f5..e354fc37427746c3b409459633d02585c84bc293 100644 (file)
@@ -6,6 +6,16 @@
 // Licence:     wxWindows licence
 /////////////////////////////////////////////////////////////////////////////
 
+
+#define wxFNTP_FONTDESC_AS_LABEL      0x0008
+#define wxFNTP_USEFONT_FOR_LABEL      0x0010
+#define wxFONTBTN_DEFAULT_STYLE       (wxFNTP_FONTDESC_AS_LABEL | wxFNTP_USEFONT_FOR_LABEL)
+#define wxFNTP_USE_TEXTCTRL           (wxPB_USE_TEXTCTRL)
+#define wxFNTP_DEFAULT_STYLE          (wxFNTP_FONTDESC_AS_LABEL|wxFNTP_USEFONT_FOR_LABEL)
+
+wxEventType wxEVT_COMMAND_FONTPICKER_CHANGED;
+
+
 /**
     @class wxFontPickerCtrl
 
@@ -49,6 +59,8 @@
 class wxFontPickerCtrl : public wxPickerBase
 {
 public:
+    wxFontPickerCtrl();
+    
     /**
         Initializes the object and calls Create() with
         all the parameters.
index eec1fec175c637ee35d96620f6ab3d24fa061f8b..c4b2f108f5732ffa65a316246a09563f7b28758e 100644 (file)
@@ -6,6 +6,11 @@
 // Licence:     wxWindows licence
 /////////////////////////////////////////////////////////////////////////////
 
+
+#define wxPB_USE_TEXTCTRL           0x0002
+#define wxPB_SMALL                  0x8000
+
+
 /**
     @class wxPickerBase
 
 class wxPickerBase : public wxControl
 {
 public:
+    wxPickerBase();
+    virtual ~wxPickerBase();
+
+    // if present, intercepts wxPB_USE_TEXTCTRL style and creates the text control
+    // The 3rd argument is the initial wxString to display in the text control
+    bool CreateBase(wxWindow *parent,
+                    wxWindowID id,
+                    const wxString& text = wxEmptyString,
+                    const wxPoint& pos = wxDefaultPosition,
+                    const wxSize& size = wxDefaultSize,
+                    long style = 0,
+                    const wxValidator& validator = wxDefaultValidator,
+                    const wxString& name = wxButtonNameStr);
+
     /**
         Returns the margin (in pixel) between the picker and the text control.
 
@@ -138,5 +157,17 @@ public:
         This function can be used only when HasTextCtrl() returns @true.
     */
     void SetTextCtrlProportion(int prop);
+
+
+    void SetTextCtrl(wxTextCtrl* text);
+    void SetPickerCtrl(wxControl* picker);
+
+    virtual void UpdatePickerFromTextCtrl() = 0;
+    virtual void UpdateTextCtrlFromPicker() = 0;
+    
+protected:
+    virtual long GetTextCtrlStyle(long style) const;
+    virtual long GetPickerStyle(long style) const;
+    void PostCreation();
 };