X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/3bc1a8e6f07454fb22d47b17abd9ae066836a510..59d04dff037f66e9e73b389de72835211f5f0bcd:/wxPython/src/mac/wx.py diff --git a/wxPython/src/mac/wx.py b/wxPython/src/mac/wx.py index 5e6aee5840..159bf91e0e 100644 --- a/wxPython/src/mac/wx.py +++ b/wxPython/src/mac/wx.py @@ -344,6 +344,8 @@ wxPRINT_QUALITY_HIGH = wxc.wxPRINT_QUALITY_HIGH wxPRINT_QUALITY_MEDIUM = wxc.wxPRINT_QUALITY_MEDIUM wxPRINT_QUALITY_LOW = wxc.wxPRINT_QUALITY_LOW wxPRINT_QUALITY_DRAFT = wxc.wxPRINT_QUALITY_DRAFT +wxID_ANY = wxc.wxID_ANY +wxID_SEPARATOR = wxc.wxID_SEPARATOR wxID_OPEN = wxc.wxID_OPEN wxID_CLOSE = wxc.wxID_CLOSE wxID_NEW = wxc.wxID_NEW @@ -463,6 +465,11 @@ wxMM_POINTS = wxc.wxMM_POINTS wxMM_METRIC = wxc.wxMM_METRIC wxTIMER_CONTINUOUS = wxc.wxTIMER_CONTINUOUS wxTIMER_ONE_SHOT = wxc.wxTIMER_ONE_SHOT +wxMOUSE_BTN_ANY = wxc.wxMOUSE_BTN_ANY +wxMOUSE_BTN_NONE = wxc.wxMOUSE_BTN_NONE +wxMOUSE_BTN_LEFT = wxc.wxMOUSE_BTN_LEFT +wxMOUSE_BTN_MIDDLE = wxc.wxMOUSE_BTN_MIDDLE +wxMOUSE_BTN_RIGHT = wxc.wxMOUSE_BTN_RIGHT wxBORDER_DEFAULT = wxc.wxBORDER_DEFAULT wxBORDER_NONE = wxc.wxBORDER_NONE wxBORDER_STATIC = wxc.wxBORDER_STATIC @@ -847,6 +854,7 @@ wxEVT_SCROLL_PAGEUP = wxc.wxEVT_SCROLL_PAGEUP wxEVT_SCROLL_PAGEDOWN = wxc.wxEVT_SCROLL_PAGEDOWN wxEVT_SCROLL_THUMBTRACK = wxc.wxEVT_SCROLL_THUMBTRACK wxEVT_SCROLL_THUMBRELEASE = wxc.wxEVT_SCROLL_THUMBRELEASE +wxEVT_SCROLL_ENDSCROLL = wxc.wxEVT_SCROLL_ENDSCROLL wxEVT_SCROLLWIN_TOP = wxc.wxEVT_SCROLLWIN_TOP wxEVT_SCROLLWIN_BOTTOM = wxc.wxEVT_SCROLLWIN_BOTTOM wxEVT_SCROLLWIN_LINEUP = wxc.wxEVT_SCROLLWIN_LINEUP @@ -1125,14 +1133,15 @@ def EVT_COMMAND_RANGE(win, id1, id2, cmd, func): # Scrolling def EVT_SCROLL(win, func): - win.Connect(-1, -1, wxEVT_SCROLL_TOP, func) - win.Connect(-1, -1, wxEVT_SCROLL_BOTTOM, func) - win.Connect(-1, -1, wxEVT_SCROLL_LINEUP, func) - win.Connect(-1, -1, wxEVT_SCROLL_LINEDOWN, func) - win.Connect(-1, -1, wxEVT_SCROLL_PAGEUP, func) - win.Connect(-1, -1, wxEVT_SCROLL_PAGEDOWN, func) - win.Connect(-1, -1, wxEVT_SCROLL_THUMBTRACK,func) + win.Connect(-1, -1, wxEVT_SCROLL_TOP, func) + win.Connect(-1, -1, wxEVT_SCROLL_BOTTOM, func) + win.Connect(-1, -1, wxEVT_SCROLL_LINEUP, func) + win.Connect(-1, -1, wxEVT_SCROLL_LINEDOWN, func) + win.Connect(-1, -1, wxEVT_SCROLL_PAGEUP, func) + win.Connect(-1, -1, wxEVT_SCROLL_PAGEDOWN, func) + win.Connect(-1, -1, wxEVT_SCROLL_THUMBTRACK, func) win.Connect(-1, -1, wxEVT_SCROLL_THUMBRELEASE,func) + win.Connect(-1, -1, wxEVT_SCROLL_ENDSCROLL, func) def EVT_SCROLL_TOP(win, func): win.Connect(-1, -1, wxEVT_SCROLL_TOP, func) @@ -1158,6 +1167,9 @@ def EVT_SCROLL_THUMBTRACK(win, func): def EVT_SCROLL_THUMBRELEASE(win, func): win.Connect(-1, -1, wxEVT_SCROLL_THUMBRELEASE, func) +def EVT_SCROLL_ENDSCROLL(win, func): + win.Connect(-1, -1, wxEVT_SCROLL_ENDSCROLL, func) + # Scrolling, with an id @@ -1170,6 +1182,7 @@ def EVT_COMMAND_SCROLL(win, id, func): win.Connect(id, -1, wxEVT_SCROLL_PAGEDOWN, func) win.Connect(id, -1, wxEVT_SCROLL_THUMBTRACK,func) win.Connect(id, -1, wxEVT_SCROLL_THUMBRELEASE,func) + win.Connect(-1, -1, wxEVT_SCROLL_ENDSCROLL, func) def EVT_COMMAND_SCROLL_TOP(win, id, func): win.Connect(id, -1, wxEVT_SCROLL_TOP, func) @@ -1195,6 +1208,9 @@ def EVT_COMMAND_SCROLL_THUMBTRACK(win, id, func): def EVT_COMMAND_SCROLL_THUMBRELEASE(win, id, func): win.Connect(id, -1, wxEVT_SCROLL_THUMBRELEASE, func) +def EVT_COMMAND_SCROLL_ENDSCROLL(win, id, func): + win.Connect(id, -1, wxEVT_SCROLL_ENDSCROLL, func) + #--- def EVT_SCROLLWIN(win, func): win.Connect(-1, -1, wxEVT_SCROLLWIN_TOP, func) @@ -1570,7 +1586,8 @@ _wxCallAfterId = None def wxCallAfter(callable, *args, **kw): """ Call the specified function after the current and pending event - handlers have been completed. + handlers have been completed. This is also good for making GUI + method calls from non-GUI threads. """ app = wxGetApp() assert app, 'No wxApp created yet' @@ -1713,6 +1730,7 @@ class wxPySimpleApp(wxApp): def __init__(self, flag=0): wxApp.__init__(self, flag) def OnInit(self): + wxInitAllImageHandlers() return true