2011-09-28 13:16:26 +00:00
|
|
|
// -*- mode: js; js-indent-level: 4; indent-tabs-mode: nil -*-
|
2011-09-06 13:05:40 +00:00
|
|
|
|
2011-11-20 16:52:50 +00:00
|
|
|
const Gio = imports.gi.Gio;
|
2011-09-06 13:05:40 +00:00
|
|
|
|
2011-11-20 16:52:50 +00:00
|
|
|
const ConsoleKitManagerIface = <interface name='org.freedesktop.ConsoleKit.Manager'>
|
|
|
|
<method name='CanRestart'>
|
|
|
|
<arg type='b' direction='out'/>
|
|
|
|
</method>
|
|
|
|
<method name='CanStop'>
|
|
|
|
<arg type='b' direction='out'/>
|
|
|
|
</method>
|
|
|
|
<method name='Restart' />
|
|
|
|
<method name='Stop' />
|
|
|
|
</interface>;
|
2011-09-06 13:05:40 +00:00
|
|
|
|
2011-11-20 16:52:50 +00:00
|
|
|
const ConsoleKitProxy = Gio.DBusProxy.makeProxyWrapper(ConsoleKitManagerIface);
|
2011-09-06 13:05:40 +00:00
|
|
|
|
2011-11-20 16:52:50 +00:00
|
|
|
function ConsoleKitManager() {
|
|
|
|
return new ConsoleKitProxy(Gio.DBus.system,
|
|
|
|
'org.freedesktop.ConsoleKit',
|
|
|
|
'/org/freedesktop/ConsoleKit/Manager');
|
2011-09-06 13:05:40 +00:00
|
|
|
};
|