Web   ·   Wiki   ·   Activities   ·   Blog   ·   Lists   ·   Chat   ·   Meeting   ·   Bugs   ·   Git   ·   Translate   ·   Archive   ·   People   ·   Donate
summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorSantiago Collazo <scollazo@activitycentral.com>2013-04-03 00:16:56 (GMT)
committer Santiago Collazo <scollazo@activitycentral.com>2013-04-03 00:16:56 (GMT)
commit147a0f1dee7588dad86c6238652e5be0994d65d1 (patch)
tree22c697e5ff6465050c0dae4cf8cab601344910f6
parent9f746af92c6f2609688fbc7b1bf88f0fa51e7a10 (diff)
Enable welcome activity and disable dcon freeze
-rwxr-xr-xbin/sugar-session15
1 files changed, 15 insertions, 0 deletions
diff --git a/bin/sugar-session b/bin/sugar-session
index d8078a1..dfd81fa 100755
--- a/bin/sugar-session
+++ b/bin/sugar-session
@@ -98,6 +98,18 @@ def cleanup_logs(logs_dir):
dest_path = os.path.join(backup_dir, log)
os.rename(source_path, dest_path)
+def show_welcome_screen():
+ path = os.path.expanduser('~/.welcome_screen')
+ if os.path.exists(path):
+ from jarabe.model import screen
+ screen.set_dcon_freeze(0)
+ welcome_file_flag = open(path, 'r')
+ welcome_file_command = welcome_file_flag.read()
+ welcome_file_flag.close()
+ os.remove(path)
+ if subprocess.call(welcome_file_command.split()):
+ logging.warning('Can not display welcome screen.')
+
def start_ui_service():
from jarabe.view.service import UIService
@@ -461,6 +473,9 @@ def main():
icons_path = os.path.join(config.data_path, 'icons')
Gtk.IconTheme.get_default().append_search_path(icons_path)
+ # OLPC: open welcome screen if booted for the first time
+ show_welcome_screen()
+
if not intro.check_profile():
win = IntroWindow()
win.connect("done", intro_window_done_cb)