1//---------------------------------------------------------------------------
2// This file is generated by wxPython's SIP generator.  Do not edit by hand.
3//
4// Copyright: (c) 2018 by Total Control Software
5// License:   wxWindows License
6//
7// This file will be included by _core.sip
8//
9//---------------------------------------------------------------------------
10
11%ModuleHeaderCode
12#include <wx/progdlg.h>
13%End
14
15
16//---------------------------------------------------------------------------
17
18const int wxPD_CAN_ABORT;
19const int wxPD_APP_MODAL;
20const int wxPD_AUTO_HIDE;
21const int wxPD_ELAPSED_TIME;
22const int wxPD_ESTIMATED_TIME;
23const int wxPD_SMOOTH;
24const int wxPD_REMAINING_TIME;
25const int wxPD_CAN_SKIP;
26class wxGenericProgressDialog : wxDialog
27{
28    %Docstring
29        GenericProgressDialog(title, message, maximum=100, parent=None, style=PD_AUTO_HIDE|PD_APP_MODAL)
30
31        This class represents a dialog that shows a short message and a
32        progress bar.
33    %End
34    %TypeHeaderCode
35        #include <wx/progdlg.h>
36    %End
37
38public:
39    wxGenericProgressDialog(
40        const wxString & title,
41        const wxString & message,
42        int maximum = 100,
43        wxWindow * parent   /TransferThis/ = NULL,
44        int style = wxPD_AUTO_HIDE|wxPD_APP_MODAL
45    );
46    %PreMethodCode
47        if (!wxPyCheckForApp()) return NULL;
48    %End
49
50    ~wxGenericProgressDialog();
51
52    int GetValue() const;
53    %Docstring
54        GetValue() -> int
55
56        Returns the last value passed to the Update() function or wxNOT_FOUND
57        if the dialog has no progress bar.
58    %End
59
60    int GetRange() const;
61    %Docstring
62        GetRange() -> int
63
64        Returns the maximum value of the progress meter, as passed to the
65        constructor or wxNOT_FOUND if the dialog has no progress bar.
66    %End
67
68    wxString GetMessage() const;
69    %Docstring
70        GetMessage() -> String
71
72        Returns the last message passed to the Update() function; if you
73        always passed wxEmptyString to Update() then the message set through
74        the constructor is returned.
75    %End
76
77    bool Pulse(
78        const wxString & newmsg = wxEmptyString,
79        bool * skip   /Out/ = NULL
80    );
81    %Docstring
82        Pulse(newmsg=EmptyString) -> (bool, skip)
83
84        Like Update() but makes the gauge control run in indeterminate mode.
85    %End
86
87    void Resume();
88    %Docstring
89        Resume()
90
91        Can be used to continue with the dialog, after the user had clicked
92        the "Abort" button.
93    %End
94
95    void SetRange(
96        int maximum
97    );
98    %Docstring
99        SetRange(maximum)
100
101        Changes the maximum value of the progress meter given in the
102        constructor.
103    %End
104
105    bool WasCancelled() const;
106    %Docstring
107        WasCancelled() -> bool
108
109        Returns true if the "Cancel" button was pressed.
110    %End
111
112    bool WasSkipped() const;
113    %Docstring
114        WasSkipped() -> bool
115
116        Returns true if the "Skip" button was pressed.
117    %End
118
119    bool Update(
120        int value,
121        const wxString & newmsg = wxEmptyString,
122        bool * skip   /Out/ = NULL
123    );
124    %Docstring
125        Update(value, newmsg=EmptyString) -> (bool, skip)
126
127        Updates the dialog, setting the progress bar to the new value and
128        updating the message if new one is specified.
129    %End
130
131    public:
132    virtual wxPoint GetClientAreaOrigin() const;
133    virtual bool Validate();
134    virtual bool TransferDataToWindow();
135    virtual bool TransferDataFromWindow();
136    virtual void InitDialog();
137    virtual bool AcceptsFocus() const;
138    virtual bool AcceptsFocusRecursively() const;
139    virtual bool AcceptsFocusFromKeyboard() const;
140    virtual void AddChild( wxWindowBase *child );
141    virtual void RemoveChild( wxWindowBase *child );
142    virtual void InheritAttributes();
143    virtual bool ShouldInheritColours() const;
144    virtual void OnInternalIdle();
145    virtual wxWindow *GetMainWindowOfCompositeControl();
146    virtual bool InformFirstDirection(int direction, int size, int availableOtherDir);
147    virtual void SetCanFocus(bool canFocus);
148    virtual bool Destroy();
149    virtual void SetValidator( const wxValidator &validator );
150    virtual wxValidator* GetValidator();
151
152
153    protected:
154    virtual bool ProcessEvent(wxEvent & event);
155    virtual void DoEnable(bool enable);
156    virtual void DoGetPosition(int *x, int *y) const;
157    virtual void DoGetSize(int *width, int *height) const;
158    virtual void DoGetClientSize(int *width, int *height) const;
159    virtual wxSize DoGetBestSize() const;
160    virtual wxSize DoGetBestClientSize() const;
161    virtual void DoSetSize(int x, int y, int width, int height, int sizeFlags);
162    virtual void DoSetClientSize(int width, int height);
163    virtual void DoSetSizeHints( int minW, int minH, int maxW, int maxH, int incW, int incH );
164    virtual wxSize DoGetBorderSize() const;
165    virtual void DoMoveWindow(int x, int y, int width, int height);
166    virtual void DoSetWindowVariant( wxWindowVariant variant);
167    virtual wxBorder GetDefaultBorder() const;
168    virtual wxBorder GetDefaultBorderForControl() const;
169    virtual void DoFreeze();
170    virtual void DoThaw();
171    virtual bool HasTransparentBackground();
172    virtual bool TryBefore(wxEvent& event);
173    virtual bool TryAfter(wxEvent& event);
174
175
176    public:
177
178
179    static
180    wxVisualAttributes GetClassDefaultAttributes(
181        wxWindowVariant variant = wxWINDOW_VARIANT_NORMAL
182    );
183    %Docstring
184        GetClassDefaultAttributes(variant=WINDOW_VARIANT_NORMAL) -> VisualAttributes
185    %End
186    %PreMethodCode
187        if (!wxPyCheckForApp()) return NULL;
188    %End
189
190    public:
191
192
193    %Property(name=Message, get=GetMessage)
194    %Property(name=Range, get=GetRange, set=SetRange)
195    %Property(name=Value, get=GetValue)
196};  // end of class wxGenericProgressDialog
197
198
199class wxProgressDialog : wxGenericProgressDialog
200{
201    %Docstring
202        ProgressDialog(title, message, maximum=100, parent=None, style=PD_APP_MODAL|PD_AUTO_HIDE)
203
204        If supported by the platform this class will provide the platform's
205        native progress dialog, else it will simply be the
206        wxGenericProgressDialog.
207    %End
208    %TypeHeaderCode
209        #include <wx/progdlg.h>
210    %End
211
212public:
213    wxProgressDialog(
214        const wxString & title,
215        const wxString & message,
216        int maximum = 100,
217        wxWindow * parent   /TransferThis/ = NULL,
218        int style = wxPD_APP_MODAL|wxPD_AUTO_HIDE
219    );
220    %PreMethodCode
221        if (!wxPyCheckForApp()) return NULL;
222    %End
223
224    int GetValue() const;
225    %Docstring
226        GetValue() -> int
227
228        Returns the last value passed to the Update() function or wxNOT_FOUND
229        if the dialog has no progress bar.
230    %End
231
232    int GetRange() const;
233    %Docstring
234        GetRange() -> int
235
236        Returns the maximum value of the progress meter, as passed to the
237        constructor or wxNOT_FOUND if the dialog has no progress bar.
238    %End
239
240    wxString GetMessage() const;
241    %Docstring
242        GetMessage() -> String
243
244        Returns the last message passed to the Update() function; if you
245        always passed wxEmptyString to Update() then the message set through
246        the constructor is returned.
247    %End
248
249    bool Pulse(
250        const wxString & newmsg = wxEmptyString,
251        bool * skip   /Out/ = NULL
252    );
253    %Docstring
254        Pulse(newmsg=EmptyString) -> (bool, skip)
255
256        Like Update() but makes the gauge control run in indeterminate mode.
257    %End
258
259    void Resume();
260    %Docstring
261        Resume()
262
263        Can be used to continue with the dialog, after the user had clicked
264        the "Abort" button.
265    %End
266
267    void SetRange(
268        int maximum
269    );
270    %Docstring
271        SetRange(maximum)
272
273        Changes the maximum value of the progress meter given in the
274        constructor.
275    %End
276
277    bool WasCancelled() const;
278    %Docstring
279        WasCancelled() -> bool
280
281        Returns true if the "Cancel" button was pressed.
282    %End
283
284    bool WasSkipped() const;
285    %Docstring
286        WasSkipped() -> bool
287
288        Returns true if the "Skip" button was pressed.
289    %End
290
291    bool Update(
292        int value,
293        const wxString & newmsg = wxEmptyString,
294        bool * skip   /Out/ = NULL
295    );
296    %Docstring
297        Update(value, newmsg=EmptyString) -> (bool, skip)
298
299        Updates the dialog, setting the progress bar to the new value and
300        updating the message if new one is specified.
301    %End
302
303    static
304    wxVisualAttributes GetClassDefaultAttributes(
305        wxWindowVariant variant = wxWINDOW_VARIANT_NORMAL
306    );
307    %Docstring
308        GetClassDefaultAttributes(variant=WINDOW_VARIANT_NORMAL) -> VisualAttributes
309    %End
310    %PreMethodCode
311        if (!wxPyCheckForApp()) return NULL;
312    %End
313
314    public:
315    virtual wxPoint GetClientAreaOrigin() const;
316    virtual bool Validate();
317    virtual bool TransferDataToWindow();
318    virtual bool TransferDataFromWindow();
319    virtual void InitDialog();
320    virtual bool AcceptsFocus() const;
321    virtual bool AcceptsFocusRecursively() const;
322    virtual bool AcceptsFocusFromKeyboard() const;
323    virtual void AddChild( wxWindowBase *child );
324    virtual void RemoveChild( wxWindowBase *child );
325    virtual void InheritAttributes();
326    virtual bool ShouldInheritColours() const;
327    virtual void OnInternalIdle();
328    virtual wxWindow *GetMainWindowOfCompositeControl();
329    virtual bool InformFirstDirection(int direction, int size, int availableOtherDir);
330    virtual void SetCanFocus(bool canFocus);
331    virtual bool Destroy();
332    virtual void SetValidator( const wxValidator &validator );
333    virtual wxValidator* GetValidator();
334
335
336    protected:
337    virtual bool ProcessEvent(wxEvent & event);
338    virtual void DoEnable(bool enable);
339    virtual void DoGetPosition(int *x, int *y) const;
340    virtual void DoGetSize(int *width, int *height) const;
341    virtual void DoGetClientSize(int *width, int *height) const;
342    virtual wxSize DoGetBestSize() const;
343    virtual wxSize DoGetBestClientSize() const;
344    virtual void DoSetSize(int x, int y, int width, int height, int sizeFlags);
345    virtual void DoSetClientSize(int width, int height);
346    virtual void DoSetSizeHints( int minW, int minH, int maxW, int maxH, int incW, int incH );
347    virtual wxSize DoGetBorderSize() const;
348    virtual void DoMoveWindow(int x, int y, int width, int height);
349    virtual void DoSetWindowVariant( wxWindowVariant variant);
350    virtual wxBorder GetDefaultBorder() const;
351    virtual wxBorder GetDefaultBorderForControl() const;
352    virtual void DoFreeze();
353    virtual void DoThaw();
354    virtual bool HasTransparentBackground();
355    virtual bool TryBefore(wxEvent& event);
356    virtual bool TryAfter(wxEvent& event);
357
358
359    public:
360
361
362    public:
363
364
365    %Property(name=Message, get=GetMessage)
366    %Property(name=Range, get=GetRange, set=SetRange)
367    %Property(name=Value, get=GetValue)
368};  // end of class wxProgressDialog
369
370
371
372//---------------------------------------------------------------------------
373
374