Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [pdt-dev] BuildError when importing PHPStructuredEditor

thanks, that one was pretty obvious actually ;)



Am 11/11/09 11:50 AM, schrieb Michael Spector:

You should add org.eclipse.wst.sse.ui plug-in to the dependencies list.

Best regards,

2009/11/11 Robert Gründler <robert@xxxxxxxxxxx>
Hi everyone,

i'm implementing a key-binding handler, which should switch between files that logically
belong together. However, when i try to get the ActiveEditor using the HandlerUtil and
cast it to a PHPStructuredEditor, i get the following build error:

The type org.eclipse.wst.sse.ui.StructuredTextEditor cannot be resolved. It is indirectly referenced from required .class files

I've tryied to add the org.eclipse.wst.sse package to the dependencied (like in the php.ui project), but i still get the error.
The ui project has the following php dependencies:


The code looks like this:

package com.dubture.cpdt.internal.handlers;

import org.eclipse.core.commands.AbstractHandler;
import org.eclipse.core.commands.ExecutionEvent;
import org.eclipse.core.commands.ExecutionException;
import org.eclipse.php.internal.ui.editor.PHPStructuredEditor;
import org.eclipse.ui.IEditorPart;
import org.eclipse.ui.handlers.HandlerUtil;

public class SwitchViewHandler extends AbstractHandler {

   public Object execute(ExecutionEvent event) throws ExecutionException {

       IEditorPart editor = HandlerUtil.getActiveEditor(event);

       if (editor instanceof PHPStructuredEditor)
           PHPStructuredEditor pEditor = (PHPStructuredEditor)editor;

       return null;

Any hints would be greatly appreciated.



pdt-dev mailing list

_______________________________________________ pdt-dev mailing list pdt-dev@xxxxxxxxxxx

Back to the top