summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--ChangeLog7
-rw-r--r--src/events.c6
2 files changed, 10 insertions, 3 deletions
diff --git a/ChangeLog b/ChangeLog
index 6313b4c..cbd0dfb 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,10 @@
+2004-10-05 Shawn Betts <katia_dilkina@verizon.net>
+
+ * src/events.c (property_notify): pass the root window to
+ receive_command.
+ (receive_command): take a root window as an argument and use it to
+ listen for the command.
+
2004-10-04 Shawn Betts <katia_dilkina@verizon.net>
* src/screen.h (is_a_root_window): new prototype
diff --git a/src/events.c b/src/events.c
index 220e7df..8005a26 100644
--- a/src/events.c
+++ b/src/events.c
@@ -483,7 +483,7 @@ execute_remote_command (Window w)
RP_COMMAND Atom. receive_command reads the list of Windows and
executes their associated command. */
static void
-receive_command ()
+receive_command (Window root)
{
char *result;
Atom type_ret;
@@ -505,7 +505,7 @@ receive_command ()
Window w;
length = sizeof (Window) / 4 + (sizeof (Window) % 4 ?1:0);
- ret = XGetWindowProperty (dpy, DefaultRootWindow (dpy),
+ ret = XGetWindowProperty (dpy, root,
rp_command_request,
offset, length,
True, XA_WINDOW, &type_ret, &format_ret,
@@ -565,7 +565,7 @@ property_notify (XEvent *ev)
&& ev->xproperty.state == PropertyNewValue)
{
PRINT_DEBUG (("ratpoison command\n"));
- receive_command();
+ receive_command(ev->xproperty.window);
}
win = find_window (ev->xproperty.window);