-
Notifications
You must be signed in to change notification settings - Fork 143
creating DE specific extensions
Chad Colgur edited this page May 12, 2013
·
3 revisions
Firstly you need to have read and understood the api specification.
All DE specific items should be added to everpad/specific/DENAME, as example for unity is everpad/specific/unity. Everpad support launchers and executable services as extensions.
- Create launcher.py in everpad/specific/DENAME.
- Create your launcher class, by default we pass app uri, session bus and service path to launcher constructor. And application run launcher update update method and pass dict to it:
{
'progresss': float beetwen 0 and 1,
'progress-visible': bool,
}
Launcher for unity as example:
class UnityLauncher(dbus.service.Object):
def __init__(self, app_uri, *args, **kwargs):
self.app_uri = app_uri
self.data = {}
dbus.service.Object.__init__(self, *args, **kwargs)
def update(self, data):
self.data = data
self.Update(self.app_uri, data)
@dbus.service.signal(
dbus_interface='com.canonical.Unity.LauncherEntry',
signature=("sa{sv}")
)
def Update(self, app_uri, properties):
return
@dbus.service.method(
dbus_interface='com.canonical.Unity.LauncherEntry',
in_signature="", out_signature="sa{sv}",
)
def Query(self):
return self.app_uri, self.data
- You can add you launcher to launchers dict, like
'ubuntu': UnityLauncher
. As dict key you need to use $DESKTOP_SESSION variable.
- Create your service in everpad/specific/DENAME, as an example you can see unity lens and kde runner
- Add it to setup.py entry_points section.
- Put additional files in data/ and add them to setup.py.