Web   ·   Wiki   ·   Activities   ·   Blog   ·   Lists   ·   Chat   ·   Meeting   ·   Bugs   ·   Git   ·   Translate   ·   Archive   ·   People   ·   Donate
summaryrefslogtreecommitdiffstats
path: root/activity.py
diff options
context:
space:
mode:
authorC. Scott Ananian <cscott@laptop.org>2007-12-28 05:18:54 (GMT)
committer C. Scott Ananian <cscott@laptop.org>2008-05-20 19:11:39 (GMT)
commitd18279cec039b7d1c6fcbe381fda5f7093169d11 (patch)
treea5a64bc07bf08e2b962457a5007c4265257937e3 /activity.py
parent44f12314acd67182c23feae9a7d1b76b2fcb08b8 (diff)
Really hide keep/share buttons in generated activities.
The Widget.show_all() method will re-show buttons we've hidden, unless we hide *after* the show_all() (we could also use Widget.show() instead of Widget.show_all()).
Diffstat (limited to 'activity.py')
-rw-r--r--activity.py11
1 files changed, 5 insertions, 6 deletions
diff --git a/activity.py b/activity.py
index fca1a90..5c57842 100644
--- a/activity.py
+++ b/activity.py
@@ -53,10 +53,7 @@ class VteActivity(ViewSourceActivity):
from gettext import gettext as _
super(VteActivity, self).__init__(handle)
toolbox = activity.ActivityToolbox(self)
- # we don't support share/keep (yet?)
toolbar = toolbox.get_activity_toolbar()
- toolbar.share.hide() # this should share bundle.
- toolbar.keep.hide()
self.set_toolbox(toolbox)
toolbox.show()
@@ -94,6 +91,8 @@ class VteActivity(ViewSourceActivity):
self.set_canvas(vtebox)
self.show_all()
# hide the buttons we don't use.
+ toolbar.share.hide() # this should share bundle.
+ toolbar.keep.hide()
edittoolbar.undo.hide()
edittoolbar.redo.hide()
edittoolbar.separator.hide()
@@ -143,10 +142,7 @@ class PyGameActivity(ViewSourceActivity):
super(PyGameActivity, self).__init__(handle)
import gobject, gtk, os
toolbox = activity.ActivityToolbox(self)
- # we don't support share/keep (yet?)
toolbar = toolbox.get_activity_toolbar()
- toolbar.share.hide() # this should share bundle.
- toolbar.keep.hide()
self.set_toolbox(toolbox)
toolbox.show()
socket = gtk.Socket()
@@ -157,3 +153,6 @@ class PyGameActivity(ViewSourceActivity):
self.show_all()
socket.grab_focus()
gobject.child_watch_add(self.child_pid, lambda pid, cond: self.close())
+ # hide the buttons we don't use.
+ toolbar.share.hide() # this should share bundle.
+ toolbar.keep.hide()