awful: split D-Bus name from awesome
awful uses its own namespace in D-Bus Signed-off-by: Julien Danjou <julien@danjou.info>
This commit is contained in:
parent
88be323e4a
commit
cbff5fe9dd
|
@ -0,0 +1,17 @@
|
||||||
|
---------------------------------------------------------------------------
|
||||||
|
-- @author Julien Danjou <julien@danjou.info>
|
||||||
|
-- @copyright 2009 Julien Danjou
|
||||||
|
-- @release @AWESOME_VERSION@
|
||||||
|
---------------------------------------------------------------------------
|
||||||
|
|
||||||
|
-- Grab environment we need
|
||||||
|
local dbus = dbus
|
||||||
|
|
||||||
|
--- D-Bus module for awful
|
||||||
|
module("awful.dbus")
|
||||||
|
|
||||||
|
if dbus then
|
||||||
|
dbus.request_name("session", "org.naquadah.awesome.awful")
|
||||||
|
end
|
||||||
|
|
||||||
|
-- vim: filetype=lua:expandtab:shiftwidth=4:tabstop=8:softtabstop=4:encoding=utf-8:textwidth=80
|
|
@ -5,6 +5,7 @@
|
||||||
---------------------------------------------------------------------------
|
---------------------------------------------------------------------------
|
||||||
|
|
||||||
-- Grab environment we need
|
-- Grab environment we need
|
||||||
|
require("awful.dbus")
|
||||||
local hooks = require("awful.hooks")
|
local hooks = require("awful.hooks")
|
||||||
local loadstring = loadstring
|
local loadstring = loadstring
|
||||||
local tostring = tostring
|
local tostring = tostring
|
||||||
|
@ -17,9 +18,8 @@ local type = type
|
||||||
--- Remote control module for awful
|
--- Remote control module for awful
|
||||||
module("awful.remote")
|
module("awful.remote")
|
||||||
|
|
||||||
if hooks.dbus then
|
if dbus then
|
||||||
dbus.request_name("session", "org.naquadah.awesome")
|
hooks.dbus.register("org.naquadah.awesome.awful.Remote", function(data, code)
|
||||||
hooks.dbus.register("org.naquadah.awesome.Remote", function(data, code)
|
|
||||||
if data.member == "Eval" then
|
if data.member == "Eval" then
|
||||||
local f, e = loadstring(code)
|
local f, e = loadstring(code)
|
||||||
if f then
|
if f then
|
||||||
|
|
|
@ -31,9 +31,9 @@ then
|
||||||
exit 1
|
exit 1
|
||||||
fi
|
fi
|
||||||
|
|
||||||
DBUS_METHOD=org.naquadah.awesome.Remote.Eval
|
|
||||||
DBUS_PATH=/
|
DBUS_PATH=/
|
||||||
DBUS_DEST=org.naquadah.awesome
|
DBUS_DEST=org.naquadah.awesome.awful
|
||||||
|
DBUS_METHOD=${DBUS_DEST}.Remote.Eval
|
||||||
|
|
||||||
a_dbus_send()
|
a_dbus_send()
|
||||||
{
|
{
|
||||||
|
|
Loading…
Reference in New Issue