From f861e3afd07d72850f96836f07b07d66c75bc627 Mon Sep 17 00:00:00 2001 From: Walter Bender Date: Wed, 02 Feb 2011 15:40:15 +0000 Subject: Merge git://git.collabora.co.uk/git/user/rgs/turtleart/ --- diff --git a/TurtleArt/tacollaboration.py b/TurtleArt/tacollaboration.py index 3c35e66..52164e0 100644 --- a/TurtleArt/tacollaboration.py +++ b/TurtleArt/tacollaboration.py @@ -47,6 +47,8 @@ class Collaboration(): _shared_activity is null in _shared_cb()") return + self._tw.set_sharing(True) + self.initiating = True self.waiting_for_turtles = False self.turtle_dictionary = self._get_dictionary() @@ -72,6 +74,8 @@ class Collaboration(): _shared_activity is null in _shared_cb()") return + self._tw.set_sharing(True) + self.initiating = False self.conn = self._shared_activity.telepathy_conn self.tubes_chan = self._shared_activity.telepathy_tubes_chan diff --git a/TurtleArt/tawindow.py b/TurtleArt/tawindow.py index f9c0d4b..ad830d9 100644 --- a/TurtleArt/tawindow.py +++ b/TurtleArt/tawindow.py @@ -100,6 +100,7 @@ class TurtleArtWindow(): def __init__(self, win, path, parent=None, mycolors=None, mynick=None): self._loaded_project = '' self.win = None + self._sharing = False self.parent = parent self.send_event = None # method to send events over the network if type(win) == gtk.DrawingArea: @@ -397,16 +398,11 @@ class TurtleArtWindow(): self.toolbar_shapes[_name].type = 'toolbar' self.toolbar_shapes['stopiton'].hide() - def sharing(self): - """ Is a chattube available for share? """ - if self.running_sugar and hasattr(self.activity, 'chattube') and\ - self.activity.chattube is not None: - return True - - if self.send_event: - return True + def set_sharing(self, shared): + self._sharing = shared - return False + def sharing(self): + return self._sharing def is_project_empty(self): """ Check to see if project has any blocks in use """ -- cgit v0.9.1