Add a get_xo_color API

This commit is contained in:
Daniel Narvaez 2013-05-01 22:45:30 +02:00 committed by Manuel Quiñones
parent 671ad1ae3e
commit 6c4a9b34a1

View File

@ -19,6 +19,7 @@ import json
import os
from gi.repository import Gtk
from gi.repository import GConf
from gi.repository import WebKit2
from gwebsockets.server import Server
@ -29,6 +30,11 @@ class ActivityAPI:
def __init__(self, activity):
self._activity = activity
def get_xo_color(self):
client = GConf.Client.get_default()
color_string = client.get_string('/desktop/sugar/user/color')
return color_string.split(",")
def close(self):
self._activity.close()