Clear out Cocoa callbacks on startup
parent
608aab0dcb
commit
aa2c3eaf73
|
@ -1,5 +1,4 @@
|
|||
- fix compiled gc check
|
||||
- 3 >n fep
|
||||
- code walker & exceptions -- test and debug problems
|
||||
- code walker and callbacks is broken?
|
||||
- prettyprinter's highlighting of non-leaves looks bad
|
||||
|
@ -49,10 +48,8 @@
|
|||
- x11 input methods
|
||||
- x11 title bars are funny
|
||||
- cocoa:
|
||||
- need to flush callbacks
|
||||
- don't multiplex in the event loop if there is no pending i/o
|
||||
- horizontal scrolling
|
||||
- zooming doesn't work
|
||||
- window zooming doesn't work
|
||||
- implement handlers for open, quit events, and whatever else
|
||||
- polish OS X menu bar code
|
||||
- when scrolling wheel, or moving mouse out of window, rollover is not
|
||||
|
|
|
@ -6,7 +6,10 @@ USING: hashtables kernel namespaces objc objc-NSObject ;
|
|||
|
||||
SYMBOL: callbacks
|
||||
|
||||
H{ } clone callbacks set-global
|
||||
: reset-callbacks ( -- )
|
||||
H{ } clone callbacks set-global ;
|
||||
|
||||
reset-callbacks
|
||||
|
||||
"NSObject" "FactorCallback" {
|
||||
{ "perform:" "void" { "id" "SEL" "id" }
|
||||
|
|
|
@ -18,12 +18,9 @@ IN: gadgets-cocoa
|
|||
! Hash mapping aliens to gadgets
|
||||
SYMBOL: views
|
||||
|
||||
H{ } clone views set-global
|
||||
: reset-views ( hash -- hash ) H{ } clone views set-global ;
|
||||
|
||||
: purge-views ( hash -- hash )
|
||||
global [
|
||||
views [ [ drop expired? not ] hash-subset ] change
|
||||
] bind ;
|
||||
reset-views
|
||||
|
||||
: view ( handle -- world ) views get hash ;
|
||||
|
||||
|
@ -237,8 +234,9 @@ IN: shells
|
|||
] unless
|
||||
[
|
||||
[
|
||||
reset-views
|
||||
reset-callbacks
|
||||
init-ui
|
||||
purge-views
|
||||
default-main-menu
|
||||
listener-window
|
||||
finish-launching
|
||||
|
|
Loading…
Reference in New Issue