From 705b61cce0e6c2167d7457c7c2b633688e9c67b6 Mon Sep 17 00:00:00 2001 From: Robin Dunn Date: Tue, 6 Jul 2004 21:01:33 +0000 Subject: [PATCH] little tweaks to match recent CVS changes git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@28183 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775 --- wxPython/src/__misc_rename.i | 3 ++- wxPython/src/_functions.i | 5 ++++- wxPython/src/_toplvl.i | 11 ++++++++--- wxPython/src/_window.i | 22 ++++++++++++++++++++++ wxPython/wxPython/_misc.py | 3 ++- 5 files changed, 38 insertions(+), 6 deletions(-) diff --git a/wxPython/src/__misc_rename.i b/wxPython/src/__misc_rename.i index 77165d9502..6ffdd55315 100644 --- a/wxPython/src/__misc_rename.i +++ b/wxPython/src/__misc_rename.i @@ -114,7 +114,8 @@ %rename(SHUTDOWN_REBOOT) wxSHUTDOWN_REBOOT; %rename(Shutdown) wxShutdown; %rename(Sleep) wxSleep; -%rename(Usleep) wxUsleep; +%rename(MilliSleep) wxMilliSleep; +%rename(MicroSleep) wxMicroSleep; %rename(EnableTopLevelWindows) wxEnableTopLevelWindows; %rename(StripMenuCodes) wxStripMenuCodes; %rename(GetEmailAddress) wxGetEmailAddress; diff --git a/wxPython/src/_functions.i b/wxPython/src/_functions.i index efc60338f3..02238b8ef5 100644 --- a/wxPython/src/_functions.i +++ b/wxPython/src/_functions.i @@ -80,7 +80,10 @@ bool wxShutdown(wxShutdownFlags wFlags); void wxSleep(int secs); -void wxUsleep(unsigned long milliseconds); +void wxMilliSleep(unsigned long milliseconds); +void wxMicroSleep(unsigned long microseconds); +%pythoncode { Usleep = MilliSleep } + void wxEnableTopLevelWindows(bool enable); wxString wxStripMenuCodes(const wxString& in); diff --git a/wxPython/src/_toplvl.i b/wxPython/src/_toplvl.i index d615218244..261d41c041 100644 --- a/wxPython/src/_toplvl.i +++ b/wxPython/src/_toplvl.i @@ -178,7 +178,7 @@ public: // sends a size event to the window using its current size -- this has an // effect of refreshing the window layout // - virtual void SendSizeEvent() { } + virtual void SendSizeEvent(); // menu bar functions @@ -286,8 +286,8 @@ public: // the modal dialogs have a return code - usually the id of the last // pressed button - void SetReturnCode(int returnCode) { m_returnCode = returnCode; } - int GetReturnCode() const { return m_returnCode; } + void SetReturnCode(int returnCode); + int GetReturnCode() const; // splits text up at newlines and places the // lines into a vertical wxBoxSizer @@ -311,6 +311,11 @@ public: static wxVisualAttributes GetClassDefaultAttributes(wxWindowVariant variant = wxWINDOW_VARIANT_NORMAL); + + %pythoncode { + def SendSizeEvent(self): + self.ProcessEvent(wx.SizeEvent((-1,-1))) + } }; //--------------------------------------------------------------------------- diff --git a/wxPython/src/_window.i b/wxPython/src/_window.i index 1c382760f3..f30260b297 100644 --- a/wxPython/src/_window.i +++ b/wxPython/src/_window.i @@ -871,8 +871,30 @@ control custom keypress handler to do the default navigation behaviour for the tab key, since the standard default behaviour for a multiline text control with the wx.TE_PROCESS_TAB style is to insert a tab and not navigate to the next control."); + + + + DocDeclStr( + void , MoveAfterInTabOrder(wxWindow *win), + "Moves this window in the tab navigation order after the specified +sibling window. This means that when the user presses the TAB key on +that other window, the focus switches to this window. + +The default tab order is the same as creation order. This function +and `MoveBeforeInTabOrder` allow to change it after creating all the +windows. +", ""); + + + DocDeclStr( + void , MoveBeforeInTabOrder(wxWindow *win), + "Same as `MoveAfterInTabOrder` except that it inserts this window just +before win instead of putting it right after it.", ""); + + + diff --git a/wxPython/wxPython/_misc.py b/wxPython/wxPython/_misc.py index 3cb27c1f09..8e46b9edb6 100644 --- a/wxPython/wxPython/_misc.py +++ b/wxPython/wxPython/_misc.py @@ -146,7 +146,8 @@ wxSHUTDOWN_POWEROFF = wx._misc.SHUTDOWN_POWEROFF wxSHUTDOWN_REBOOT = wx._misc.SHUTDOWN_REBOOT wxShutdown = wx._misc.Shutdown wxSleep = wx._misc.Sleep -wxUsleep = wx._misc.Usleep +wxMilliSleep = wx._misc.MilliSleep +wxMicroSleep = wx._misc.MicroSleep wxEnableTopLevelWindows = wx._misc.EnableTopLevelWindows wxStripMenuCodes = wx._misc.StripMenuCodes wxGetEmailAddress = wx._misc.GetEmailAddress -- 2.47.2