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:
parent
9d14d093c0
commit
31a6fa77d0
1 changed files with 6 additions and 2 deletions
|
@ -18,8 +18,12 @@
|
|||
(if (modulep! :ui workspaces)
|
||||
(progn
|
||||
(+workspace-switch +calendar-workspace-name t)
|
||||
(unless (memq (buffer-local-value 'major-mode
|
||||
(window-buffer (selected-window)))
|
||||
'(cfw:details-mode
|
||||
cfw:calendar-mode))
|
||||
(doom/switch-to-scratch-buffer)
|
||||
(+calendar--init)
|
||||
(+calendar--init))
|
||||
(+workspace/display))
|
||||
(setq +calendar--wconf (current-window-configuration))
|
||||
(delete-other-windows)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue