tmf: Update copyright headers in tmf.ui
[deliverable/tracecompass.git] / org.eclipse.linuxtools.tmf.ui / src / org / eclipse / linuxtools / tmf / ui / views / timechart / TimeChartView.java
index daac4e02010c4c7a86277eedf2013cb70c174fc9..fe0582bbeff395b637ab27463e4b931fb29f08c0 100644 (file)
@@ -1,5 +1,5 @@
 /*******************************************************************************
- * Copyright (c) 2010 Ericsson
+ * Copyright (c) 2010, 2013 Ericsson
  *
  * All rights reserved. This program and the accompanying materials are
  * made available under the terms of the Eclipse Public License v1.0 which
@@ -55,12 +55,8 @@ import org.eclipse.linuxtools.tmf.ui.widgets.timegraph.TimeGraphTimeEvent;
 import org.eclipse.linuxtools.tmf.ui.widgets.timegraph.TimeGraphViewer;
 import org.eclipse.linuxtools.tmf.ui.widgets.timegraph.model.ITimeEvent;
 import org.eclipse.linuxtools.tmf.ui.widgets.timegraph.model.ITimeGraphEntry;
-import org.eclipse.linuxtools.tmf.ui.widgets.timegraph.widgets.TimeGraphColorScheme;
-import org.eclipse.linuxtools.tmf.ui.widgets.timegraph.widgets.TimeGraphControl;
 import org.eclipse.linuxtools.tmf.ui.widgets.timegraph.widgets.Utils.TimeFormat;
 import org.eclipse.swt.SWT;
-import org.eclipse.swt.graphics.GC;
-import org.eclipse.swt.graphics.Rectangle;
 import org.eclipse.swt.widgets.Composite;
 import org.eclipse.swt.widgets.Display;
 import org.eclipse.ui.IEditorPart;
@@ -93,30 +89,6 @@ public class TimeChartView extends TmfView implements ITimeGraphRangeListener, I
     private final Object fSyncObj = new Object();
     private ITimeGraphPresentationProvider fPresentationProvider;
 
-    /**
-     * TimeChartViewer extends TimeGraphViewer to use a TimeGraphControl that overrides drawState
-     * to inhibit drawing of filtered-out events.
-     */
-    private class TimeChartViewer extends TimeGraphViewer {
-
-        public TimeChartViewer(Composite parent, int style) {
-            super(parent, style);
-        }
-
-        @Override
-        protected TimeGraphControl createTimeGraphControl(Composite parent, TimeGraphColorScheme colorScheme) {
-            return new TimeGraphControl(parent, colorScheme) {
-                @Override
-                protected void drawState(TimeGraphColorScheme colors, ITimeEvent event, Rectangle rect, GC gc, boolean selected, boolean timeSelected) {
-                    if (! ((TimeChartEvent) event).isVisible()) {
-                        return;
-                    }
-                    super.drawState(colors, event, rect, gc, selected, timeSelected);
-                }
-            };
-        }
-    }
-
     /**
      * Default constructor
      */
@@ -127,7 +99,7 @@ public class TimeChartView extends TmfView implements ITimeGraphRangeListener, I
 
     @Override
     public void createPartControl(Composite parent) {
-        fViewer = new TimeChartViewer(parent, SWT.NONE);
+        fViewer = new TimeGraphViewer(parent, SWT.NONE);
         fPresentationProvider = new TimeChartAnalysisProvider();
         fViewer.setTimeGraphProvider(fPresentationProvider);
         fViewer.setTimeFormat(TimeFormat.CALENDAR);
This page took 0.024736 seconds and 5 git commands to generate.