diff --git a/slic/gui/widgets/alarm.py b/slic/gui/widgets/alarm.py new file mode 100644 index 00000000..9781888f --- /dev/null +++ b/slic/gui/widgets/alarm.py @@ -0,0 +1,11 @@ +import wx + + +class AlarmMixin: + + def alarm(self, obj=None): + obj = obj or self + wx.GetTopLevelParent(obj).Raise() + + + diff --git a/slic/gui/widgets/tools.py b/slic/gui/widgets/tools.py index 736503ed..0101bf8b 100644 --- a/slic/gui/widgets/tools.py +++ b/slic/gui/widgets/tools.py @@ -4,15 +4,6 @@ import wx WX_DEFAULT_RESIZABLE_DIALOG_STYLE = wx.DEFAULT_DIALOG_STYLE|wx.RESIZE_BORDER|wx.MINIMIZE_BOX|wx.MAXIMIZE_BOX - -class AlarmMixin: - - def alarm(self, obj=None): - obj = obj or self - wx.GetTopLevelParent(obj).Raise() - - - def post_event(event, source): evt = wx.PyCommandEvent(event.typeId, source.GetId()) wx.PostEvent(source, evt)