More fixes of static analysis warnings for UML2SD
[deliverable/tracecompass.git] / org.eclipse.linuxtools.tmf.ui / src / org / eclipse / linuxtools / tmf / ui / views / uml2sd / core / HotSpot.java
index 669dc6201e5daddb5fe5525ffb1e7b7b7fb4890e..db099e50d3024cf5c99d180a4b77323b2fb39558 100755 (executable)
@@ -16,6 +16,7 @@ package org.eclipse.linuxtools.tmf.ui.views.uml2sd.core;
 import org.eclipse.linuxtools.tmf.ui.views.uml2sd.drawings.IGC;
 import org.eclipse.linuxtools.tmf.ui.views.uml2sd.drawings.IImage;
 import org.eclipse.linuxtools.tmf.ui.views.uml2sd.preferences.ISDPreferences;
+import org.eclipse.linuxtools.tmf.ui.views.uml2sd.preferences.SDViewPref;
 
 /**
  * Class to add a hot spot marker.
@@ -164,14 +165,16 @@ public class HotSpot extends GraphNode {
     @Override
     public void draw(IGC context) {
 
+        ISDPreferences pref = SDViewPref.getInstance();
+
         // The execution occurrence is selected
         // if the owning lifeline is selected
         if (isSelected() || (fExecOcc != null && fExecOcc.isSelected()) || (fExecOcc != null && fExecOcc.getLifeline() != null && fExecOcc.getLifeline().isSelected())) {
-            context.setBackground(Frame.getUserPref().getBackGroundColorSelection());
-            context.setForeground(Frame.getUserPref().getForeGroundColorSelection());
+            context.setBackground(pref.getBackGroundColorSelection());
+            context.setForeground(pref.getForeGroundColorSelection());
         } else {
-            context.setBackground(Frame.getUserPref().getBackGroundColor(ISDPreferences.PREF_EXEC));
-            context.setForeground(Frame.getUserPref().getForeGroundColor(ISDPreferences.PREF_EXEC));
+            context.setBackground(pref.getBackGroundColor(ISDPreferences.PREF_EXEC));
+            context.setForeground(pref.getForeGroundColor(ISDPreferences.PREF_EXEC));
         }
         context.drawImage(fImage, getX(), getY(), getWidth(), getHeight());
     }
This page took 0.030069 seconds and 5 git commands to generate.