Skip to content

Commit 8bfc78d

Browse files
committed
Revert "fix bug: set the property JS_QUERY_POOL_SIZE to use JBCefJSQuery after the browser has been created"
This reverts commit e998ae8.
1 parent 97e4004 commit 8bfc78d

File tree

1 file changed

+2
-5
lines changed
  • extensions/intellij/src/main/kotlin/com/github/continuedev/continueintellijextension/browser

1 file changed

+2
-5
lines changed

extensions/intellij/src/main/kotlin/com/github/continuedev/continueintellijextension/browser/ContinueBrowser.kt

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -21,14 +21,12 @@ class ContinueBrowser(
2121
): Disposable {
2222

2323
private val log = Logger.getInstance(ContinueBrowser::class.java.simpleName)
24-
private val myJBCefClient: JBCefClient = JBCefApp.getInstance().createClient().apply {
25-
setProperty(JBCefClient.Properties.JS_QUERY_POOL_SIZE, 200)
26-
}
27-
private val browser: JBCefBrowser = JBCefBrowser.createBuilder().setOffScreenRendering(true).setClient(myJBCefClient).build()
24+
private val browser: JBCefBrowser = JBCefBrowser.createBuilder().setOffScreenRendering(true).build()
2825
private val myJSQueryOpenInBrowser = JBCefJSQuery.create(browser as JBCefBrowserBase)
2926

3027
init {
3128
CefApp.getInstance().registerSchemeHandlerFactory("http", "continue", CustomSchemeHandlerFactory())
29+
browser.jbCefClient.setProperty(JBCefClient.Properties.JS_QUERY_POOL_SIZE, 200)
3230
myJSQueryOpenInBrowser.addHandler { msg: String? ->
3331
val json = gsonService.gson.fromJson(msg, BrowserMessage::class.java)
3432
val messageType = json.messageType
@@ -109,7 +107,6 @@ class ContinueBrowser(
109107
override fun dispose() {
110108
Disposer.dispose(myJSQueryOpenInBrowser)
111109
Disposer.dispose(browser)
112-
Disposer.dispose(myJBCefClient)
113110
}
114111

115112
// todo: remove and use types.Message

0 commit comments

Comments
 (0)