fix: improve dock close controls#3
Open
gvanderclay wants to merge 1 commit intoiamironz:mainfrom
Open
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
This started from a couple of rough edges in the dock UI.
Before this change, logcat could be closed with
q, but<Esc>did nothing. Build output had no quick close mapping, so closing it meant leaving the buffer or using a window command. The dock controls window already usedwinfixheight, but the dock body did not, so the output area could still participate in height redistribution when other horizontal splits were opened or equalized.After this change, logcat accepts both
qand<Esc>, and build output gets the same close keys. Dock body windows also getwinfixheightafter they are created, matching the existing controls window behavior and the way Neovim treats quickfix-style bottom panels.Changes
<Esc>handling for the logcat controls.qand<Esc>close mappings for build output.winfixheighton dock body windows after those windows are created.One behavior is intentionally unchanged: build output still closes through
panel.close(). That matches the existing panel/window close path, so this PR hides the build dock but does not cancel or signal the running Gradle job.The new mappings are buffer-local to the plugin dock buffers. If someone has their own
<Esc>mapping forandroid-logorandroid-log-controls, they may need to apply it after the plugin sets its maps.Testing
./scripts/run-tests.shDocs
Checklist