summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--starling/gui.scm4
1 files changed, 3 insertions, 1 deletions
diff --git a/starling/gui.scm b/starling/gui.scm
index f00c329..256cfd7 100644
--- a/starling/gui.scm
+++ b/starling/gui.scm
@@ -300,7 +300,9 @@
(keyboard-focus #:accessor keyboard-focus #:init-value #f))
(define-method (pick-widget (scene <gui-scene>) p)
- (pick scene p (lambda (node) (is-a? node <widget>))))
+ (pick scene p (lambda (node)
+ (and (visible? node)
+ (is-a? node <widget>)))))
(define-method (on-mouse-move (scene <gui-scene>) x y x-rel y-rel buttons)
(let ((focused (mouse-focus scene))