diff options
author | Marco Pesenti Gritti <marco@localhost.localdomain> | 2006-10-16 11:34:43 (GMT) |
---|---|---|
committer | Marco Pesenti Gritti <marco@localhost.localdomain> | 2006-10-16 11:34:43 (GMT) |
commit | bc0ee6d34c963de81f65d3319e99be0b1e13effc (patch) | |
tree | a0bc604b07fda04db0c8b5161b650a4e71a6de0d /shell/model | |
parent | a3be4492b2c910bd78ced7daf3208f69d0862005 (diff) |
Refactor startup. In progress, give me a couple hours.
For now start sugar with "sugar-emulator shell/sugar-shell"
Diffstat (limited to 'shell/model')
-rw-r--r-- | shell/model/Owner.py | 12 |
1 files changed, 5 insertions, 7 deletions
diff --git a/shell/model/Owner.py b/shell/model/Owner.py index 0382e3c..7d83ab2 100644 --- a/shell/model/Owner.py +++ b/shell/model/Owner.py @@ -18,15 +18,15 @@ import os import random import base64 import time +import logging +import dbus -import conf from sugar import env -import logging +from sugar import profile from sugar.p2p import Stream from sugar.presence import PresenceService from sugar import util from model.Invites import Invites -import dbus PRESENCE_SERVICE_TYPE = "_presence_olpc._tcp" @@ -35,10 +35,8 @@ class ShellOwner(object): runs in the shell and serves up the buddy icon and other stuff. It's the server portion of the Owner, paired with the client portion in Buddy.py.""" def __init__(self): - profile = conf.get_profile() - self._nick = profile.get_nick_name() - user_dir = profile.get_path() + user_dir = env.get_profile_path() self._icon = None self._icon_hash = "" @@ -71,7 +69,7 @@ class ShellOwner(object): def announce(self): # Create and announce our presence - color = conf.get_profile().get_color() + color = profile.get_color() props = {'color': color.to_string(), 'icon-hash': self._icon_hash} self._service = self._pservice.register_service(self._nick, PRESENCE_SERVICE_TYPE, properties=props) |