Bootstrap fix, stop event loop after all windows closed, start UI by default if $DISPLAY is set
parent
3f4907c304
commit
7570b189cf
|
|
@ -46,8 +46,10 @@ GENERIC: client-event ( event window -- )
|
|||
} cond ;
|
||||
|
||||
: event-loop ( -- )
|
||||
windows get hash-empty? [
|
||||
wait-event dup XAnyEvent-window windows get hash dup
|
||||
[ handle-event ] [ 2drop ] if event-loop ;
|
||||
[ handle-event ] [ 2drop ] if event-loop
|
||||
] unless ;
|
||||
|
||||
: char-array>string ( n <char-array> -- string )
|
||||
swap >string [ swap char-nth ] map-with ;
|
||||
|
|
|
|||
|
|
@ -8,8 +8,8 @@ USING: kernel parser words compiler sequences ;
|
|||
"/library/x11/constants.factor"
|
||||
"/library/x11/utilities.factor"
|
||||
"/library/x11/events.factor"
|
||||
"/library/x11/windows.factor"
|
||||
"/library/x11/glx-utils.factor"
|
||||
"/library/x11/windows.factor"
|
||||
"/library/x11/ui.factor"
|
||||
} [ run-resource ] each
|
||||
|
||||
|
|
|
|||
|
|
@ -121,4 +121,4 @@ IN: shells
|
|||
|
||||
IN: kernel
|
||||
|
||||
! : default-shell "DISPLAY" os-env empty? "tty" "ui" ? ;
|
||||
: default-shell "DISPLAY" os-env empty? "tty" "ui" ? ;
|
||||
|
|
|
|||
Loading…
Reference in New Issue