### Eclipse Workspace Patch 1.0 #P org.eclipse.pde.core Index: src/org/eclipse/pde/internal/core/builders/PDEMarkerFactory.java =================================================================== RCS file: /cvsroot/eclipse/org.eclipse.pde.core/src/org/eclipse/pde/internal/core/builders/PDEMarkerFactory.java,v retrieving revision 1.20 diff -u -r1.20 PDEMarkerFactory.java --- src/org/eclipse/pde/internal/core/builders/PDEMarkerFactory.java 2 Jan 2008 15:56:21 -0000 1.20 +++ src/org/eclipse/pde/internal/core/builders/PDEMarkerFactory.java 3 Jan 2008 02:37:38 -0000 @@ -1,5 +1,5 @@ /******************************************************************************* - * Copyright (c) 2000, 2007 IBM Corporation and others. + * Copyright (c) 2000, 2008 IBM Corporation and others. * All rights reserved. This program and the accompanying materials * are made available under the terms of the Eclipse Public License v1.0 * which accompanies this distribution, and is available at @@ -9,6 +9,7 @@ * IBM Corporation - initial API and implementation * Brock Janiczak - bug 169373 * Gary Duprex - bug 150225 + * Bartosz Michalik - bug 214156 *******************************************************************************/ package org.eclipse.pde.internal.core.builders; @@ -44,6 +45,7 @@ public static final int M_DEPRECATED_PROVIDE_PACKAGE = 0x1019; // deprecation public static final int M_EXECUTION_ENVIRONMENT_NOT_SET = 0x1020; // other problem public static final int M_MISSING_BUNDLE_CLASSPATH_ENTRY = 0x1021; // fatal problem + public static final int M_LAZYLOADING_HAS_NO_EFFECT = 0x1022; //other problem // build properties fixes public static final int B_APPEND_SLASH_FOLDER_ENTRY = 0x2001; Index: src/org/eclipse/pde/internal/core/builders/BundleErrorReporter.java =================================================================== RCS file: /cvsroot/eclipse/org.eclipse.pde.core/src/org/eclipse/pde/internal/core/builders/BundleErrorReporter.java,v retrieving revision 1.57 diff -u -r1.57 BundleErrorReporter.java --- src/org/eclipse/pde/internal/core/builders/BundleErrorReporter.java 2 Jan 2008 21:09:38 -0000 1.57 +++ src/org/eclipse/pde/internal/core/builders/BundleErrorReporter.java 3 Jan 2008 02:37:38 -0000 @@ -9,7 +9,7 @@ * IBM Corporation - initial API and implementation * Brock Janiczak - bug 169373 * Gary Duprex - bug 150225 - * Bartosz Michalik - bug 209432 + * Bartosz Michalik - bug 209432, 214156 *******************************************************************************/ package org.eclipse.pde.internal.core.builders; @@ -945,7 +945,7 @@ if (header != null) { IHeader activator = getHeader(Constants.BUNDLE_ACTIVATOR); if (activator == null && "true".equals(header.getValue())) { //$NON-NLS-1$ - report(PDECoreMessages.BundleErrorReporter_lazyStart_missingActivator, header.getLineNumber() + 1, CompilerFlags.WARNING, PDEMarkerFactory.M_DIRECTIVE_HAS_NO_EFFECT, PDEMarkerFactory.CAT_OTHER); + report(PDECoreMessages.BundleErrorReporter_lazyStart_missingActivator, header.getLineNumber() + 1, CompilerFlags.WARNING, PDEMarkerFactory.M_LAZYLOADING_HAS_NO_EFFECT, PDEMarkerFactory.CAT_OTHER); } if (TargetPlatformHelper.getTargetVersion() < 3.2 && severity != CompilerFlags.IGNORE) { report(PDECoreMessages.BundleErrorReporter_lazyStart_unsupported, header.getLineNumber() + 1, severity, PDEMarkerFactory.NO_RESOLUTION, PDEMarkerFactory.CAT_OTHER); #P org.eclipse.pde.ui Index: src/org/eclipse/pde/internal/ui/editor/plugin/PluginGeneralInfoSection.java =================================================================== RCS file: /cvsroot/eclipse/org.eclipse.pde.ui/src/org/eclipse/pde/internal/ui/editor/plugin/PluginGeneralInfoSection.java,v retrieving revision 1.33 diff -u -r1.33 PluginGeneralInfoSection.java --- src/org/eclipse/pde/internal/ui/editor/plugin/PluginGeneralInfoSection.java 3 Sep 2007 15:45:04 -0000 1.33 +++ src/org/eclipse/pde/internal/ui/editor/plugin/PluginGeneralInfoSection.java 3 Jan 2008 02:38:11 -0000 @@ -16,6 +16,7 @@ import org.eclipse.core.runtime.CoreException; import org.eclipse.jdt.core.search.IJavaSearchConstants; import org.eclipse.jdt.ui.IJavaElementSearchConstants; +import org.eclipse.pde.core.IModelChangedEvent; import org.eclipse.pde.core.plugin.IPlugin; import org.eclipse.pde.core.plugin.IPluginModelBase; import org.eclipse.pde.internal.core.ICoreConstants; @@ -45,7 +46,6 @@ import org.eclipse.ui.forms.widgets.TableWrapData; public class PluginGeneralInfoSection extends GeneralInfoSection { - private FormEntry fClassEntry; private Button fLazyStart; private TypeFieldAssistDisposer fTypeFieldAssistDisposer; @@ -215,4 +215,13 @@ } } + public void modelChanged(IModelChangedEvent e) { + super.modelChanged(e); + if (e.getChangeType() == IModelChangedEvent.CHANGE + && ICoreConstants.ECLIPSE_LAZYSTART.equals(e + .getChangedProperty())) { + fLazyStart.setSelection("true".equals(e.getNewValue())); + } + } + } Index: src/org/eclipse/pde/internal/ui/PDEUIMessages.java =================================================================== RCS file: /cvsroot/eclipse/org.eclipse.pde.ui/src/org/eclipse/pde/internal/ui/PDEUIMessages.java,v retrieving revision 1.345 diff -u -r1.345 PDEUIMessages.java --- src/org/eclipse/pde/internal/ui/PDEUIMessages.java 2 Jan 2008 22:39:40 -0000 1.345 +++ src/org/eclipse/pde/internal/ui/PDEUIMessages.java 3 Jan 2008 02:37:55 -0000 @@ -2493,6 +2493,10 @@ public static String LauncherUtils_title; + public static String LazyLoadingResolution_remove; + + public static String LazyLoadingResolution_disable; + public static String EditorPreferencePage_link; public static String ManifestSyntaxColorTab_keys; Index: src/org/eclipse/pde/internal/ui/pderesources.properties =================================================================== RCS file: /cvsroot/eclipse/org.eclipse.pde.ui/src/org/eclipse/pde/internal/ui/pderesources.properties,v retrieving revision 1.950 diff -u -r1.950 pderesources.properties --- src/org/eclipse/pde/internal/ui/pderesources.properties 2 Jan 2008 22:39:39 -0000 1.950 +++ src/org/eclipse/pde/internal/ui/pderesources.properties 3 Jan 2008 02:38:09 -0000 @@ -1946,6 +1946,8 @@ LauncherSection_launcherName=Launcher Name: LauncherSection_dialogTitle=Image Selection LauncherSection_dialogMessage=Select an image: +LazyLoadingResolution_remove=Remove Eclipse-LazyStart header +LazyLoadingResolution_disable=Set Eclipse-LazyStart to false ProductDefinitonWizardPage_applicationDefinition=

