IPackageFilter filter = new IPackageFilter() {
public boolean select(String packageName) {
return !packageName.equals("java") && !packageName.startsWith("java.") && !packageNameSet.contains(packageName);
}
};
IFormPage page = (IFormPage) getManagedForm().getContainer();
IWorkbenchWindow window = page.getEditorSite().getWorkbenchWindow();
// Prepare the package lister from the Java project
IJavaProject javaProject = getJavaProject();
if (javaProject == null) {
MessageDialog.openError(getSection().getShell(), "Error", "Cannot add packages: unable to find a Java project associated with the editor input.");