diff options
author | Daniel Narvaez <dwnarvaez@gmail.com> | 2013-01-29 11:05:17 (GMT) |
---|---|---|
committer | Daniel Narvaez <dwnarvaez@gmail.com> | 2013-01-29 11:05:17 (GMT) |
commit | f6aba355c4709bad6c000757bc94c31475bc4ee2 (patch) | |
tree | 8e0f10d9c85ecff6d04f86e53eb359504fc543df /src/jarabe | |
parent | 298d03956f998c7295417589c4e2d275eb47f3db (diff) |
Start sugar-http-serverhtml
Diffstat (limited to 'src/jarabe')
-rwxr-xr-x | src/jarabe/main.py | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/src/jarabe/main.py b/src/jarabe/main.py index 44880ba..8544f28 100755 --- a/src/jarabe/main.py +++ b/src/jarabe/main.py @@ -72,6 +72,7 @@ from jarabe.view.service import UIService _metacity_process = None _window_manager_started = False _starting_desktop = False +_http_server_process = None def unfreeze_dcon_cb(): @@ -235,6 +236,13 @@ def _start_intro(): window.connect('done', __intro_window_done_cb) window.show_all() +def _start_http_server(): + global _http_server_process + _http_server_process = subprocess.Popen(["sugar-http-server"]) + +def _stop_http_server(): + global _http_server_process + _http_server_process.terminate() def main(): GLib.threads_init() @@ -265,11 +273,14 @@ def main(): else: _begin_desktop_startup() + _start_http_server() + try: Gtk.main() except KeyboardInterrupt: print 'Ctrl+C pressed, exiting...' + _stop_http_server() _stop_window_manager() main() |