Skip to content

Commit

Permalink
fix: bring back HotSwapUI wrapper (#129)
Browse files Browse the repository at this point in the history
Fixes #128
  • Loading branch information
MarcinVaadin authored Oct 23, 2024
1 parent fa60159 commit 74a7e6f
Showing 1 changed file with 2 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@ package com.vaadin.plugin.actions
import com.intellij.debugger.DebuggerManagerEx
import com.intellij.debugger.ui.HotSwapUI
import com.intellij.ide.actionsOnSave.impl.ActionsOnSaveFileDocumentManagerListener
import com.intellij.openapi.application.WriteIntentReadAction
import com.intellij.openapi.diagnostic.Logger
import com.intellij.openapi.editor.Document
import com.intellij.openapi.fileEditor.FileDocumentManager
Expand Down Expand Up @@ -42,7 +43,7 @@ class VaadinCompileOnSaveAction : ActionsOnSaveFileDocumentManagerListener.Actio
val session = DebuggerManagerEx.getInstanceEx(project).context.debuggerSession
if (session != null) {
LOG.info("${vfsFile.name} compiling...")
HotSwapUI.getInstance(project).compileAndReload(session, vfsFile)
WriteIntentReadAction.run { HotSwapUI.getInstance(project).compileAndReload(session, vfsFile) }
}
}
}
Expand Down

0 comments on commit 74a7e6f

Please sign in to comment.