Activator.java
Go to the documentation of this file.00001 package edu.rice.cs.hpc.traceviewer.framework;
00002
00003 import org.eclipse.jface.resource.ImageDescriptor;
00004 import org.eclipse.jface.resource.ImageRegistry;
00005 import org.eclipse.ui.plugin.AbstractUIPlugin;
00006 import org.osgi.framework.BundleContext;
00007
00008 import edu.rice.cs.hpc.traceviewer.icon.IconManager;
00009
00013 public class Activator extends AbstractUIPlugin {
00014
00015
00016 public static final String PLUGIN_ID = "hpctraceviewer";
00017
00018
00019 private static Activator plugin;
00020
00024 public Activator() {
00025 }
00026
00027
00028
00029
00030
00031 public void start(BundleContext context) throws Exception {
00032 super.start(context);
00033 plugin = this;
00034 }
00035
00036
00037
00038
00039
00040 public void stop(BundleContext context) throws Exception {
00041 plugin = null;
00042 super.stop(context);
00043 }
00044
00050 public static Activator getDefault() {
00051 return plugin;
00052 }
00053
00061 public static ImageDescriptor getImageDescriptor(String path) {
00062 return imageDescriptorFromPlugin(PLUGIN_ID, path);
00063 }
00064
00065
00066
00067
00068
00069 protected void initializeImageRegistry(ImageRegistry registry) {
00070
00071 IconManager icon = new IconManager();
00072 icon.init(registry);
00073 }
00074 }