Added patch from #1437426: error in assign template
[phpeclipse.git] / net.sourceforge.phpeclipse / src / net / sourceforge / phpeclipse / actions / PHPOpenAllIncludesEditorAction.java
index aec734b..c21740f 100644 (file)
@@ -4,10 +4,11 @@
  * the Common Public License v1.0 which accompanies this distribution, and is
  * available at http://www.eclipse.org/legal/cpl-v10.html
  * 
- * Contributors: Klaus Hartlage - www.eclipseproject.de
+ * Contributors: www.phpeclipse.de
  ******************************************************************************/
 package net.sourceforge.phpeclipse.actions;
 
+import java.io.File;
 import java.util.List;
 
 import net.sourceforge.phpeclipse.PHPeclipsePlugin;
@@ -26,6 +27,7 @@ import org.eclipse.jface.text.TextSelection;
 import org.eclipse.jface.viewers.ISelection;
 import org.eclipse.jface.viewers.LabelProvider;
 import org.eclipse.jface.window.Window;
+import net.sourceforge.phpdt.internal.ui.viewsupport.ListContentProvider;
 import org.eclipse.swt.graphics.Point;
 import org.eclipse.ui.IEditorActionDelegate;
 import org.eclipse.ui.IEditorPart;
@@ -34,7 +36,6 @@ import org.eclipse.ui.IWorkbenchPage;
 import org.eclipse.ui.IWorkbenchWindow;
 import org.eclipse.ui.actions.ActionDelegate;
 import org.eclipse.ui.dialogs.ListSelectionDialog;
-import org.eclipse.ui.internal.dialogs.ListContentProvider;
 
 public class PHPOpenAllIncludesEditorAction extends ActionDelegate implements IEditorActionDelegate {
 
@@ -126,8 +127,9 @@ public class PHPOpenAllIncludesEditorAction extends ActionDelegate implements IE
 
           List list = fIncludesScanner.getList();
           if (list != null && list.size() > 0) {
-            String workspaceLocation = PHPeclipsePlugin.getWorkspace().getRoot().getLocation().toString();
-
+//            String workspaceLocation = PHPeclipsePlugin.getWorkspace().getRoot().getLocation().toString();
+            String workspaceLocation = fProject.getLocation().toString()+File.separatorChar;
+            
             ListSelectionDialog listSelectionDialog = new ListSelectionDialog(PHPeclipsePlugin.getDefault().getWorkbench()
                 .getActiveWorkbenchWindow().getShell(), list, new ListContentProvider(), new LabelProvider(),
                 "Select the includes to open.");