mirror of
https://github.com/stumpwm/stumpwm-contrib.git
synced 2026-09-10 07:26:25 -04:00
fix stack exhaustion error
This commit is contained in:
parent
a9a26a327d
commit
f04a78c879
|
|
@ -11,18 +11,12 @@
|
|||
(defun resize-px (target current-px)
|
||||
(- target current-px))
|
||||
|
||||
(defun balance-current-group ()
|
||||
(stumpwm::balance-frames-internal (stumpwm:current-group)
|
||||
(list (stumpwm::tile-group-frame-head
|
||||
(stumpwm:current-group)
|
||||
(stumpwm:current-head)))))
|
||||
|
||||
(defun resize-to-golden-ratio (to-frame from-frame)
|
||||
(when (and *golden-ratio-on* (not (stumpwm::single-frame-p)))
|
||||
(let* ((target-x (target-px (stumpwm::head-width (stumpwm:current-head))))
|
||||
(target-y (target-px (stumpwm::head-height (stumpwm:current-head)))))
|
||||
(setq *golden-ratio-on* nil)
|
||||
(balance-current-group)
|
||||
(stumpwm:balance-frames)
|
||||
(stumpwm:resize (resize-px target-x
|
||||
(stumpwm::frame-width to-frame))
|
||||
(resize-px target-y
|
||||
|
|
|
|||
Loading…
Reference in a new issue