An Eclipse product must be associated with an application, the default entry point for the product when it is running.

ArgumentsSection_title=Launching Arguments ArgumentsSection_editorTitle=Arguments Index: src/org/eclipse/pde/internal/ui/correction/ResolutionGenerator.java =================================================================== RCS file: /cvsroot/eclipse/org.eclipse.pde.ui/src/org/eclipse/pde/internal/ui/correction/ResolutionGenerator.java,v retrieving revision 1.32 diff -u -r1.32 ResolutionGenerator.java --- src/org/eclipse/pde/internal/ui/correction/ResolutionGenerator.java 16 Nov 2007 21:44:21 -0000 1.32 +++ src/org/eclipse/pde/internal/ui/correction/ResolutionGenerator.java 3 Jan 2008 02:38:09 -0000 @@ -1,5 +1,5 @@ /******************************************************************************* - * Copyright (c) 2005, 2007 IBM Corporation and others. + * Copyright (c) 2005, 2008 IBM Corporation and others. * All rights reserved. This program and the accompanying materials * are made available under the terms of the Eclipse Public License v1.0 * which accompanies this distribution, and is available at @@ -8,6 +8,7 @@ * Contributors: * IBM Corporation - initial API and implementation * Gary Duprex - bug 150225 + * Bartosz Michalik - bug 214156 *******************************************************************************/ package org.eclipse.pde.internal.ui.correction; @@ -96,6 +97,9 @@ return new IMarkerResolution[] { new AddDefaultExecutionEnvironmentResolution(AbstractPDEMarkerResolution.CREATE_TYPE, marker.getAttribute("ee_id", null)) }; //$NON-NLS-1$ case PDEMarkerFactory.M_MISSING_BUNDLE_CLASSPATH_ENTRY: return new IMarkerResolution[] {new AddBundleClassPathMarkerResolution(AbstractPDEMarkerResolution.CREATE_TYPE, marker.getAttribute("entry", null))}; //$NON-NLS-1$ + case PDEMarkerFactory.M_LAZYLOADING_HAS_NO_EFFECT: + return new IMarkerResolution[] {new DisableLazyLoadingDirectiveResolution(AbstractPDEMarkerResolution.RENAME_TYPE), + new DisableLazyLoadingDirectiveResolution(AbstractPDEMarkerResolution.REMOVE_TYPE)}; } return NO_RESOLUTIONS; } Index: src/org/eclipse/pde/internal/ui/correction/DisableLazyLoadingDirectiveResolution.java =================================================================== RCS file: src/org/eclipse/pde/internal/ui/correction/DisableLazyLoadingDirectiveResolution.java diff -N src/org/eclipse/pde/internal/ui/correction/DisableLazyLoadingDirectiveResolution.java --- /dev/null 1 Jan 1970 00:00:00 -0000 +++ src/org/eclipse/pde/internal/ui/correction/DisableLazyLoadingDirectiveResolution.java 1 Jan 1970 00:00:00 -0000 @@ -0,0 +1,39 @@ +/******************************************************************************* + * Copyright (c) 2008 IBM Corporation and others. + * All rights reserved. This program and the accompanying materials + * are made available under the terms of the Eclipse Public License v1.0 + * which accompanies this distribution, and is available at + * http://www.eclipse.org/legal/epl-v10.html + * + * Contributors: + * IBM Corporation - initial API and implementation + * Bartosz Michalik - bug 214156 + *******************************************************************************/ +package org.eclipse.pde.internal.ui.correction; + +import org.eclipse.pde.internal.core.ICoreConstants; +import org.eclipse.pde.internal.core.ibundle.IManifestHeader; +import org.eclipse.pde.internal.core.text.bundle.BundleModel; +import org.eclipse.pde.internal.ui.PDEUIMessages; + +public class DisableLazyLoadingDirectiveResolution extends + AbstractManifestMarkerResolution { + + private boolean fRemove; + + public DisableLazyLoadingDirectiveResolution(int type) { + super(type); + fRemove = (type == AbstractPDEMarkerResolution.REMOVE_TYPE); + } + + protected void createChange(BundleModel model) { + IManifestHeader activation = model.getBundle().getManifestHeader(ICoreConstants.ECLIPSE_LAZYSTART); + if(fRemove) activation.setValue(null); + else activation.setValue("false"); //$NON-NLS-1$ + } + + public String getLabel() { + return fRemove ? PDEUIMessages.LazyLoadingResolution_remove : PDEUIMessages.LazyLoadingResolution_disable; + } + +}