aboutsummaryrefslogtreecommitdiff
path: root/docs/design
diff options
context:
space:
mode:
authorCraig Jennings <c@cjennings.net>2026-05-10 03:19:03 -0500
committerCraig Jennings <c@cjennings.net>2026-05-10 03:19:03 -0500
commit96b59b4742843566eaa600252d80a38236e45e84 (patch)
tree245dc034ba82ed0429191decc60039d4913e96dd /docs/design
parent266eb908c1bd06b48eeb0d56afd109aec8c9270c (diff)
downloaddotemacs-96b59b4742843566eaa600252d80a38236e45e84.tar.gz
dotemacs-96b59b4742843566eaa600252d80a38236e45e84.zip
refactor: extract toggle-state helpers shared by F9 and F12
The F12 commit (6075562) flagged this as a follow-up: ~120 lines of capture-state and display-saved logic were duplicated between modules/ai-vterm.el and modules/eshell-vterm-config.el. The only differences were the default direction (right for F9, below for F12) and the customization name for the fallback size. Extract the shared logic into modules/cj-window-toggle.el so both consumers reduce to thin delegates that pass their state-var symbols and defaults. The state vars stay where they were, so existing tests against each consumer's helpers keep working. 10 new tests cover the parameterized helpers in isolation. All consumer tests still pass.
Diffstat (limited to 'docs/design')
0 files changed, 0 insertions, 0 deletions