Ejemplo n.º 1
0
    def __init__(self):
        super(KNotifyNotifier, self).__init__()

        self.__factory = None
        try:
            import pcop
            import pydcop
        except ImportError:
            pass
        else:
            if pydcop.anyAppCalled('knotify') is not None:
                self.__factory = pydcop.anyAppCalled
Ejemplo n.º 2
0
    def __init__(self):
        super(KNotifyNotifier, self).__init__()

        self.__factory = None
        try:
            import pcop
            import pydcop
        except ImportError:
            pass
        else:
            if pydcop.anyAppCalled('knotify') is not None:
                self.__factory = pydcop.anyAppCalled
Ejemplo n.º 3
0
 def connect(self, screenlet_settings):
     self.playerAPI = pydcop.anyAppCalled("amarok").player
     self.playerAPI2 = pydcop.anyAppCalled(
         "amarok").MainApplication - Interface
Ejemplo n.º 4
0
 def is_active(self, dbus_iface, screenlet_settings):
     app = pydcop.anyAppCalled("amarok")
     if not app: return False
     else: return True
Ejemplo n.º 5
0
 def __init__(self):
     import pydcop
     self._wait_start = None
     #FIXME: The following line will probably break things if I have to restart kdesktop.
     self._kdesktop = pydcop.anyAppCalled('kdesktop')
     self._tid = None
Ejemplo n.º 6
0
TODO:
- Merge this with another idea of mine and whip up a nice GUI for it.
"""

__appname__ = "KDE GUI Fixes"
__author__ = "Stephan Sokolow (deitarion/SSokolow)"
__version__ = "0.1alpha1"
__license__ = "GNU GPL 2.0 or newer"

import pygtk
pygtk.require('2.0')
import gtk, gobject, logging

import time, pydcop
kwin = pydcop.anyAppCalled('kwin')

SCROLL_ACTIONS = {
    gtk.gdk.SCROLL_DOWN: lambda w, e: kwin.KWinInterface.nextDesktop(),
    gtk.gdk.SCROLL_UP: lambda w, e: kwin.KWinInterface.previousDesktop()
}

BUTTON_ACTIONS = {
    1:
    lambda w, e: pydcop.anyAppCalled('kdesktop').KDesktopIface.
    popupExecuteCommand(),
    2:
    lambda w, e: pydcop.anyAppCalled('kicker').kicker.toggleShowDesktop(),
    3:
    lambda w, e: pydcop.anyAppCalled('kicker').kicker.popupKMenu(
        tuple(int(x) for x in e.get_root_coords()))
Ejemplo n.º 7
0
	def __init__( self, passed_config ):
		global config
		self.amarokapp = pydcop.anyAppCalled( "amarok" )
		self.db = MySQLdb.connect( host = "localhost", user = "******", db = "amarok", passwd = "amarok" )
		config = passed_config
Ejemplo n.º 8
0
 def __init__(self):
     import pydcop
     self._wait_start = None
     #FIXME: The following line will probably break things if I have to restart kdesktop.
     self._kdesktop = pydcop.anyAppCalled('kdesktop')
     self._tid = None
Ejemplo n.º 9
0
TODO:
- Merge this with another idea of mine and whip up a nice GUI for it.
"""

__appname__ = "KDE GUI Fixes"
__author__  = "Stephan Sokolow (deitarion/SSokolow)"
__version__ = "0.1alpha1"
__license__ = "GNU GPL 2.0 or newer"

import pygtk
pygtk.require('2.0')
import gtk, gobject, logging

import time, pydcop
kwin = pydcop.anyAppCalled('kwin')

SCROLL_ACTIONS = {
    gtk.gdk.SCROLL_DOWN   : lambda w,e : kwin.KWinInterface.nextDesktop(),
    gtk.gdk.SCROLL_UP : lambda w,e : kwin.KWinInterface.previousDesktop()
}

BUTTON_ACTIONS = {
    1 : lambda w,e : pydcop.anyAppCalled('kdesktop').KDesktopIface.popupExecuteCommand(),
    2 : lambda w,e : pydcop.anyAppCalled('kicker').kicker.toggleShowDesktop(),
    3 : lambda w,e : pydcop.anyAppCalled('kicker').kicker.popupKMenu(tuple(int(x) for x in e.get_root_coords()))
}

ACTIVE_CORNERS = (gtk.gdk.GRAVITY_NORTH_WEST, gtk.gdk.GRAVITY_NORTH_EAST,
                  gtk.gdk.GRAVITY_SOUTH_WEST, gtk.gdk.GRAVITY_SOUTH_EAST)
Ejemplo n.º 10
0
def init():
    return pydcop.anyAppCalled("amarok")
Ejemplo n.º 11
0
	def connect(self, screenlet_settings):
		self.playerAPI = pydcop.anyAppCalled("amarok").player
		self.playerAPI2 = pydcop.anyAppCalled("amarok").MainApplication-Interface
Ejemplo n.º 12
0
	def is_active(self, dbus_iface, screenlet_settings):
		app = pydcop.anyAppCalled("amarok")
		if not app: return False
		else: return True