# HG changeset patch # User Eugene Ostroukhov # Date 1271808717 25200 # Node ID 25282116ebcf0c27c3311cc2872e839084ed2860 # Parent 11f39c9c31567bba96acfe5ac66b730d35436430 Eclipse 3.6 M6 support diff -r 11f39c9c3156 -r 25282116ebcf org.symbian.tools.wrttools.debug.core/build.properties --- a/org.symbian.tools.wrttools.debug.core/build.properties Tue Apr 20 15:15:32 2010 -0700 +++ b/org.symbian.tools.wrttools.debug.core/build.properties Tue Apr 20 17:11:57 2010 -0700 @@ -5,10 +5,7 @@ plugin.xml,\ LICENSE,\ icons/ -src.includes = src/,\ - .classpath,\ - .project,\ - LICENSE +src.includes = LICENSE # javac javacSource=1.5 javacTarget=1.5 diff -r 11f39c9c3156 -r 25282116ebcf org.symbian.tools.wrttools.debug.core/src/org/symbian/tools/wrttools/debug/internal/BreakpointAdapterFactory.java --- a/org.symbian.tools.wrttools.debug.core/src/org/symbian/tools/wrttools/debug/internal/BreakpointAdapterFactory.java Tue Apr 20 15:15:32 2010 -0700 +++ b/org.symbian.tools.wrttools.debug.core/src/org/symbian/tools/wrttools/debug/internal/BreakpointAdapterFactory.java Tue Apr 20 17:11:57 2010 -0700 @@ -23,9 +23,9 @@ import org.eclipse.debug.ui.actions.IToggleBreakpointsTarget; import org.eclipse.ui.IEditorPart; +@SuppressWarnings("rawtypes") public class BreakpointAdapterFactory implements IAdapterFactory { - @SuppressWarnings("unchecked") public Object getAdapter(Object adaptableObject, Class adapterType) { if (adaptableObject instanceof IEditorPart) { IResource resource = (IResource) ((IEditorPart) adaptableObject) @@ -37,8 +37,7 @@ return null; } - @SuppressWarnings("unchecked") - public Class[] getAdapterList() { + public Class[] getAdapterList() { return new Class[] { IToggleBreakpointsTarget.class }; } diff -r 11f39c9c3156 -r 25282116ebcf org.symbian.tools.wrttools.debug.core/src/org/symbian/tools/wrttools/debug/internal/property/LaunchableFactory.java --- a/org.symbian.tools.wrttools.debug.core/src/org/symbian/tools/wrttools/debug/internal/property/LaunchableFactory.java Tue Apr 20 15:15:32 2010 -0700 +++ b/org.symbian.tools.wrttools.debug.core/src/org/symbian/tools/wrttools/debug/internal/property/LaunchableFactory.java Tue Apr 20 17:11:57 2010 -0700 @@ -4,13 +4,13 @@ public class LaunchableFactory implements IAdapterFactory { - @SuppressWarnings("unchecked") - public Object getAdapter(Object adaptableObject, Class adapterType) { + @SuppressWarnings("rawtypes") + public Object getAdapter(Object adaptableObject, Class adapterType) { // It is only needed to exist return null; } - @SuppressWarnings("unchecked") + @SuppressWarnings("rawtypes") public Class[] getAdapterList() { // It is only needed to exist return null; diff -r 11f39c9c3156 -r 25282116ebcf org.symbian.tools.wrttools.debug.core/src/org/symbian/tools/wrttools/debug/internal/session/TerminateSession.java --- a/org.symbian.tools.wrttools.debug.core/src/org/symbian/tools/wrttools/debug/internal/session/TerminateSession.java Tue Apr 20 15:15:32 2010 -0700 +++ b/org.symbian.tools.wrttools.debug.core/src/org/symbian/tools/wrttools/debug/internal/session/TerminateSession.java Tue Apr 20 17:11:57 2010 -0700 @@ -31,7 +31,7 @@ import org.symbian.tools.wrttools.previewer.IPreviewerCommandHandler; public class TerminateSession implements IPreviewerCommandHandler { - @SuppressWarnings("unchecked") + @SuppressWarnings("rawtypes") public void handle(String commandName, String projectName, Map parameters) { ILaunchManager launchManager = DebugPlugin.getDefault().getLaunchManager(); for (ILaunch launch : launchManager.getLaunches()) { diff -r 11f39c9c3156 -r 25282116ebcf org.symbian.tools.wrttools.debug.core/src/org/symbian/tools/wrttools/debug/ui/launch/WidgetLaunchShortcut.java --- a/org.symbian.tools.wrttools.debug.core/src/org/symbian/tools/wrttools/debug/ui/launch/WidgetLaunchShortcut.java Tue Apr 20 15:15:32 2010 -0700 +++ b/org.symbian.tools.wrttools.debug.core/src/org/symbian/tools/wrttools/debug/ui/launch/WidgetLaunchShortcut.java Tue Apr 20 17:11:57 2010 -0700 @@ -39,102 +39,85 @@ public class WidgetLaunchShortcut implements ILaunchShortcut2 { - public IResource getLaunchableResource(IEditorPart editorpart) { - IEditorInput input = editorpart.getEditorInput(); - return (IResource) input.getAdapter(IResource.class); - } - - public IResource getLaunchableResource(ISelection selection) { - if (!selection.isEmpty() && selection instanceof IStructuredSelection) { - Object object = ((IStructuredSelection) selection) - .getFirstElement(); - IResource resource = null; - if (object instanceof IResource) { - resource = (IResource) object; - } else if (object instanceof IAdaptable) { - resource = (IResource) ((IAdaptable) object) - .getAdapter(IResource.class); - } - return resource; - } - return null; - } + public IResource getLaunchableResource(IEditorPart editorpart) { + IEditorInput input = editorpart.getEditorInput(); + return (IResource) input.getAdapter(IResource.class); + } - public ILaunchConfiguration[] getLaunchConfigurations(IEditorPart editorpart) { - return getLaunchConfigurations(getLaunchableResource(editorpart)); - } + public IResource getLaunchableResource(ISelection selection) { + if (!selection.isEmpty() && selection instanceof IStructuredSelection) { + Object object = ((IStructuredSelection) selection).getFirstElement(); + IResource resource = null; + if (object instanceof IResource) { + resource = (IResource) object; + } else if (object instanceof IAdaptable) { + resource = (IResource) ((IAdaptable) object).getAdapter(IResource.class); + } + return resource; + } + return null; + } - private ILaunchConfiguration getLaunchConfigurations(IProject project) - throws CoreException { - ILaunchManager launchManager = DebugPlugin.getDefault() - .getLaunchManager(); - ILaunchConfigurationType type = launchManager - .getLaunchConfigurationType(WidgetLaunchDelegate.ID); - ILaunchConfiguration configuration = null; - ILaunchConfiguration[] configurations = launchManager - .getLaunchConfigurations(type); - for (ILaunchConfiguration c : configurations) { - if (project.getName() - .equals( - c.getAttribute(IConstants.PROP_PROJECT_NAME, - (String) null))) { - configuration = c; - break; - } - } - return configuration; - } + public ILaunchConfiguration[] getLaunchConfigurations(IEditorPart editorpart) { + return getLaunchConfigurations(getLaunchableResource(editorpart)); + } + + private ILaunchConfiguration getLaunchConfigurations(IProject project) throws CoreException { + ILaunchManager launchManager = DebugPlugin.getDefault().getLaunchManager(); + ILaunchConfigurationType type = launchManager.getLaunchConfigurationType(WidgetLaunchDelegate.ID); + ILaunchConfiguration configuration = null; + ILaunchConfiguration[] configurations = launchManager.getLaunchConfigurations(type); + for (ILaunchConfiguration c : configurations) { + if (project.getName().equals(c.getAttribute(IConstants.PROP_PROJECT_NAME, (String) null))) { + configuration = c; + break; + } + } + return configuration; + } - private ILaunchConfiguration[] getLaunchConfigurations(IResource resource) { - if (resource != null) { - try { - ILaunchConfiguration launchConfigurations = getLaunchConfigurations(resource - .getProject()); - if (launchConfigurations != null) { - return new ILaunchConfiguration[] { launchConfigurations }; - } - } catch (CoreException e) { - Activator.log(e); - } - } - return null; - } + private ILaunchConfiguration[] getLaunchConfigurations(IResource resource) { + if (resource != null) { + try { + ILaunchConfiguration launchConfigurations = getLaunchConfigurations(resource.getProject()); + if (launchConfigurations != null) { + return new ILaunchConfiguration[] { launchConfigurations }; + } + } catch (CoreException e) { + Activator.log(e); + } + } + return null; + } - public ILaunchConfiguration[] getLaunchConfigurations(ISelection selection) { - return getLaunchConfigurations(getLaunchableResource(selection)); - } + public ILaunchConfiguration[] getLaunchConfigurations(ISelection selection) { + return getLaunchConfigurations(getLaunchableResource(selection)); + } - public void launch(IEditorPart editor, String mode) { - launch(getLaunchableResource(editor), mode); - } + public void launch(IEditorPart editor, String mode) { + launch(getLaunchableResource(editor), mode); + } - private void launch(IResource launchableResource, String mode) { - try { - IProject project = launchableResource.getProject(); - ILaunchManager launchManager = DebugPlugin.getDefault() - .getLaunchManager(); - ILaunchConfigurationType type = launchManager - .getLaunchConfigurationType(WidgetLaunchDelegate.ID); - ILaunchConfiguration configuration = getLaunchConfigurations(project); - if (configuration == null) { - ILaunchConfigurationWorkingCopy copy = type - .newInstance( - null, - launchManager - .generateUniqueLaunchConfigurationNameFrom(project - .getName())); - copy.setAttribute(IConstants.PROP_PROJECT_NAME, project - .getName()); - copy.setMappedResources(new IResource[] {project}); - configuration = copy.doSave(); - } - DebugUITools.launch(configuration, mode); - } catch (CoreException e) { - Activator.log(e); - } - } + private void launch(IResource launchableResource, String mode) { + try { + IProject project = launchableResource.getProject(); + ILaunchManager launchManager = DebugPlugin.getDefault().getLaunchManager(); + ILaunchConfigurationType type = launchManager.getLaunchConfigurationType(WidgetLaunchDelegate.ID); + ILaunchConfiguration configuration = getLaunchConfigurations(project); + if (configuration == null) { + ILaunchConfigurationWorkingCopy copy = type.newInstance(null, launchManager + .generateLaunchConfigurationName(project.getName())); + copy.setAttribute(IConstants.PROP_PROJECT_NAME, project.getName()); + copy.setMappedResources(new IResource[] { project }); + configuration = copy.doSave(); + } + DebugUITools.launch(configuration, mode); + } catch (CoreException e) { + Activator.log(e); + } + } - public void launch(ISelection selection, String mode) { - launch(getLaunchableResource(selection), mode); - } + public void launch(ISelection selection, String mode) { + launch(getLaunchableResource(selection), mode); + } } diff -r 11f39c9c3156 -r 25282116ebcf org.symbian.tools.wrttools.doc.WRTKit/build.properties --- a/org.symbian.tools.wrttools.doc.WRTKit/build.properties Tue Apr 20 15:15:32 2010 -0700 +++ b/org.symbian.tools.wrttools.doc.WRTKit/build.properties Tue Apr 20 17:11:57 2010 -0700 @@ -3,4 +3,3 @@ WRT_Doc.xml,\ toc.xml,\ html/ -jars.compile.order = diff -r 11f39c9c3156 -r 25282116ebcf org.symbian.tools.wrttools.doc.WebDeveloper/build.properties --- a/org.symbian.tools.wrttools.doc.WebDeveloper/build.properties Tue Apr 20 15:15:32 2010 -0700 +++ b/org.symbian.tools.wrttools.doc.WebDeveloper/build.properties Tue Apr 20 17:11:57 2010 -0700 @@ -2,4 +2,3 @@ plugin.xml,\ html/,\ toc.xml -jars.compile.order = diff -r 11f39c9c3156 -r 25282116ebcf org.symbian.tools.wrttools.previewer/src/org/symbian/tools/wrttools/previewer/CommandHandlerManager.java --- a/org.symbian.tools.wrttools.previewer/src/org/symbian/tools/wrttools/previewer/CommandHandlerManager.java Tue Apr 20 15:15:32 2010 -0700 +++ b/org.symbian.tools.wrttools.previewer/src/org/symbian/tools/wrttools/previewer/CommandHandlerManager.java Tue Apr 20 17:11:57 2010 -0700 @@ -31,8 +31,7 @@ private Map handlers = null; - @SuppressWarnings("unchecked") - public void handle(String commandName, String projectName, Map parameters) { + public void handle(String commandName, String projectName, Map parameters) { final IPreviewerCommandHandler commandHandler = getCommandMap().get(commandName); if (commandHandler == null) { PreviewerPlugin.log(MessageFormat.format("Command {0} is not handled", commandName), null); diff -r 11f39c9c3156 -r 25282116ebcf org.symbian.tools.wrttools.previewer/src/org/symbian/tools/wrttools/previewer/IPreviewerCommandHandler.java --- a/org.symbian.tools.wrttools.previewer/src/org/symbian/tools/wrttools/previewer/IPreviewerCommandHandler.java Tue Apr 20 15:15:32 2010 -0700 +++ b/org.symbian.tools.wrttools.previewer/src/org/symbian/tools/wrttools/previewer/IPreviewerCommandHandler.java Tue Apr 20 17:11:57 2010 -0700 @@ -21,6 +21,5 @@ import java.util.Map; public interface IPreviewerCommandHandler { - @SuppressWarnings("unchecked") - void handle(String commandName, String projectName, Map parameters); + void handle(String commandName, String projectName, Map parameters); } diff -r 11f39c9c3156 -r 25282116ebcf org.symbian.tools.wrttools.previewer/src/org/symbian/tools/wrttools/previewer/http/WebappManager.java --- a/org.symbian.tools.wrttools.previewer/src/org/symbian/tools/wrttools/previewer/http/WebappManager.java Tue Apr 20 15:15:32 2010 -0700 +++ b/org.symbian.tools.wrttools.previewer/src/org/symbian/tools/wrttools/previewer/http/WebappManager.java Tue Apr 20 17:11:57 2010 -0700 @@ -49,8 +49,8 @@ private static int port = -1; private static final int AUTO_SELECT_JETTY_PORT = 0; - @SuppressWarnings("unchecked") - public static void start(String webappName) throws Exception { + @SuppressWarnings({ "rawtypes", "unchecked" }) + public static void start(String webappName) throws Exception { Dictionary d = new Hashtable(); d.put("http.port", new Integer(getPortParameter())); //$NON-NLS-1$ diff -r 11f39c9c3156 -r 25282116ebcf org.symbian.tools.wrttools.product/build.properties --- a/org.symbian.tools.wrttools.product/build.properties Tue Apr 20 15:15:32 2010 -0700 +++ b/org.symbian.tools.wrttools.product/build.properties Tue Apr 20 17:11:57 2010 -0700 @@ -8,7 +8,6 @@ about.properties,\ about.html,\ plugin.properties,\ - config_inis/,\ splash.bmp source.. = src/ # javac javacSource=1.5 diff -r 11f39c9c3156 -r 25282116ebcf org.symbian.tools.wrttools.product/launch/WRT IDE Product (Windows).launch --- a/org.symbian.tools.wrttools.product/launch/WRT IDE Product (Windows).launch Tue Apr 20 15:15:32 2010 -0700 +++ b/org.symbian.tools.wrttools.product/launch/WRT IDE Product (Windows).launch Tue Apr 20 17:11:57 2010 -0700 @@ -22,474 +22,475 @@ - - + + - + + + + + + + + + + + + + - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + + + + + + + + + + + + + + + + + + + + + - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + + + - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + + + + - - - - - - - - - - - - - - - - - - - - - - - + - - - - - - - - - - - - - - - - - - - - - - - - - - + + - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + - - - - - + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + - - - - + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + - + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff -r 11f39c9c3156 -r 25282116ebcf org.symbian.tools.wrttools.product/plugin.xml --- a/org.symbian.tools.wrttools.product/plugin.xml Tue Apr 20 15:15:32 2010 -0700 +++ b/org.symbian.tools.wrttools.product/plugin.xml Tue Apr 20 17:11:57 2010 -0700 @@ -56,8 +56,7 @@ name="Web"> + id="org.symbian.tools.wrttools.core.wrtwidgetwizard"> @@ -152,7 +151,7 @@ name="WebRuntime Toolkit IDE"> + value="icons/ico/WRT_main-icon_16px.png,icons/ico/WRT_main-icon_32px.png,icons/ico/WRT_main-icon_48px.png,icons/ico/WRT_main-icon_64px.png,icons/ico/WRT_main-icon_128px.png"> + value="icons/WRT_blurb_image.png"> + value="5,245,410,15"> + value="7,220,400,20"> + diff -r 11f39c9c3156 -r 25282116ebcf org.symbian.tools.wrttools/src/org/symbian/tools/wrttools/navigator/WRTNavigatorContentProvider.java --- a/org.symbian.tools.wrttools/src/org/symbian/tools/wrttools/navigator/WRTNavigatorContentProvider.java Tue Apr 20 15:15:32 2010 -0700 +++ b/org.symbian.tools.wrttools/src/org/symbian/tools/wrttools/navigator/WRTNavigatorContentProvider.java Tue Apr 20 17:11:57 2010 -0700 @@ -1,7 +1,5 @@ package org.symbian.tools.wrttools.navigator; -import java.util.Collection; - import org.eclipse.core.resources.IFile; import org.eclipse.core.resources.IFolder; import org.eclipse.core.resources.IResource; @@ -9,7 +7,6 @@ import org.eclipse.core.resources.IResourceChangeListener; import org.eclipse.core.resources.IResourceDelta; import org.eclipse.core.resources.IResourceDeltaVisitor; -import org.eclipse.core.resources.IWorkspace; import org.eclipse.core.resources.IWorkspaceRoot; import org.eclipse.core.resources.ResourcesPlugin; import org.eclipse.core.runtime.CoreException; @@ -18,14 +15,13 @@ import org.eclipse.jface.viewers.TreeViewer; import org.eclipse.jface.viewers.Viewer; import org.eclipse.wst.jsdt.core.IJavaScriptElement; -import org.eclipse.wst.jsdt.core.IJavaScriptModel; import org.eclipse.wst.jsdt.core.IJavaScriptProject; import org.eclipse.wst.jsdt.core.JavaScriptCore; import org.eclipse.wst.jsdt.core.JavaScriptModelException; import org.eclipse.wst.jsdt.internal.ui.navigator.JavaNavigatorContentProvider; import org.symbian.tools.wrttools.Activator; -@SuppressWarnings({"restriction", "unchecked"}) +@SuppressWarnings("restriction") public class WRTNavigatorContentProvider extends JavaNavigatorContentProvider implements ITreeContentProvider { private static final class RootResourceFinder implements @@ -122,40 +118,6 @@ this.viewer = viewer; super.inputChanged(viewer, oldInput, newInput); } - // - // @SuppressWarnings("unchecked") - // @Override - // protected void postAdd(final Object parent, final Object element, - // Collection runnables) { - // final Object p; - // if (element instanceof IProject) { - // p = null; - // } else { - // p = parent; - // } - // runnables.add(new Runnable() { - // @Override - // public void run() { - // if (p != null) { - // ((TreeViewer) viewer).refresh(p); - // } else { - // ((TreeViewer) viewer).refresh(); - // } - // } - // }); - // } - - @Override - protected void postAdd(Object parent, Object element, Collection runnables) { - if (parent instanceof IWorkspace) { - super.postAdd(((IWorkspace) parent).getRoot(), element, runnables); - } else if (parent instanceof IJavaScriptModel) { - super.postAdd(((IJavaScriptModel) parent).getWorkspace().getRoot(), - element, runnables); - } else { - super.postAdd(parent, element, runnables); - } - } protected void refreshViewer(final IResource resource) { viewer.getControl().getDisplay().asyncExec(new Runnable() {