>Is there anyway to send an event/atom/whatever to the
>root window to say "hey buddy, someone right-clicked
>on you, handle it" ??

I've done just that by patching bbkeys.  I'm getting the patch ready to 
submit to the bbkeys folks, but here's the basic idea:


I added the following actions to bbkeys:

     MouseUp - move cursor up
     MouseDown - move cursor down
     MouseLeft - move cursor left
     MouseRight - move cursor right

     MouseButton1 - send button 1 click to front window
     MouseButton2 - send button 2 click to front window
     MouseButton3 - send button 3 click to front window

     RootMouseButton1 - send button 1 click to root window
     RootMouseButton2 - send button 1 click to root window
     RootMouseButton3 - send button 1 click to root window


By binding these to sensible keys, I am able to trigger the menu 
(RootMouseButton3 or RootMouseButton2), move the cursor to navigate the 
menu (MouseUp/MouseDown/MouseLeft/MouseRight), then I can select a menu 
item or dismiss the menu (MouseButton1 or MouseButton3).

It works very nicely.  Not as nice as being directly integrated into 
blackbox, but....

The only annoying bit is mouse movement-- particularly how far to move 
the mouse for each keystroke.  I actually made that a parameter in the 
.bbkeysrc file, though it is not very elegant (you cannot currently set 
different movement amounts for different keybindings, so you cannot have 
alt-KP_8 move the mouse up 20 pixels and KP_8 move it up 10 pixels).

Anyway, I'll go put together the patch and then post it here and on the 
bbkeys list.


-Roy

Reply via email to