From 5c39670305846ac2abf3e8b7405e57c7511c32ff Mon Sep 17 00:00:00 2001 From: Raul Gutierrez Segales Date: Mon, 31 Jan 2011 17:23:00 +0000 Subject: Renamed collaboration as tacollaboration to avoid name clash --- (limited to 'TurtleArt') diff --git a/TurtleArt/collaboration.py b/TurtleArt/tacollaboration.py index b76b3c1..3760d15 100644 --- a/TurtleArt/collaboration.py +++ b/TurtleArt/tacollaboration.py @@ -3,9 +3,15 @@ from dbus.service import signal from dbus.gobject_service import ExportedGObject import logging import telepathy -from sugar import profile -from sugar.presence import presenceservice -from sugar.presence.tubeconn import TubeConnection + +try: + from sugar import profile + from sugar.presence import presenceservice + from sugar.presence.tubeconn import TubeConnection +except: + profile = None + from collaboration import presenceservice + from collaboration.tubeconn import TubeConnection SERVICE = 'org.laptop.TurtleArtActivity' IFACE = SERVICE @@ -225,7 +231,11 @@ class Collaboration(): return self._tw.nick def _get_colors(self): - return profile.get_color().to_string() + if profile: + colors = profile.get_color().to_string() + else: + colors = self._activity.get_colors() + return colors class ChatTube(ExportedGObject): -- cgit v0.9.1