2012-01-12 17:34:20 +00:00
|
|
|
from objp.util import dontwrap
|
2012-01-11 20:55:25 +00:00
|
|
|
from cocoa.inter2 import PyGUIObject
|
2011-09-21 20:02:13 +00:00
|
|
|
|
2012-01-12 17:34:20 +00:00
|
|
|
class ExtraFairwareReminderView:
|
|
|
|
def startTimer(self): pass
|
|
|
|
def stopTimer(self): pass
|
|
|
|
def setButtonText_(self, text: str): pass;
|
|
|
|
def enableButton(self): pass
|
|
|
|
|
2011-09-21 20:02:13 +00:00
|
|
|
class PyExtraFairwareReminder(PyGUIObject):
|
|
|
|
def start(self):
|
2012-01-11 20:55:25 +00:00
|
|
|
self.model.start()
|
2011-09-21 20:02:13 +00:00
|
|
|
|
|
|
|
def updateButton(self):
|
2012-01-11 20:55:25 +00:00
|
|
|
self.model.update_button()
|
2011-09-21 20:02:13 +00:00
|
|
|
|
|
|
|
# model --> view
|
2012-01-12 17:34:20 +00:00
|
|
|
@dontwrap
|
2011-09-21 20:02:13 +00:00
|
|
|
def start_timer(self):
|
2012-01-11 20:55:25 +00:00
|
|
|
self.callback.startTimer()
|
2011-09-21 20:02:13 +00:00
|
|
|
|
2012-01-12 17:34:20 +00:00
|
|
|
@dontwrap
|
2011-09-21 20:02:13 +00:00
|
|
|
def stop_timer(self):
|
2012-01-11 20:55:25 +00:00
|
|
|
self.callback.stopTimer()
|
2011-09-21 20:02:13 +00:00
|
|
|
|
2012-01-12 17:34:20 +00:00
|
|
|
@dontwrap
|
2011-09-21 20:02:13 +00:00
|
|
|
def enable_button(self):
|
2012-01-11 20:55:25 +00:00
|
|
|
self.callback.enableButton()
|
2011-09-21 20:02:13 +00:00
|
|
|
|
2012-01-12 17:34:20 +00:00
|
|
|
@dontwrap
|
2011-09-21 20:02:13 +00:00
|
|
|
def set_button_text(self, text):
|
2012-01-11 20:55:25 +00:00
|
|
|
self.callback.setButtonText_(text)
|