Merge pull request #2611 from continuedev/pe/jb-inline-edit-bugfix

bugfix(jb): incorrect scroll logic on inline edit
This commit is contained in:
Patrick Erichsen 2024-10-21 18:26:14 -07:00 • committed by GitHub
commit d9dd54c2d5
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
2 changed files with 8 additions and 3 deletions

View file

@ -0,0 +1,8 @@
<component name="ProjectRunConfigurationManager">
<configuration default="false" name="Run Continue" type="CompoundRunConfigurationType">
<toRun name="Run Extension" type="GradleRunConfiguration" />
<toRun name="GUI: Start Dev Server" type="js.build_tools.npm" />
<toRun name="Tail Dev Logs" type="ShConfigurationType" />
<method v="2" />
</configuration>
</component>

View file

@ -241,9 +241,6 @@ fun openInlineEdit(project: Project?, editor: Editor) {
val viewport = (editor as? EditorImpl)?.scrollPane?.viewport
viewport?.dispatchEvent(ComponentEvent(viewport, ComponentEvent.COMPONENT_RESIZED))
// Scroll to the top of the startLine plus the height of the panel
editor.scrollingModel.scrollVertically(editor.visualLineToY(startLineNumber) - panel.height)
// Add key listener to text area
textArea.addKeyListener(
object : KeyAdapter() {