/*******************************************************************************\r
- * Copyright (c) 2009 Ericsson\r
+ * Copyright (c) 2009, 2010 Ericsson\r
* \r
* All rights reserved. This program and the accompanying materials are\r
* made available under the terms of the Eclipse Public License v1.0 which\r
import java.util.List;\r
import java.util.Map;\r
\r
-import org.eclipse.jface.resource.ImageDescriptor;\r
-import org.eclipse.linuxtools.tmf.ui.TmfUiPlugin;\r
import org.eclipse.linuxtools.tmf.ui.viewers.timeAnalysis.model.ITimeEvent;\r
import org.eclipse.linuxtools.tmf.ui.viewers.timeAnalysis.model.ITmfTimeAnalysisEntry;\r
import org.eclipse.linuxtools.tmf.ui.viewers.timeAnalysis.model.TimeEvent;\r
import org.eclipse.swt.graphics.GC;\r
import org.eclipse.swt.graphics.Image;\r
import org.eclipse.swt.graphics.Rectangle;\r
-import org.eclipse.ui.plugin.AbstractUIPlugin;\r
\r
public abstract class TmfTimeAnalysisProvider {\r
\r
}\r
}\r
\r
- static private String _externalPath[] = {\r
- "icons/full/obj16/thread_obj.gif", // running thread\r
- "icons/full/obj16/threads_obj.gif", // suspended\r
- "icons/full/obj16/threadt_obj.gif", // stopped\r
- "icons/full/obj16/stckframe_running_obj.gif", // running stack frame\r
- "icons/full/obj16/stckframe_obj.gif", // stack frame\r
- };\r
-\r
- static private String _externalPlugin[] = { "org.eclipse.debug.ui",\r
- "org.eclipse.debug.ui", "org.eclipse.debug.ui",\r
- "org.eclipse.debug.ui", "org.eclipse.debug.ui", };\r
-\r
- static private Image getImage(int idx) {\r
- if (idx < 0 || idx >= IMG_NUM)\r
- SWT.error(SWT.ERROR_INVALID_ARGUMENT);\r
- String key = "trace.img." + idx;\r
- Image img = TmfUiPlugin.getDefault().getImageRegistry().get(key);\r
- if (null == img) {\r
- ImageDescriptor desc = AbstractUIPlugin.imageDescriptorFromPlugin(\r
- _externalPlugin[idx], _externalPath[idx]);\r
- TmfUiPlugin.getDefault().getImageRegistry().put(key, desc);\r
- img = TmfUiPlugin.getDefault().getImageRegistry().get(key);\r
- }\r
- return img;\r
- }\r
+ // static private String _externalPath[] = {\r
+ // "icons/full/obj16/thread_obj.gif", // running thread\r
+ // "icons/full/obj16/threads_obj.gif", // suspended\r
+ // "icons/full/obj16/threadt_obj.gif", // stopped\r
+ // "icons/full/obj16/stckframe_running_obj.gif", // running stack frame\r
+ // "icons/full/obj16/stckframe_obj.gif", // stack frame\r
+ // };\r
+ //\r
+ // static private String _externalPlugin[] = { "org.eclipse.debug.ui",\r
+ // "org.eclipse.debug.ui", "org.eclipse.debug.ui",\r
+ // "org.eclipse.debug.ui", "org.eclipse.debug.ui", };\r
+ //\r
+ // static private Image getImage(int idx) {\r
+ // if (idx < 0 || idx >= IMG_NUM)\r
+ // SWT.error(SWT.ERROR_INVALID_ARGUMENT);\r
+ // String key = "trace.img." + idx;\r
+ // Image img = TmfUiPlugin.getDefault().getImageRegistry().get(key);\r
+ // if (null == img) {\r
+ // ImageDescriptor desc = AbstractUIPlugin.imageDescriptorFromPlugin(\r
+ // _externalPlugin[idx], _externalPath[idx]);\r
+ // TmfUiPlugin.getDefault().getImageRegistry().put(key, desc);\r
+ // img = TmfUiPlugin.getDefault().getImageRegistry().get(key);\r
+ // }\r
+ // return img;\r
+ // }\r
\r
public void drawState(TraceColorScheme colors, ITimeEvent event,\r
Rectangle rect, GC gc, boolean selected, boolean rectBound,\r
* @return\r
*/\r
public Image getItemImage(Object obj) {\r
+ /*\r
if (obj instanceof ITmfTimeAnalysisEntry) {\r
List<TimeEvent> list = ((ITmfTimeAnalysisEntry) obj).getTraceEvents();\r
if (null != list && list.size() > 0)\r
if (obj instanceof TimeEvent) {\r
return getImage(IMG_THREAD_RUNNING);\r
}\r
+ */\r
return null;\r
}\r
\r