Web   ·   Wiki   ·   Activities   ·   Blog   ·   Lists   ·   Chat   ·   Meeting   ·   Bugs   ·   Git   ·   Translate   ·   Archive   ·   People   ·   Donate
summaryrefslogtreecommitdiffstats
path: root/bin/sugar-activity
diff options
context:
space:
mode:
authorTomeu Vizoso <tomeu@tomeuvizoso.net>2007-12-19 19:03:25 (GMT)
committer Tomeu Vizoso <tomeu@tomeuvizoso.net>2007-12-19 19:03:25 (GMT)
commitb7e0ccbf81a7eb503bf8521d7896622920a1aeb4 (patch)
tree7fff62eea1faf915b14c03a64baabf7ec9247c6f /bin/sugar-activity
parentc14abfb022e505607e8882f3203b02b69d14b135 (diff)
#5512 import the activity module later.
Diffstat (limited to 'bin/sugar-activity')
-rwxr-xr-xbin/sugar-activity22
1 files changed, 11 insertions, 11 deletions
diff --git a/bin/sugar-activity b/bin/sugar-activity
index 2e10922..c01b263 100755
--- a/bin/sugar-activity
+++ b/bin/sugar-activity
@@ -94,6 +94,17 @@ if len(args) == 0:
bundle_path = os.environ['SUGAR_BUNDLE_PATH']
sys.path.append(bundle_path)
+bundle = ActivityBundle(bundle_path)
+
+os.environ['SUGAR_BUNDLE_ID'] = bundle.get_bundle_id()
+os.environ['SUGAR_BUNDLE_NAME'] = bundle.get_name()
+
+gtk.icon_theme_get_default().append_search_path(bundle.get_icons_path())
+
+gettext.bindtextdomain(bundle.get_bundle_id(),
+ bundle.get_locale_path())
+gettext.textdomain(bundle.get_bundle_id())
+
splitted_module = args[0].rsplit('.', 1)
module_name = splitted_module[0]
class_name = splitted_module[1]
@@ -133,17 +144,6 @@ if options.single_process is True:
if hasattr(module, 'start'):
module.start()
-bundle = ActivityBundle(bundle_path)
-
-os.environ['SUGAR_BUNDLE_ID'] = bundle.get_bundle_id()
-os.environ['SUGAR_BUNDLE_NAME'] = bundle.get_name()
-
-gettext.bindtextdomain(bundle.get_bundle_id(),
- bundle.get_locale_path())
-gettext.textdomain(bundle.get_bundle_id())
-
-gtk.icon_theme_get_default().append_search_path(bundle.get_icons_path())
-
create_activity_instance(constructor, handle)
gtk.main()