Skip to main content
summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorSebastian Struckmann2015-09-16 08:01:28 -0400
committerSebastian Struckmann2015-09-16 08:01:28 -0400
commitf2aa5d7aa97db4ca94601c32b46c2cf4571e34f2 (patch)
treec407ec33419be992d81e15865973d3d9eb669765
parent820b0a81ddf9dcf410cc60e01db49b6c7f86ca16 (diff)
downloadorg.eclipse.jubula.core-f2aa5d7aa97db4ca94601c32b46c2cf4571e34f2.tar.gz
org.eclipse.jubula.core-f2aa5d7aa97db4ca94601c32b46c2cf4571e34f2.tar.xz
org.eclipse.jubula.core-f2aa5d7aa97db4ca94601c32b46c2cf4571e34f2.zip
Non-sprint task - Fix some invalid thread access problems
-rw-r--r--org.eclipse.jubula.client.ui.rcp/src/org/eclipse/jubula/client/ui/rcp/editors/AbstractJBEditor.java12
-rw-r--r--org.eclipse.jubula.client.ui.rcp/src/org/eclipse/jubula/client/ui/rcp/editors/CentralTestDataEditor.java6
2 files changed, 15 insertions, 3 deletions
diff --git a/org.eclipse.jubula.client.ui.rcp/src/org/eclipse/jubula/client/ui/rcp/editors/AbstractJBEditor.java b/org.eclipse.jubula.client.ui.rcp/src/org/eclipse/jubula/client/ui/rcp/editors/AbstractJBEditor.java
index 727deebdb..2afe541cd 100644
--- a/org.eclipse.jubula.client.ui.rcp/src/org/eclipse/jubula/client/ui/rcp/editors/AbstractJBEditor.java
+++ b/org.eclipse.jubula.client.ui.rcp/src/org/eclipse/jubula/client/ui/rcp/editors/AbstractJBEditor.java
@@ -338,7 +338,11 @@ public abstract class AbstractJBEditor extends EditorPart implements IJBEditor,
*/
public void handlePropertyChanged(boolean isCompNameChanged) {
createPartName();
- getTreeViewer().refresh();
+ Plugin.getDisplay().syncExec(new Runnable() {
+ public void run() {
+ getTreeViewer().refresh();
+ }
+ });
}
@@ -682,6 +686,10 @@ public abstract class AbstractJBEditor extends EditorPart implements IJBEditor,
* Refreshes the editors viewer
*/
public void refresh() {
- getTreeViewer().refresh(true);
+ Plugin.getDisplay().syncExec(new Runnable() {
+ public void run() {
+ getTreeViewer().refresh(true);
+ }
+ });
}
}
diff --git a/org.eclipse.jubula.client.ui.rcp/src/org/eclipse/jubula/client/ui/rcp/editors/CentralTestDataEditor.java b/org.eclipse.jubula.client.ui.rcp/src/org/eclipse/jubula/client/ui/rcp/editors/CentralTestDataEditor.java
index 9c62635df..bde71cc3a 100644
--- a/org.eclipse.jubula.client.ui.rcp/src/org/eclipse/jubula/client/ui/rcp/editors/CentralTestDataEditor.java
+++ b/org.eclipse.jubula.client.ui.rcp/src/org/eclipse/jubula/client/ui/rcp/editors/CentralTestDataEditor.java
@@ -436,7 +436,11 @@ public class CentralTestDataEditor extends AbstractJBEditor implements
/** {@inheritDoc} */
public void handlePropertyChanged(boolean isCompNameChanged) {
- getMainTreeViewer().refresh();
+ Plugin.getDisplay().syncExec(new Runnable() {
+ public void run() {
+ getMainTreeViewer().refresh();
+ }
+ });
}
/** {@inheritDoc} */

Back to the top