;; Use the menus (and bind window and icon behaviors) 
(set! window-behavior 
  (make-behavior
   (on-event (button 1 any)
             raise-lower-move-window
             :steal (check-modifiers modifiers))
   (on-event (button 3 any)
             (lambda (deco event) (menu-pop (window-pop) deco event))
             :steal (check-modifiers modifiers))
   ))

(set! icon-behavior 
  (make-behavior
   (on-event (button 1 any)
             iconify-move-window)
   (on-event (button 3 any)
             (lambda (deco event) (menu-pop (window-pop) deco event)))
   ))

(set! screen-behavior 
  (make-behavior
   (on (button 1 any)
       (menu-pop (command-pop) deco event))
   (on (button 1 shift-mask)
       (menu-pop (login-pop) deco event))
   (on (button 3 shift-mask)
       (menu-pop (make-windows-popup "Windows") deco event))
   (on (button 3 any)
       (menu-pop (root-pop) deco event))
   (on (keypress "e" (logior alt-mask control-mask))
       (execute "xfrun4"))
   (on (keypress "r" (logior alt-mask control-mask))
       (execute "rox"))))
