Skip to content

Commit ffa5c0c

Browse files
authored
Fix stale paint when switching Settings tabs (#21) (#23)
JBCefBrowser was built with setOffScreenRendering true. Under OSR, CEF intermittently fails to invalidate the freed region when a large React subtree is replaced in one commit (e.g. switching out of LogsTab with thousands of buffered entries), leaving the previous tab's pixels visible behind the new one until any other event triggers a repaint. OSR was set in the initial webview scaffolding (7c0511b) with a "TODO move to config" note and no specific need for transparency or custom compositing. Switched to heavyweight rendering.
1 parent f9c09dd commit ffa5c0c

2 files changed

Lines changed: 8 additions & 1 deletion

File tree

CHANGELOG.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,8 @@
22

33
## [Unreleased]
44

5+
- Fix intermittent stale paint when switching Settings tabs (#21) where the previous tab body stayed visible behind the new one. The `JBCefBrowser` was built with `setOffScreenRendering true`; CEF's OSR pipeline occasionally failed to invalidate the freed region when a large React subtree (e.g. `LogsTab`'s up-to-5000-entry buffer) was unmounted and a sibling mounted in the same commit, leaving prior pixels onscreen until the next paint event. Switched to heavyweight rendering.
6+
57
## 0.26.14
68

79
- Fix empty Settings → MCPs tab on tool-window reopen (#22). `webview/ready` now replays the cached MCP roster as `tool/serversUpdated`, and `on-initialized` merges into `:session` instead of clobbering it (notifications that race ahead of `initialized` no longer get wiped).

src/main/clojure/dev/eca/eca_intellij/extension/tool_window.clj

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -183,7 +183,12 @@
183183

184184
(defn ^:private create-webview ^JBCefBrowser [^Project project url]
185185
(let [browser (-> (JBCefBrowser/createBuilder)
186-
(.setOffScreenRendering true) ;; TODO move to config
186+
;; Heavyweight (native) rendering. OSR (true) intermittently fails to
187+
;; invalidate freed regions when a large React subtree is replaced in
188+
;; one commit (e.g. switching Settings tabs while LogsTab holds
189+
;; thousands of entries), leaving the prior tab's pixels visible
190+
;; behind the new one until another event triggers a repaint (#21).
191+
(.setOffScreenRendering false)
187192
(.build))
188193
;; Per-client JS query pool size. We previously bumped this via a
189194
;; global `System.setProperty "ide.browser.jcef.jsQueryPoolSize"` inside

0 commit comments

Comments
 (0)