cocoa: fix frame coordinate system by using initial menu-bar height

This commit is contained in:
Matthew Flatt 2011-05-09 17:27:19 -06:00
parent d8340c6e2e
commit 2e93e0ec14

View File

@ -83,8 +83,11 @@
(and (<= x (NSPoint-x p) (+ x w)) (and (<= x (NSPoint-x p) (+ x w))
(<= (- y h) (NSPoint-y p) y))))))) (<= (- y h) (NSPoint-y p) y)))))))
(define (get-menu-bar-height)
(define initial-menubar-height
(inexact->exact (floor (tell #:type _CGFloat cocoa-mb menuBarHeight)))) (inexact->exact (floor (tell #:type _CGFloat cocoa-mb menuBarHeight))))
(define (get-menu-bar-height)
initial-menubar-height)
(set-menu-bar-hooks! in-menu-bar-range) (set-menu-bar-hooks! in-menu-bar-range)