X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/900d98862dc265f24943f60074d8b69025331737..3de0866e8ce40962137723caaf9206269534b9a7:/wxPython/src/msw/events.py diff --git a/wxPython/src/msw/events.py b/wxPython/src/msw/events.py index 85de45a1f6..402df0334c 100644 --- a/wxPython/src/msw/events.py +++ b/wxPython/src/msw/events.py @@ -4,6 +4,8 @@ import eventsc from misc import * from gdi import * + +from fonts import * class wxEventPtr(wxObjectPtr): def __init__(self,this): self.this = this @@ -41,12 +43,15 @@ class wxEventPtr(wxObjectPtr): def Skip(self, *_args, **_kwargs): val = apply(eventsc.wxEvent_Skip,(self,) + _args, _kwargs) return val + def Clone(self, *_args, **_kwargs): + val = apply(eventsc.wxEvent_Clone,(self,) + _args, _kwargs) + if val: val = wxEventPtr(val) + return val def __repr__(self): return "" % (self.this,) class wxEvent(wxEventPtr): - def __init__(self,*_args,**_kwargs): - self.this = apply(eventsc.new_wxEvent,_args,_kwargs) - self.thisown = 1 + def __init__(self,this): + self.this = this @@ -384,6 +389,53 @@ class wxMouseEvent(wxMouseEventPtr): +class wxMouseCaptureChangedEventPtr(wxEventPtr): + def __init__(self,this): + self.this = this + self.thisown = 0 + def GetCapturedWindow(self, *_args, **_kwargs): + val = apply(eventsc.wxMouseCaptureChangedEvent_GetCapturedWindow,(self,) + _args, _kwargs) + return val + def __repr__(self): + return "" % (self.this,) +class wxMouseCaptureChangedEvent(wxMouseCaptureChangedEventPtr): + def __init__(self,*_args,**_kwargs): + self.this = apply(eventsc.new_wxMouseCaptureChangedEvent,_args,_kwargs) + self.thisown = 1 + + + + +class wxSetCursorEventPtr(wxEventPtr): + def __init__(self,this): + self.this = this + self.thisown = 0 + def GetX(self, *_args, **_kwargs): + val = apply(eventsc.wxSetCursorEvent_GetX,(self,) + _args, _kwargs) + return val + def GetY(self, *_args, **_kwargs): + val = apply(eventsc.wxSetCursorEvent_GetY,(self,) + _args, _kwargs) + return val + def SetCursor(self, *_args, **_kwargs): + val = apply(eventsc.wxSetCursorEvent_SetCursor,(self,) + _args, _kwargs) + return val + def GetCursor(self, *_args, **_kwargs): + val = apply(eventsc.wxSetCursorEvent_GetCursor,(self,) + _args, _kwargs) + if val: val = wxCursorPtr(val) + return val + def HasCursor(self, *_args, **_kwargs): + val = apply(eventsc.wxSetCursorEvent_HasCursor,(self,) + _args, _kwargs) + return val + def __repr__(self): + return "" % (self.this,) +class wxSetCursorEvent(wxSetCursorEventPtr): + def __init__(self,*_args,**_kwargs): + self.this = apply(eventsc.new_wxSetCursorEvent,_args,_kwargs) + self.thisown = 1 + + + + class wxKeyEventPtr(wxEventPtr): def __init__(self,this): self.this = this @@ -409,6 +461,12 @@ class wxKeyEventPtr(wxEventPtr): def HasModifiers(self, *_args, **_kwargs): val = apply(eventsc.wxKeyEvent_HasModifiers,(self,) + _args, _kwargs) return val + def GetRawKeyCode(self, *_args, **_kwargs): + val = apply(eventsc.wxKeyEvent_GetRawKeyCode,(self,) + _args, _kwargs) + return val + def GetRawKeyFlags(self, *_args, **_kwargs): + val = apply(eventsc.wxKeyEvent_GetRawKeyFlags,(self,) + _args, _kwargs) + return val def GetX(self, *_args, **_kwargs): val = apply(eventsc.wxKeyEvent_GetX,(self,) + _args, _kwargs) return val @@ -447,6 +505,12 @@ class wxKeyEventPtr(wxEventPtr): if name == "m_scanCode" : eventsc.wxKeyEvent_m_scanCode_set(self,value) return + if name == "m_rawCode" : + eventsc.wxKeyEvent_m_rawCode_set(self,value) + return + if name == "m_rawFlags" : + eventsc.wxKeyEvent_m_rawFlags_set(self,value) + return self.__dict__[name] = value def __getattr__(self,name): if name == "m_x" : @@ -465,6 +529,10 @@ class wxKeyEventPtr(wxEventPtr): return eventsc.wxKeyEvent_m_metaDown_get(self) if name == "m_scanCode" : return eventsc.wxKeyEvent_m_scanCode_get(self) + if name == "m_rawCode" : + return eventsc.wxKeyEvent_m_rawCode_get(self) + if name == "m_rawFlags" : + return eventsc.wxKeyEvent_m_rawFlags_get(self) raise AttributeError,name def __repr__(self): return "" % (self.this,) @@ -571,6 +639,23 @@ class wxFocusEvent(wxFocusEventPtr): +class wxChildFocusEventPtr(wxCommandEventPtr): + def __init__(self,this): + self.this = this + self.thisown = 0 + def GetWindow(self, *_args, **_kwargs): + val = apply(eventsc.wxChildFocusEvent_GetWindow,(self,) + _args, _kwargs) + return val + def __repr__(self): + return "" % (self.this,) +class wxChildFocusEvent(wxChildFocusEventPtr): + def __init__(self,*_args,**_kwargs): + self.this = apply(eventsc.new_wxChildFocusEvent,_args,_kwargs) + self.thisown = 1 + + + + class wxActivateEventPtr(wxEventPtr): def __init__(self,this): self.this = this @@ -609,6 +694,9 @@ class wxMenuEventPtr(wxEventPtr): def GetMenuId(self, *_args, **_kwargs): val = apply(eventsc.wxMenuEvent_GetMenuId,(self,) + _args, _kwargs) return val + def IsPopup(self, *_args, **_kwargs): + val = apply(eventsc.wxMenuEvent_IsPopup,(self,) + _args, _kwargs) + return val def __repr__(self): return "" % (self.this,) class wxMenuEvent(wxMenuEventPtr): @@ -854,6 +942,20 @@ class wxNotifyEvent(wxNotifyEventPtr): +class wxDisplayChangedEventPtr(wxEventPtr): + def __init__(self,this): + self.this = this + self.thisown = 0 + def __repr__(self): + return "" % (self.this,) +class wxDisplayChangedEvent(wxDisplayChangedEventPtr): + def __init__(self,*_args,**_kwargs): + self.this = apply(eventsc.new_wxDisplayChangedEvent,_args,_kwargs) + self.thisown = 1 + + + + class wxPaletteChangedEventPtr(wxEventPtr): def __init__(self,this): self.this = this @@ -928,6 +1030,27 @@ class wxWindowDestroyEvent(wxWindowDestroyEventPtr): +class wxContextMenuEventPtr(wxCommandEventPtr): + def __init__(self,this): + self.this = this + self.thisown = 0 + def GetPosition(self, *_args, **_kwargs): + val = apply(eventsc.wxContextMenuEvent_GetPosition,(self,) + _args, _kwargs) + if val: val = wxPointPtr(val) + return val + def SetPosition(self, *_args, **_kwargs): + val = apply(eventsc.wxContextMenuEvent_SetPosition,(self,) + _args, _kwargs) + return val + def __repr__(self): + return "" % (self.this,) +class wxContextMenuEvent(wxContextMenuEventPtr): + def __init__(self,*_args,**_kwargs): + self.this = apply(eventsc.new_wxContextMenuEvent,_args,_kwargs) + self.thisown = 1 + + + + class wxTimerEventPtr(wxEventPtr): def __init__(self,this): self.this = this