mirror of
https://github.com/doomemacs/doomemacs
synced 2025-08-01 12:17:25 -05:00
feat(calendar): only initialize calfw if necessary
If the *calendar* workspace is already populated with calfw buffers, there is no reason to re-initialize calfw.
This commit is contained in:
committed by
Henrik Lissner
parent
9d14d093c0
commit
31a6fa77d0
@ -18,8 +18,12 @@
|
||||
(if (modulep! :ui workspaces)
|
||||
(progn
|
||||
(+workspace-switch +calendar-workspace-name t)
|
||||
(doom/switch-to-scratch-buffer)
|
||||
(+calendar--init)
|
||||
(unless (memq (buffer-local-value 'major-mode
|
||||
(window-buffer (selected-window)))
|
||||
'(cfw:details-mode
|
||||
cfw:calendar-mode))
|
||||
(doom/switch-to-scratch-buffer)
|
||||
(+calendar--init))
|
||||
(+workspace/display))
|
||||
(setq +calendar--wconf (current-window-configuration))
|
||||
(delete-other-windows)
|
||||
|
Reference in New Issue
Block a user