Browse Source

Merge pull request #8303 in DESIGN/design from release/11.0 to feature/x

* commit '62c0e0c753d7bce8ce72da61058786f117ad1395':
  v7的构造函数不能走v6的,会一直创建v6的Chromium进程,先搞个构造函数这样处理下..
  CHART-23172 & CHART-23111 v7的jxbrowser没有正确关闭engine
  Revert "CHART-23172 & CHART-23111 只处理没正确关闭engine"
  CHART-23172 & CHART-23111 只处理没正确关闭engine
  Revert "CHART-23172 & CHART-23111 v7的jxbrowser没有正确关闭engine"
  CHART-23172 & CHART-23111 v7的jxbrowser没有正确关闭engine
feature/x
superman 3 years ago
parent
commit
2e8eacf5b4
  1. 4
      designer-base/src/main/java/com/fr/design/ui/ModernUIPane.java
  2. 6
      designer-base/src/main/java/com/fr/design/ui/compatible/NewModernUIPane.java

4
designer-base/src/main/java/com/fr/design/ui/ModernUIPane.java

@ -203,6 +203,10 @@ public class ModernUIPane<T> extends BasicPane {
this.pane = new ModernUIPane<>(browserType);
}
public Builder(ModernUIPane<T> pane) {
this.pane = pane;
}
public Builder<T> prepare(ScriptContextListener contextListener) {
pane.browser.addScriptContextListener(contextListener);
return this;

6
designer-base/src/main/java/com/fr/design/ui/compatible/NewModernUIPane.java

@ -182,7 +182,7 @@ public class NewModernUIPane<T> extends ModernUIPane<T> {
public void disposeBrowser() {
if (browser != null) {
browser.close();
browser.engine().close();
browser = null;
}
@ -206,6 +206,10 @@ public class NewModernUIPane<T> extends ModernUIPane<T> {
private NewModernUIPane<T> pane = new NewModernUIPane<>();
public Builder() {
super((ModernUIPane<T>)null);
}
public NewModernUIPane.Builder<T> prepare(InjectJsCallback callback) {
pane.browser.set(InjectJsCallback.class, callback);
return this;

Loading…
Cancel
Save