mirror of
https://github.com/carlrobertoh/ProxyAI.git
synced 2026-05-10 20:30:24 +00:00
fix: use the proper callback for text area autofocus
This commit is contained in:
parent
71aee5f6aa
commit
efe0f0b74a
1 changed files with 4 additions and 4 deletions
|
|
@ -1,15 +1,15 @@
|
|||
package ee.carlrobert.codegpt.toolwindow;
|
||||
|
||||
import com.intellij.openapi.project.Project
|
||||
import com.intellij.openapi.wm.ToolWindowManager
|
||||
import com.intellij.openapi.wm.ToolWindow
|
||||
import com.intellij.openapi.wm.ex.ToolWindowManagerListener
|
||||
import ee.carlrobert.codegpt.toolwindow.chat.standard.StandardChatToolWindowContentManager
|
||||
|
||||
class ChatToolWindowListener : ToolWindowManagerListener {
|
||||
|
||||
override fun stateChanged(toolWindowManager: ToolWindowManager) {
|
||||
toolWindowManager.getToolWindow("CodeGPT")?.run {
|
||||
if (isVisible) requestFocusForTextArea(project)
|
||||
override fun toolWindowShown(toolWindow: ToolWindow) {
|
||||
if ("CodeGPT" == toolWindow.id) {
|
||||
requestFocusForTextArea(toolWindow.project)
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue