ppc cocoa
original commit: 2cebc60eca44c78a441f89a825dd1eb3d60db7d7
This commit is contained in:
parent
0b65316bdf
commit
31a364e892
|
@ -564,10 +564,17 @@
|
||||||
[(scroller val)
|
[(scroller val)
|
||||||
(when scroller
|
(when scroller
|
||||||
(set-scroller-page! scroller val)
|
(set-scroller-page! scroller val)
|
||||||
(tellv (scroller-cocoa scroller) setKnobProportion:
|
(let ([proportion
|
||||||
#:type _CGFloat (max (min 1.0 (/ val
|
(max (min 1.0 (/ val
|
||||||
(+ val (exact->inexact (scroller-range scroller)))))
|
(+ val (exact->inexact (scroller-range scroller)))))
|
||||||
0.0)))]
|
0.0)])
|
||||||
|
(if old-cocoa?
|
||||||
|
(tellv (scroller-cocoa scroller)
|
||||||
|
setFloatValue: #:type _float (tell #:type _float (scroller-cocoa scroller)
|
||||||
|
floatValue)
|
||||||
|
knobProportion: #:type _CGFloat proportion)
|
||||||
|
(tellv (scroller-cocoa scroller) setKnobProportion:
|
||||||
|
#:type _CGFloat proportion))))]
|
||||||
[(scroller)
|
[(scroller)
|
||||||
(if scroller
|
(if scroller
|
||||||
(scroller-page scroller)
|
(scroller-page scroller)
|
||||||
|
|
|
@ -18,7 +18,8 @@
|
||||||
with-autorelease
|
with-autorelease
|
||||||
clean-menu-label
|
clean-menu-label
|
||||||
->wxb
|
->wxb
|
||||||
->wx)
|
->wx
|
||||||
|
old-cocoa?)
|
||||||
|
|
||||||
(define cocoa-lib (ffi-lib (format "/System/Library/Frameworks/Cocoa.framework/Cocoa")))
|
(define cocoa-lib (ffi-lib (format "/System/Library/Frameworks/Cocoa.framework/Cocoa")))
|
||||||
(define cf-lib (ffi-lib (format "/System/Library/Frameworks/CoreFoundation.framework/CoreFoundation")))
|
(define cf-lib (ffi-lib (format "/System/Library/Frameworks/CoreFoundation.framework/CoreFoundation")))
|
||||||
|
@ -69,3 +70,7 @@
|
||||||
(define (->wx wxb)
|
(define (->wx wxb)
|
||||||
(and wxb
|
(and wxb
|
||||||
(weak-box-value wxb)))
|
(weak-box-value wxb)))
|
||||||
|
|
||||||
|
;; FIXME: need a better test:
|
||||||
|
(define old-cocoa? (equal? (path->string (system-library-subpath #f))
|
||||||
|
"ppc-macosx"))
|
||||||
|
|
Loading…
Reference in New Issue
Block a user