added check for other windowmanagers
This commit is contained in:
parent
84bbfcaec2
commit
0d05a7c0e3
10
src/main.scm
10
src/main.scm
|
@ -5,6 +5,16 @@
|
|||
(let ((dpy (open-display)))
|
||||
(synchronize dpy #t)
|
||||
(init-sync-x-events dpy)
|
||||
;; first try if there is already a window-manager
|
||||
(with-handler
|
||||
(lambda (condition punt)
|
||||
(mdisplay "Another window manager is already running on this screen\nTerminate it before running Orion.\n")
|
||||
(exit))
|
||||
(lambda ()
|
||||
(display-select-input dpy (default-root-window dpy)
|
||||
(event-mask substructure-redirect))
|
||||
(display-sync dpy #f)))
|
||||
|
||||
;; for debugging:
|
||||
; (spawn (lambda ()
|
||||
; (let loop ((se (most-recent-sync-x-event)))
|
||||
|
|
Loading…
Reference in New Issue