]> gerrit.simantics Code Review - simantics/district.git/commitdiff
Add edge arrow contributions to visualisations 73/3473/1
authorjsimomaa <jani.simomaa@gmail.com>
Thu, 7 Nov 2019 12:21:35 +0000 (14:21 +0200)
committerTuukka Lehtonen <tuukka.lehtonen@semantum.fi>
Thu, 7 Nov 2019 12:41:39 +0000 (12:41 +0000)
gitlab #59

Change-Id: Ie53f5509ba4e3545aa6858058376823af937ae58
(cherry picked from commit 314680bcb969e7436eb1d3326fec11ef71b5e420)

org.simantics.district.network/src/org/simantics/district/network/visualisations/model/DynamicArrowContribution.java

index 6e05a999a390e37d42f652c904d287929f33019f..6966ec56b18cf6a44e4d9b226c2605f3fdda1860 100644 (file)
@@ -55,4 +55,9 @@ public class DynamicArrowContribution {
     public boolean isUseDefault() {
         return useDefault;
     }
+
+    public double adjustedValue(double value) {
+        // here we do the adjusting according to spec in #15038
+        return value * getDefaultGain() + getDefaultBias();
+    }
 }
\ No newline at end of file