1) Fixed '$' preceding of PHP variables (this file was missed in the previous commit).
[phpeclipse.git] / net.sourceforge.phpeclipse / src / net / sourceforge / phpdt / ui / actions / GenerateActionGroup.java
index f627deb..b228189 100644 (file)
@@ -22,13 +22,15 @@ import net.sourceforge.phpeclipse.phpeditor.PHPEditor;
 import org.eclipse.jface.action.IAction;
 import org.eclipse.jface.action.IMenuManager;
 import org.eclipse.jface.action.MenuManager;
-import org.eclipse.jface.util.Assert;
+//incastrix
+//import org.eclipse.jface.text.Assert;
+import org.eclipse.core.runtime.Assert;
 import org.eclipse.jface.viewers.ISelection;
 import org.eclipse.jface.viewers.ISelectionChangedListener;
 import org.eclipse.jface.viewers.ISelectionProvider;
 import org.eclipse.jface.viewers.IStructuredSelection;
 import org.eclipse.ui.IActionBars;
-import org.eclipse.ui.IViewPart;
+//import org.eclipse.ui.IViewPart;
 import org.eclipse.ui.IWorkbenchSite;
 import org.eclipse.ui.actions.ActionGroup;
 import org.eclipse.ui.actions.AddBookmarkAction;
@@ -88,8 +90,8 @@ public class GenerateActionGroup extends ActionGroup {
                fEditor = editor;
                fGroupName = groupName;
 
-               ISelectionProvider provider = fSite.getSelectionProvider();
-               ISelection selection = provider.getSelection();
+               //ISelectionProvider provider = fSite.getSelectionProvider();
+               //ISelection selection = provider.getSelection();
 
                // fAddImport= new AddImportOnSelectionAction(editor);
                // fAddImport.setActionDefinitionId(IJavaEditorActionDefinitionIds.ADD_IMPORT);
@@ -156,9 +158,9 @@ public class GenerateActionGroup extends ActionGroup {
         * @param part
         *            the view part that owns this action group
         */
-       public GenerateActionGroup(IViewPart part) {
-               this(part.getSite());
-       }
+//     public GenerateActionGroup(IViewPart part) {
+//             this(part.getSite());
+//     }
 
        private GenerateActionGroup(IWorkbenchSite site) {
                fSite = site;
@@ -358,21 +360,21 @@ public class GenerateActionGroup extends ActionGroup {
                }
        }
 
-       private int appendToGroup(IMenuManager menu, IAction action) {
-               if (action != null && action.isEnabled()) {
-                       menu.appendToGroup(fGroupName, action);
-                       return 1;
-               }
-               return 0;
-       }
-
-       private int addAction(IMenuManager menu, IAction action) {
-               if (action != null && action.isEnabled()) {
-                       menu.add(action);
-                       return 1;
-               }
-               return 0;
-       }
+//     private int appendToGroup(IMenuManager menu, IAction action) {
+//             if (action != null && action.isEnabled()) {
+//                     menu.appendToGroup(fGroupName, action);
+//                     return 1;
+//             }
+//             return 0;
+//     }
+
+//     private int addAction(IMenuManager menu, IAction action) {
+//             if (action != null && action.isEnabled()) {
+//                     menu.add(action);
+//                     return 1;
+//             }
+//             return 0;
+//     }
 
        private int addEditorAction(IMenuManager menu, String actionID) {
                if (fEditor == null)