X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/e058867b94a4cec792377318b41e304797aeeaa2..2693507fda7617b7cd16197f92e9abacf1ce75f9:/wxPython/src/gtk/_misc.py diff --git a/wxPython/src/gtk/_misc.py b/wxPython/src/gtk/_misc.py index a221887ce5..e020898a52 100644 --- a/wxPython/src/gtk/_misc.py +++ b/wxPython/src/gtk/_misc.py @@ -950,7 +950,7 @@ class Timer(_core.EvtHandler): self.this = newobj.this self.thisown = 1 del newobj.thisown - self._setCallbackInfo(self, Timer, 0) + self._setCallbackInfo(self, Timer, 0); self._setOORInfo(self) def __del__(self, destroy=_misc_.delete_Timer): """__del__(self)""" @@ -966,6 +966,10 @@ class Timer(_core.EvtHandler): """SetOwner(self, EvtHandler owner, int id=-1)""" return _misc_.Timer_SetOwner(*args, **kwargs) + def GetOwner(*args, **kwargs): + """GetOwner(self) -> EvtHandler""" + return _misc_.Timer_GetOwner(*args, **kwargs) + def Start(*args, **kwargs): """Start(self, int milliseconds=-1, bool oneShot=False) -> bool""" return _misc_.Timer_Start(*args, **kwargs) @@ -2020,13 +2024,9 @@ SOUND_LOOP = _misc_.SOUND_LOOP class Sound(object): def __repr__(self): return "<%s.%s; proxy of C++ wxSound instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this,) - def __init__(self, *args): - """ - __init__(self) -> Sound - __init__(self, String fileName, bool isResource=false) -> Sound - __init__(self, int size, wxByte data) -> Sound - """ - newobj = _misc_.new_Sound(*args) + def __init__(self, *args, **kwargs): + """__init__(self, String fileName=EmptyString) -> Sound""" + newobj = _misc_.new_Sound(*args, **kwargs) self.this = newobj.this self.thisown = 1 del newobj.thisown @@ -2036,24 +2036,25 @@ class Sound(object): if self.thisown: destroy(self) except: pass - def Create(*args): - """ - Create(self, String fileName, bool isResource=false) -> bool - Create(self, int size, wxByte data) -> bool - """ - return _misc_.Sound_Create(*args) + def Create(*args, **kwargs): + """Create(self, String fileName) -> bool""" + return _misc_.Sound_Create(*args, **kwargs) + + def CreateFromData(*args, **kwargs): + """CreateFromData(self, PyObject data) -> bool""" + return _misc_.Sound_CreateFromData(*args, **kwargs) def IsOk(*args, **kwargs): """IsOk(self) -> bool""" return _misc_.Sound_IsOk(*args, **kwargs) - def Play(*args): + def Play(*args, **kwargs): """Play(self, unsigned int flags=SOUND_ASYNC) -> bool""" - return _misc_.Sound_Play(*args) + return _misc_.Sound_Play(*args, **kwargs) - def PlaySound(*args): + def PlaySound(*args, **kwargs): """PlaySound(String filename, unsigned int flags=SOUND_ASYNC) -> bool""" - return _misc_.Sound_PlaySound(*args) + return _misc_.Sound_PlaySound(*args, **kwargs) PlaySound = staticmethod(PlaySound) def Stop(*args, **kwargs): @@ -2070,9 +2071,15 @@ class SoundPtr(Sound): self.__class__ = Sound _misc_.Sound_swigregister(SoundPtr) -def Sound_PlaySound(*args): +def SoundFromData(*args, **kwargs): + """SoundFromData(PyObject data) -> Sound""" + val = _misc_.new_SoundFromData(*args, **kwargs) + val.thisown = 1 + return val + +def Sound_PlaySound(*args, **kwargs): """Sound_PlaySound(String filename, unsigned int flags=SOUND_ASYNC) -> bool""" - return _misc_.Sound_PlaySound(*args) + return _misc_.Sound_PlaySound(*args, **kwargs) def Sound_Stop(*args, **kwargs): """Sound_Stop()"""