Web   ·   Wiki   ·   Activities   ·   Blog   ·   Lists   ·   Chat   ·   Meeting   ·   Bugs   ·   Git   ·   Translate   ·   Archive   ·   People   ·   Donate
summaryrefslogtreecommitdiffstats
path: root/bin
diff options
context:
space:
mode:
authorMarco Pesenti Gritti <mpgritti@gmail.com>2008-10-06 00:02:27 (GMT)
committer Marco Pesenti Gritti <mpgritti@gmail.com>2008-10-06 00:02:27 (GMT)
commita757c6040cbff1a48525b8c629a41fd9a73d1270 (patch)
tree89b850b39b1290024470cb64b1ddaf503450deb0 /bin
parent7665848bb8766813a77372cbb24d70ebfcc573de (diff)
Remove the remaining shell view bits and finally kill it.
Diffstat (limited to 'bin')
-rw-r--r--bin/sugar-shell22
1 files changed, 14 insertions, 8 deletions
diff --git a/bin/sugar-shell b/bin/sugar-shell
index acdfa89..ec1b1cb 100644
--- a/bin/sugar-shell
+++ b/bin/sugar-shell
@@ -34,7 +34,6 @@ from sugar.profile import get_profile
from sugar.datastore import datastore
from sugar import env
-from jarabe.view import shell
from jarabe.shellservice import ShellService
from jarabe.intro.window import IntroWindow
from jarabe.intro.window import create_profile
@@ -47,12 +46,11 @@ from jarabe.view import launcher
from jarabe import logsmanager
from jarabe import config
-def _shell_started_cb():
+def _shell_started_cb(home_window):
screen.set_dcon_freeze(0)
if os.path.isfile(os.path.expanduser('~/.sugar-update')):
- home_box = shell.get_instance().home_window.get_home_box()
- home_box.show_software_updates_alert()
+ home_window.get_home_box().show_software_updates_alert()
# Mount the datastore in internal flash
ds_path = env.get_profile_path('datastore')
@@ -68,8 +66,6 @@ def _shell_started_cb():
journalactivity.start()
def main():
- gobject.idle_add(_shell_started_cb)
-
try:
logsmanager.setup()
except Exception, e:
@@ -100,8 +96,16 @@ def main():
if get_profile().timezone is not None:
os.environ['TZ'] = get_profile().timezone
- # TODO: move initializations from the Shell constructor to a start() method
- shell.get_instance()
+ from jarabe.frame import frame
+ frame = frame.get_instance()
+
+ from jarabe.view.keyhandler import KeyHandler
+ key_handler = KeyHandler(frame)
+
+ from jarabe.desktop.homewindow import HomeWindow
+ home_window = HomeWindow()
+ home_window.show()
+
ShellService()
launcher.setup()
@@ -116,6 +120,8 @@ def main():
sound.restore()
+ gobject.idle_add(_shell_started_cb, home_window)
+
try:
gtk.main()
except KeyboardInterrupt: