avoid calling client->screen with numbers out of its domain

related to PR 13292
This commit is contained in:
Robby Findler 2012-11-23 15:40:34 -06:00
parent 9f5324b754
commit 3a04bed479

View File

@ -1216,7 +1216,7 @@ If the namespace does not, they are colored the unbound color.
(loop (send (send admin get-snip) get-editor)) (loop (send (send admin get-snip) get-editor))
#f)]))) #f)])))
(cond (cond
[window [(and window (< -10000 x-off 10000) (< -10000 y-off 10000))
(define (c n) (inexact->exact (round n))) (define (c n) (inexact->exact (round n)))
(define-values (gx gy) (send window client->screen (c x-off) (c y-off))) (define-values (gx gy) (send window client->screen (c x-off) (c y-off)))
(values gx gy gx gy)] (values gx gy gx gy)]