From 1b155ec4dc011ed325ec82d44754074e9a40f21a Mon Sep 17 00:00:00 2001 From: flavio Date: Wed, 05 Dec 2012 11:50:54 +0000 Subject: Proper implementation of the path where you obtained the videotape. --- diff --git a/ScreencastActivity.py b/ScreencastActivity.py index 767c505..6b7543b 100644 --- a/ScreencastActivity.py +++ b/ScreencastActivity.py @@ -31,7 +31,7 @@ import sc_gst import os # bundlepath -from sugar.activity.activity import get_bundle_path +from sugar.activity.activity import get_activity_root # datetime for journal entry name import datetime @@ -57,10 +57,11 @@ class ScreencastActivity(activity.Activity): self._ui = sc_ui.ScreencastUserInterface(self) # Set video file - if not os.path.exists(get_bundle_path() + "/data"): - os.makedirs(get_bundle_path() + "/data") + directory = os.path.join(get_activity_root(), "data") + if not os.path.exists(directory): + os.makedir(directory) - self._videofile = os.path.join( get_bundle_path(), "data", "screencast.ogg" ) + self._videofile = os.path.join( directory, "screencast.ogg" ) # Gstreamer interface object self._gst = sc_gst.ScreencastGstreamer(self, self._videofile) -- cgit v0.9.1