Example #1
0
    def __init__(self):
        self._color = profile.get_color()
        TrayIcon.__init__(self, icon_name=_ICON_NAME, xo_color=self._color)
        self.set_palette_invoker(FrameWidgetInvoker(self))
        self.palette_invoker.props.toggle_palette = True

        self._manager = speech.get_speech_manager()
Example #2
0
    def __init__(self):
        self._color = profile.get_color()
        TrayIcon.__init__(self, icon_name=_ICON_NAME, xo_color=self._color)
        self.set_palette_invoker(FrameWidgetInvoker(self))
        self.palette_invoker.props.toggle_palette = True

        self._manager = speech.get_speech_manager()
Example #3
0
    def __init__(self):
        client = GConf.Client.get_default()
        self._color = XoColor(client.get_string('/desktop/sugar/user/color'))
        TrayIcon.__init__(self, icon_name=_ICON_NAME, xo_color=self._color)
        self.set_palette_invoker(FrameWidgetInvoker(self))
        self.palette_invoker.props.toggle_palette = True

        self._manager = speech.get_speech_manager()
Example #4
0
 def __init__(self):
     client = gconf.client_get_default()
     self._color = XoColor(client.get_string('/desktop/sugar/user/color'))
     TrayIcon.__init__(self, icon_name=_ICON_NAME, xo_color=self._color)
     self.set_palette_invoker(FrameWidgetInvoker(self))
     self._manager = speech.get_speech_manager()
     self._icon_widget.connect('button-release-event',
                               self.__button_release_event_cb)
Example #5
0
def handle_key_press(key):
    manager = speech.get_speech_manager()
    if manager.is_paused:
        manager.restart()
    elif not manager.is_playing:
        manager.say_selected_text()
    else:
        manager.pause()
Example #6
0
    def __init__(self):
        client = GConf.Client.get_default()
        self._color = XoColor(client.get_string('/desktop/sugar/user/color'))
        TrayIcon.__init__(self, icon_name=_ICON_NAME, xo_color=self._color)
        self.set_palette_invoker(FrameWidgetInvoker(self))
        self.palette_invoker.props.toggle_palette = True

        self._manager = speech.get_speech_manager()
Example #7
0
def setup(tray):
    if speech.get_speech_manager() is not None:
        tray.add_device(SpeechDeviceView())
Example #8
0
def setup(tray):
    if speech.get_speech_manager() is not None:
        tray.add_device(SpeechDeviceView())
Example #9
0
 def test_speech_manager(self):
     try:
         manager = speech.get_speech_manager()
         self.assertIsNotNone(manager)
     except:
         self.fail("speech manager could not be created")