Web   ·   Wiki   ·   Activities   ·   Blog   ·   Lists   ·   Chat   ·   Meeting   ·   Bugs   ·   Git   ·   Translate   ·   Archive   ·   People   ·   Donate
summaryrefslogtreecommitdiffstats
path: root/src/jarabe/model/sound.py
diff options
context:
space:
mode:
Diffstat (limited to 'src/jarabe/model/sound.py')
-rw-r--r--src/jarabe/model/sound.py12
1 files changed, 6 insertions, 6 deletions
diff --git a/src/jarabe/model/sound.py b/src/jarabe/model/sound.py
index c6cb75f..65090a4 100644
--- a/src/jarabe/model/sound.py
+++ b/src/jarabe/model/sound.py
@@ -14,7 +14,8 @@
# along with this program; if not, write to the Free Software
# Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
-from sugar.profile import get_profile
+import gconf
+
from sugar import env
from sugar import _sugarext
from sugar import dispatch
@@ -46,13 +47,12 @@ def set_muted(new_state):
def save():
if env.is_emulator() is False:
- profile = get_profile()
- profile.sound_volume = get_volume()
- profile.save()
+ client = gconf.client_get_default()
+ client.set_int('/desktop/sugar/sound/volume', get_volume())
def restore():
if env.is_emulator() is False:
- profile = get_profile()
- set_volume(profile.sound_volume)
+ client = gconf.client_get_default()
+ set_volume(client.get_int('/desktop/sugar/sound/volume'))
_volume = _sugarext.VolumeAlsa()