Web   ·   Wiki   ·   Activities   ·   Blog   ·   Lists   ·   Chat   ·   Meeting   ·   Bugs   ·   Git   ·   Translate   ·   Archive   ·   People   ·   Donate
summaryrefslogtreecommitdiffstats
path: root/plugins/plugin.py
diff options
context:
space:
mode:
authorWalter Bender <walter.bender@gmail.com>2011-02-19 16:20:42 (GMT)
committer Walter Bender <walter.bender@gmail.com>2011-02-19 16:20:42 (GMT)
commit122c2d0a1293688c63cba02155f1ce103519cf45 (patch)
treeb0e4bebef86686fa6b7a8709c36f9c88b2a2a48e /plugins/plugin.py
parent05437dd62d6c19614bf57700a5531ec6f840fcd4 (diff)
added quit, goto_background, return_to_foreground methods to all plugins
Diffstat (limited to 'plugins/plugin.py')
-rw-r--r--plugins/plugin.py22
1 files changed, 22 insertions, 0 deletions
diff --git a/plugins/plugin.py b/plugins/plugin.py
index 366c1bc..0fe836b 100644
--- a/plugins/plugin.py
+++ b/plugins/plugin.py
@@ -28,7 +28,29 @@ class Plugin(gobject.GObject):
gobject.GObject.__init__(self)
def setup(self):
+ """ Setup is called once, when the Turtle Window is created. """
raise RuntimeError("You need to define setup for your plugin.")
+ def start(self):
+ """ start is called when run button is pressed. """
+ raise RuntimeError("You need to define start for your plugin.")
+
def stop(self):
+ """ stop is called when stop button is pressed. """
raise RuntimeError("You need to define stop for your plugin.")
+
+ def goto_background(self):
+ """ goto_background is called when the activity is sent to the
+ background. """
+ raise RuntimeError(
+ "You need to define goto_background for your plugin.")
+
+ def return_to_foreground(self):
+ """ return_to_foreground is called when the activity returns to
+ the foreground. """
+ raise RuntimeError(
+ "You need to define return_to_foreground for your plugin.")
+
+ def quit(self):
+ """ cleanup is called when the activity is exiting. """
+ raise RuntimeError("You need to define quit for your plugin.")