From 72186a982dc8b076bef48313fbbd22ecc78c08bc Mon Sep 17 00:00:00 2001 From: Tuukka Lehtonen Date: Mon, 15 Jan 2018 10:39:54 +0200 Subject: [PATCH] Use transient listener caching for NodePropertyTester requests refs #7718 Change-Id: I6ccb4ef720c4fe8677c78e58fe7ee273caa7ddae --- .../org/simantics/browsing/ui/swt/NodePropertyTester.java | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/bundles/org.simantics.browsing.ui.swt/src/org/simantics/browsing/ui/swt/NodePropertyTester.java b/bundles/org.simantics.browsing.ui.swt/src/org/simantics/browsing/ui/swt/NodePropertyTester.java index 647d0a158..2b6f7c379 100644 --- a/bundles/org.simantics.browsing.ui.swt/src/org/simantics/browsing/ui/swt/NodePropertyTester.java +++ b/bundles/org.simantics.browsing.ui.swt/src/org/simantics/browsing/ui/swt/NodePropertyTester.java @@ -26,6 +26,7 @@ import org.simantics.browsing.ui.model.queries.IsNodeContextModifiable; import org.simantics.browsing.ui.model.queries.IsNodeContextRemovable; import org.simantics.db.Resource; import org.simantics.db.Session; +import org.simantics.db.common.procedure.adapter.TransientCacheListener; import org.simantics.db.common.utils.RequestUtil; import org.simantics.db.exception.DatabaseException; import org.simantics.db.layer0.SelectionHints; @@ -158,7 +159,8 @@ public class NodePropertyTester extends PropertyTester { SimanticsUI.UI_THREAD_REQUEST_START_TIMEOUT, SimanticsUI.UI_THREAD_REQUEST_EXECUTION_TIMEOUT, false, - new IsNodeContextRemovable( nc ) ); + new IsNodeContextRemovable( nc ), + TransientCacheListener.instance()); } catch (DatabaseException | InterruptedException e) { } return false; @@ -185,7 +187,8 @@ public class NodePropertyTester extends PropertyTester { SimanticsUI.UI_THREAD_REQUEST_START_TIMEOUT, SimanticsUI.UI_THREAD_REQUEST_EXECUTION_TIMEOUT, false, - new IsNodeContextModifiable( nc ) ); + new IsNodeContextModifiable( nc ), + TransientCacheListener.instance()); } catch (DatabaseException | InterruptedException e) { } return false; -- 2.43.2