3.x RC1 compatibility
[phpeclipse.git] / net.sourceforge.phpeclipse.debug.ui / src / net / sourceforge / phpdt / internal / debug / ui / PHPDebugUiPlugin.java
index 16f59ce..79f91cb 100644 (file)
@@ -6,12 +6,13 @@ import org.eclipse.core.resources.IWorkspace;
 import org.eclipse.core.runtime.IPluginDescriptor;
 import org.eclipse.core.runtime.IStatus;
 import org.eclipse.core.runtime.Status;
+import org.eclipse.jface.dialogs.ErrorDialog;
+import org.eclipse.swt.widgets.Display;
+import org.eclipse.swt.widgets.Shell;
 import org.eclipse.ui.IWorkbenchPage;
 import org.eclipse.ui.IWorkbenchWindow;
 import org.eclipse.ui.plugin.AbstractUIPlugin;
-import org.eclipse.swt.widgets.Shell;
-import org.eclipse.jface.dialogs.ErrorDialog;
-import org.eclipse.swt.widgets.Display;
+import org.osgi.framework.BundleContext;
 
 public class PHPDebugUiPlugin extends AbstractUIPlugin {
        public static final String PLUGIN_ID = "net.sourceforge.phpeclipse.debug.ui"; //$NON-NLS-1$
@@ -41,17 +42,17 @@ public class PHPDebugUiPlugin extends AbstractUIPlugin {
        /**
         * Convenience method which returns the unique identifier of this plugin.
         */
-       public static String getUniqueIdentifier()
-       {
-               if ( getDefault() == null )
-               {
-                       // If the default instance is not yet initialized,
-                       // return a static identifier. This identifier must
-                       // match the plugin id defined in plugin.xml
-                       return PLUGIN_ID;
-               }
-               return getDefault().getDescriptor().getUniqueIdentifier();
-       }
+//     public static String getUniqueIdentifier()
+//     {
+//             if ( getDefault() == null )
+//             {
+//                     // If the default instance is not yet initialized,
+//                     // return a static identifier. This identifier must
+//                     // match the plugin id defined in plugin.xml
+//                     return PLUGIN_ID;
+//             }
+//             return getDefault().getDescriptor().getUniqueIdentifier();
+//     }
        
        /**
         * Returns the standard display to be used. The method first checks, if
@@ -95,7 +96,7 @@ public class PHPDebugUiPlugin extends AbstractUIPlugin {
                        Shell shell = getActiveWorkbenchShell();
                        if ( shell != null )
                        {
-                               IStatus status = new Status( IStatus.ERROR, getUniqueIdentifier(), /*ICDebugUIConstants.INTERNAL_ERROR*/ 150, t.getMessage(), null ); //$NON-NLS-1$     
+                               IStatus status = new Status( IStatus.ERROR, PLUGIN_ID, /*ICDebugUIConstants.INTERNAL_ERROR*/ 150, t.getMessage(), null ); //$NON-NLS-1$ 
                                ErrorDialog.openError( shell, "Error", message, status );
                        }
                }                       
@@ -108,6 +109,20 @@ public class PHPDebugUiPlugin extends AbstractUIPlugin {
                log(new Status(IStatus.ERROR, PLUGIN_ID, IStatus.ERROR, PHPDebugUiMessages.getString("RdtDebugUiPlugin.internalErrorOccurred"), e)); //$NON-NLS-1$
        }
 
+       /**
+        * This method is called upon plug-in activation
+        */
+       public void start(BundleContext context) throws Exception {
+               super.start(context);
+       }
+
+       /**
+        * This method is called when the plug-in is stopped
+        */
+       public void stop(BundleContext context) throws Exception {
+               super.stop(context);
+       }
+       
 //     protected void initializeDefaultPreferences(IPreferenceStore store) {
 //             super.initializeDefaultPreferences(store);
 //