From 212bcef93f38d2e69d015862f817e29c7517fc11 Mon Sep 17 00:00:00 2001 From: "Java.Edge" Date: Tue, 14 Apr 2020 16:53:49 +0800 Subject: [PATCH] EPORT-27996 bugfix --- .../java/com/fr/design/gui/ilist/TableViewList.java | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/designer-base/src/main/java/com/fr/design/gui/ilist/TableViewList.java b/designer-base/src/main/java/com/fr/design/gui/ilist/TableViewList.java index 06a4f5480..cccf64e26 100644 --- a/designer-base/src/main/java/com/fr/design/gui/ilist/TableViewList.java +++ b/designer-base/src/main/java/com/fr/design/gui/ilist/TableViewList.java @@ -91,10 +91,10 @@ public class TableViewList extends UIList { if (refreshList != null) { refreshList.cancel(true); } - refreshList = new SwingWorker() { + refreshList = new SwingWorker() { @Override - protected Void doInBackground() throws Exception { + protected DefaultListModel doInBackground() throws Exception { Connection datasource = ConnectionConfig.getInstance().getConnection(databaseName); boolean status = false; int count = 3; @@ -106,13 +106,13 @@ public class TableViewList extends UIList { if (!status) { throw new Exception(com.fr.design.i18n.Toolkit.i18nText("Fine-Design_Basic_Database_Connection_Failed")); } - TableViewList.this.setModel(processDataInAnotherThread(databaseName, searchFilter, typesFilter)); - return null; + return processDataInAnotherThread(databaseName, searchFilter, typesFilter); } + @Override public void done() { try { - get(); + TableViewList.this.setModel(get()); } catch (Exception e) { if (!(e instanceof InterruptedException) && !(e instanceof CancellationException)) { TableViewList.this.setModel(failed);