# HG changeset patch
# User TasneemS@US-TASNEEMS
# Date 1264636023 28800
# Node ID a0e2f1f4e2124b2c0d3dc50e1b41cfaf38f7636e
# Parent 0560e98b9bf661317720ffad9f8d87bbb2f21444# Parent e64c52f5ee56b960b999c51bb286a32b88891aaa
Merged
diff -r 0560e98b9bf6 -r a0e2f1f4e212 org.symbian.tools.wrttools.debug.core/src/org/symbian/tools/wrttools/debug/internal/IConstants.java
--- a/org.symbian.tools.wrttools.debug.core/src/org/symbian/tools/wrttools/debug/internal/IConstants.java Wed Jan 27 15:05:37 2010 -0800
+++ b/org.symbian.tools.wrttools.debug.core/src/org/symbian/tools/wrttools/debug/internal/IConstants.java Wed Jan 27 15:47:03 2010 -0800
@@ -20,7 +20,7 @@
public interface IConstants {
String PREF_NAME_CHROME_LOCATION="chrome.location";
+ String PROP_PROJECT_NAME = "projectName";
- String PROP_PROJECT_NAME = "projectName";
- public static final String WRT_PREVIEW_HTML = "wrt_preview_main.html";
+ public static final String WRT_PREVIEW_HTML = "wrt_preview_frame.html";
}
diff -r 0560e98b9bf6 -r a0e2f1f4e212 org.symbian.tools.wrttools.debug.core/src/org/symbian/tools/wrttools/debug/internal/launch/WidgetLaunchDelegate.java
--- a/org.symbian.tools.wrttools.debug.core/src/org/symbian/tools/wrttools/debug/internal/launch/WidgetLaunchDelegate.java Wed Jan 27 15:05:37 2010 -0800
+++ b/org.symbian.tools.wrttools.debug.core/src/org/symbian/tools/wrttools/debug/internal/launch/WidgetLaunchDelegate.java Wed Jan 27 15:47:03 2010 -0800
@@ -27,6 +27,7 @@
import org.eclipse.core.resources.IProject;
import org.eclipse.core.resources.ResourcesPlugin;
import org.eclipse.core.runtime.CoreException;
+import org.eclipse.core.runtime.IPath;
import org.eclipse.core.runtime.IProgressMonitor;
import org.eclipse.core.runtime.IStatus;
import org.eclipse.core.runtime.Status;
@@ -85,12 +86,11 @@
// 2. Start Chrome
synchronized (CHROME_ARGS) { // No chances for collision. Still, better safe then spend several days looking for hard-to-reproduce problem
CHROME_ARGS[EXECUTABLE_ARG_NUM] = browserExecutable;
- CHROME_ARGS[PROFILE_ARG_NUM] = "--user-data-dir=\"" + Activator.getDefault().getStateLocation().append("chromeprofile").toOSString() + "\"";
+ CHROME_ARGS[PROFILE_ARG_NUM] = "--user-data-dir=\"" + getChromeProfilePath() + "\"";
CHROME_ARGS[PORT_ARG_NUM] = "--remote-shell-port=" + port;
CHROME_ARGS[APP_ARG_NUM] = MessageFormat.format("--app={0}", uri.toASCIIString());
try {
- Runtime.getRuntime().exec(CHROME_ARGS, null,
- new File(browserExecutable).getParentFile());
+ Runtime.getRuntime().exec(CHROME_ARGS, null, null);
} catch (IOException e) {
launchManager.removeLaunch(launch);
StringBuffer commandLine = new StringBuffer(CHROME_ARGS[0]);
@@ -109,6 +109,12 @@
}
+ private String getChromeProfilePath() {
+ IPath location = ResourcesPlugin.getWorkspace().getRoot().getLocation();
+ return location.append(".chrome").toOSString();
+ }
+
+
private int findFreePort() {
try {
final ServerSocket socket = new ServerSocket(0);
diff -r 0560e98b9bf6 -r a0e2f1f4e212 org.symbian.tools.wrttools.feature/.project
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/org.symbian.tools.wrttools.feature/.project Wed Jan 27 15:47:03 2010 -0800
@@ -0,0 +1,17 @@
+
+
+ org.symbian.tools.wrttools.feature
+
+
+
+
+
+ org.eclipse.pde.FeatureBuilder
+
+
+
+
+
+ org.eclipse.pde.FeatureNature
+
+
diff -r 0560e98b9bf6 -r a0e2f1f4e212 org.symbian.tools.wrttools.feature/build.properties
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/org.symbian.tools.wrttools.feature/build.properties Wed Jan 27 15:47:03 2010 -0800
@@ -0,0 +1,1 @@
+bin.includes = feature.xml
diff -r 0560e98b9bf6 -r a0e2f1f4e212 org.symbian.tools.wrttools.feature/compile.org.symbian.tools.wrttools.xml
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/org.symbian.tools.wrttools.feature/compile.org.symbian.tools.wrttools.xml Wed Jan 27 15:47:03 2010 -0800
@@ -0,0 +1,9 @@
+
+
+
+
+
+
+
+
+
diff -r 0560e98b9bf6 -r a0e2f1f4e212 org.symbian.tools.wrttools.feature/feature.xml
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/org.symbian.tools.wrttools.feature/feature.xml Wed Jan 27 15:47:03 2010 -0800
@@ -0,0 +1,56 @@
+
+
+
+
+ [Enter Feature Description here.]
+
+
+
+ [Enter Copyright Description here.]
+
+
+
+ [Enter License Description here.]
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff -r 0560e98b9bf6 -r a0e2f1f4e212 org.symbian.tools.wrttools.jseditors/META-INF/MANIFEST.MF
--- a/org.symbian.tools.wrttools.jseditors/META-INF/MANIFEST.MF Wed Jan 27 15:05:37 2010 -0800
+++ b/org.symbian.tools.wrttools.jseditors/META-INF/MANIFEST.MF Wed Jan 27 15:47:03 2010 -0800
@@ -15,7 +15,6 @@
org.eclipse.ui.intro,
org.eclipse.ui.intro.universal,
org.eclipse.ui.console,
- org.eclipse.jdt.ui,
org.eclipse.swt,
org.eclipse.jface,
org.eclipse.ui.workbench
diff -r 0560e98b9bf6 -r a0e2f1f4e212 org.symbian.tools.wrttools.jseditors/src/org/symbian/tools/wrttools/jseditors/perspectives/RelEngPerspective.java
--- a/org.symbian.tools.wrttools.jseditors/src/org/symbian/tools/wrttools/jseditors/perspectives/RelEngPerspective.java Wed Jan 27 15:05:37 2010 -0800
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
@@ -1,128 +0,0 @@
-/**
- * Copyright (c) 2009 Symbian Foundation and/or its subsidiary(-ies).
- * All rights reserved.
- * This component and the accompanying materials are made available
- * under the terms of the License "Eclipse Public License v1.0"
- * which accompanies this distribution, and is available
- * at the URL "http://www.eclipse.org/legal/epl-v10.html".
- *
- * Initial Contributors:
- * Symbian Foundation - initial contribution.
- * Contributors:
- * Description:
- * Overview:
- * Details:
- * Platforms/Drives/Compatibility:
- * Assumptions/Requirement/Pre-requisites:
- * Failures and causes:
- */
-
-/*******************************************************************************
- * Copyright (c) 2006 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
- *******************************************************************************/
-package org.symbian.tools.wrttools.jseditors.perspectives;
-
-import org.eclipse.ui.IFolderLayout;
-import org.eclipse.ui.IPageLayout;
-import org.eclipse.ui.IPerspectiveFactory;
-import org.eclipse.ui.console.IConsoleConstants;
-import org.eclipse.jdt.ui.JavaUI;
-
-
-/**
- * This class is meant to serve as an example for how various contributions
- * are made to a perspective. Note that some of the extension point id's are
- * referred to as API constants while others are hardcoded and may be subject
- * to change.
- */
-public class RelEngPerspective implements IPerspectiveFactory {
-
- private IPageLayout factory;
-
- public RelEngPerspective() {
- super();
- }
-
- public void createInitialLayout(IPageLayout factory) {
- this.factory = factory;
- addViews();
- addActionSets();
- addNewWizardShortcuts();
- addPerspectiveShortcuts();
- addViewShortcuts();
- }
-
- private void addViews() {
- // Creates the overall folder layout.
- // Note that each new Folder uses a percentage of the remaining EditorArea.
-
- IFolderLayout bottom =
- factory.createFolder(
- "bottomRight", //NON-NLS-1
- IPageLayout.BOTTOM,
- 0.75f,
- factory.getEditorArea());
- bottom.addView(IPageLayout.ID_PROBLEM_VIEW);
- bottom.addView("org.eclipse.team.ui.GenericHistoryView"); //NON-NLS-1
- bottom.addPlaceholder(IConsoleConstants.ID_CONSOLE_VIEW);
-
- IFolderLayout topLeft =
- factory.createFolder(
- "topLeft", //NON-NLS-1
- IPageLayout.LEFT,
- 0.25f,
- factory.getEditorArea());
- topLeft.addView(IPageLayout.ID_RES_NAV);
- topLeft.addView("org.eclipse.jdt.junit.ResultView"); //NON-NLS-1
-
- factory.addFastView("org.eclipse.team.ccvs.ui.RepositoriesView",0.50f); //NON-NLS-1
- factory.addFastView("org.eclipse.team.sync.views.SynchronizeView", 0.50f); //NON-NLS-1
- }
-
- private void addActionSets() {
- factory.addActionSet("org.eclipse.debug.ui.launchActionSet"); //NON-NLS-1
- factory.addActionSet("org.eclipse.debug.ui.debugActionSet"); //NON-NLS-1
- factory.addActionSet("org.eclipse.debug.ui.profileActionSet"); //NON-NLS-1
- factory.addActionSet("org.eclipse.jdt.debug.ui.JDTDebugActionSet"); //NON-NLS-1
- factory.addActionSet("org.eclipse.jdt.junit.JUnitActionSet"); //NON-NLS-1
- factory.addActionSet("org.eclipse.team.ui.actionSet"); //NON-NLS-1
- factory.addActionSet("org.eclipse.team.cvs.ui.CVSActionSet"); //NON-NLS-1
- factory.addActionSet("org.eclipse.ant.ui.actionSet.presentation"); //NON-NLS-1
- factory.addActionSet(JavaUI.ID_ACTION_SET);
- factory.addActionSet(JavaUI.ID_ELEMENT_CREATION_ACTION_SET);
- factory.addActionSet(IPageLayout.ID_NAVIGATE_ACTION_SET); //NON-NLS-1
- }
-
- private void addPerspectiveShortcuts() {
- factory.addPerspectiveShortcut("org.eclipse.team.ui.TeamSynchronizingPerspective"); //NON-NLS-1
- factory.addPerspectiveShortcut("org.eclipse.team.cvs.ui.cvsPerspective"); //NON-NLS-1
- factory.addPerspectiveShortcut("org.eclipse.ui.resourcePerspective"); //NON-NLS-1
- }
-
- private void addNewWizardShortcuts() {
- factory.addNewWizardShortcut("org.eclipse.team.cvs.ui.newProjectCheckout");//NON-NLS-1
- factory.addNewWizardShortcut("org.eclipse.ui.wizards.new.folder");//NON-NLS-1
- factory.addNewWizardShortcut("org.eclipse.ui.wizards.new.file");//NON-NLS-1
- }
-
- private void addViewShortcuts() {
- factory.addShowViewShortcut("org.eclipse.ant.ui.views.AntView"); //NON-NLS-1
- factory.addShowViewShortcut("org.eclipse.team.ccvs.ui.AnnotateView"); //NON-NLS-1
- factory.addShowViewShortcut("org.eclipse.pde.ui.DependenciesView"); //NON-NLS-1
- factory.addShowViewShortcut("org.eclipse.jdt.junit.ResultView"); //NON-NLS-1
- factory.addShowViewShortcut("org.eclipse.team.ui.GenericHistoryView"); //NON-NLS-1
- factory.addShowViewShortcut(IConsoleConstants.ID_CONSOLE_VIEW);
- factory.addShowViewShortcut(JavaUI.ID_PACKAGES);
- factory.addShowViewShortcut(IPageLayout.ID_RES_NAV);
- factory.addShowViewShortcut(IPageLayout.ID_PROBLEM_VIEW);
- factory.addShowViewShortcut(IPageLayout.ID_OUTLINE);
- }
-
-}
diff -r 0560e98b9bf6 -r a0e2f1f4e212 org.symbian.tools.wrttools.previewer/META-INF/MANIFEST.MF
--- a/org.symbian.tools.wrttools.previewer/META-INF/MANIFEST.MF Wed Jan 27 15:05:37 2010 -0800
+++ b/org.symbian.tools.wrttools.previewer/META-INF/MANIFEST.MF Wed Jan 27 15:47:03 2010 -0800
@@ -9,7 +9,9 @@
org.eclipse.core.resources;bundle-version="3.5.0",
org.eclipse.core.net;bundle-version="1.2.0",
org.mozilla.xpcom;bundle-version="1.9.1",
- org.eclipse.equinox.http.jetty;bundle-version="2.0.0"
+ org.eclipse.equinox.http.jetty;bundle-version="2.0.0",
+ org.eclipse.wst.jsdt.core;bundle-version="1.0.201",
+ org.eclipse.wst.jsdt.ui;bundle-version="1.0.200"
Bundle-ActivationPolicy: lazy
Bundle-RequiredExecutionEnvironment: JavaSE-1.6
Export-Package: org.symbian.tools.wrttools.previewer,
diff -r 0560e98b9bf6 -r a0e2f1f4e212 org.symbian.tools.wrttools.previewer/build.properties
--- a/org.symbian.tools.wrttools.previewer/build.properties Wed Jan 27 15:05:37 2010 -0800
+++ b/org.symbian.tools.wrttools.previewer/build.properties Wed Jan 27 15:47:03 2010 -0800
@@ -6,4 +6,5 @@
preview/,\
preferences.ini,\
icons/,\
- wrt.xml
+ wrt.xml,\
+ http-content/
diff -r 0560e98b9bf6 -r a0e2f1f4e212 org.symbian.tools.wrttools.previewer/src/org/symbian/tools/wrttools/previewer/http/WorkspaceResourcesServlet.java
--- a/org.symbian.tools.wrttools.previewer/src/org/symbian/tools/wrttools/previewer/http/WorkspaceResourcesServlet.java Wed Jan 27 15:05:37 2010 -0800
+++ b/org.symbian.tools.wrttools.previewer/src/org/symbian/tools/wrttools/previewer/http/WorkspaceResourcesServlet.java Wed Jan 27 15:47:03 2010 -0800
@@ -71,7 +71,6 @@
if (contents != null) {
copyData(contents, resp.getOutputStream());
} else {
- System.err.println(path);
resp.setStatus(HttpServletResponse.SC_NOT_FOUND);
}
} catch (CoreException e) {
diff -r 0560e98b9bf6 -r a0e2f1f4e212 org.symbian.tools.wrttools.previewer/src/org/symbian/tools/wrttools/previewer/jsdt/WrtContainerInitializer.java
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/org.symbian.tools.wrttools.previewer/src/org/symbian/tools/wrttools/previewer/jsdt/WrtContainerInitializer.java Wed Jan 27 15:47:03 2010 -0800
@@ -0,0 +1,25 @@
+package org.symbian.tools.wrttools.previewer.jsdt;
+
+import org.eclipse.core.runtime.IPath;
+import org.eclipse.wst.jsdt.core.IJavaScriptProject;
+import org.eclipse.wst.jsdt.core.JsGlobalScopeContainerInitializer;
+import org.eclipse.wst.jsdt.core.compiler.libraries.LibraryLocation;
+
+public class WrtContainerInitializer extends JsGlobalScopeContainerInitializer {
+ public static final String CONTAINER_ID = "org.symbian.wrt";
+
+ @Override
+ public LibraryLocation getLibraryLocation() {
+ return new WrtLibraryLocation();
+ }
+
+ @Override
+ public String getDescription() {
+ return "WebRuntime Support Library";
+ }
+
+ @Override
+ public String getDescription(IPath containerPath, IJavaScriptProject project) {
+ return getDescription();
+ }
+}
diff -r 0560e98b9bf6 -r a0e2f1f4e212 org.symbian.tools.wrttools.previewer/src/org/symbian/tools/wrttools/previewer/jsdt/WrtLibraryLocation.java
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/org.symbian.tools.wrttools.previewer/src/org/symbian/tools/wrttools/previewer/jsdt/WrtLibraryLocation.java Wed Jan 27 15:47:03 2010 -0800
@@ -0,0 +1,60 @@
+package org.symbian.tools.wrttools.previewer.jsdt;
+
+import java.io.IOException;
+import java.net.URL;
+
+import org.eclipse.core.runtime.FileLocator;
+import org.eclipse.core.runtime.IPath;
+import org.eclipse.core.runtime.Path;
+import org.eclipse.wst.jsdt.core.compiler.libraries.LibraryLocation;
+import org.symbian.tools.wrttools.previewer.PreviewerPlugin;
+
+public class WrtLibraryLocation implements LibraryLocation {
+ private static final Path LIBRARIES_PATH = new Path("/preview/script/lib");
+ private static final char[][] FILE_NAMES = {
+ "console.js".toCharArray(),
+ "device.js".toCharArray(),
+ "loader.js".toCharArray(),
+ "menu.js".toCharArray(),
+ "menuItem.js".toCharArray(),
+ "systeminfo.js".toCharArray(),
+ "widget.js".toCharArray(),
+ };
+
+ @Override
+ public char[][] getLibraryFileNames() {
+ return FILE_NAMES;
+ }
+
+ @Override
+ public String getLibraryPath(String name) {
+ System.out.println(name);
+ return null;
+ }
+
+ @Override
+ public String getLibraryPath(char[] name) {
+ URL entry = FileLocator.find(PreviewerPlugin.getDefault().getBundle(), LIBRARIES_PATH.append(new String(name)), null);
+ if (entry != null) {
+ try {
+ URL fileURL = FileLocator.toFileURL(entry);
+ final IPath path = new Path(fileURL.getPath());
+ return path.toString();
+ } catch (IOException e) {
+ PreviewerPlugin.log(e);
+ }
+ }
+ return null;
+ }
+
+ @Override
+ public IPath getLibraryPathInPlugin() {
+ return LIBRARIES_PATH;
+ }
+
+ @Override
+ public IPath getWorkingLibPath() {
+ return new Path(getLibraryPath(""));
+ }
+
+}
diff -r 0560e98b9bf6 -r a0e2f1f4e212 org.symbian.tools.wrttools.previewer/src/org/symbian/tools/wrttools/previewer/jsdt/WrtLibraryWizardPage.java
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/org.symbian.tools.wrttools.previewer/src/org/symbian/tools/wrttools/previewer/jsdt/WrtLibraryWizardPage.java Wed Jan 27 15:47:03 2010 -0800
@@ -0,0 +1,69 @@
+package org.symbian.tools.wrttools.previewer.jsdt;
+
+import org.eclipse.core.runtime.Path;
+import org.eclipse.jface.dialogs.Dialog;
+import org.eclipse.swt.SWT;
+import org.eclipse.swt.widgets.Composite;
+import org.eclipse.wst.jsdt.core.IIncludePathEntry;
+import org.eclipse.wst.jsdt.core.IJavaScriptProject;
+import org.eclipse.wst.jsdt.core.JavaScriptCore;
+import org.eclipse.wst.jsdt.internal.ui.wizards.dialogfields.DialogField;
+import org.eclipse.wst.jsdt.internal.ui.wizards.dialogfields.LayoutUtil;
+import org.eclipse.wst.jsdt.ui.wizards.IJsGlobalScopeContainerPage;
+import org.eclipse.wst.jsdt.ui.wizards.IJsGlobalScopeContainerPageExtension;
+import org.eclipse.wst.jsdt.ui.wizards.IJsGlobalScopeContainerPageExtension2;
+import org.eclipse.wst.jsdt.ui.wizards.NewElementWizardPage;
+
+/**
+ * Wizard page for adding IE library support to the project.
+ */
+public class WrtLibraryWizardPage extends NewElementWizardPage implements
+ IJsGlobalScopeContainerPage, IJsGlobalScopeContainerPageExtension,
+ IJsGlobalScopeContainerPageExtension2 {
+
+ private static final String CONTAINER_ID = WrtContainerInitializer.CONTAINER_ID;
+
+ public WrtLibraryWizardPage() {
+ super("InternetExplorerBrowserLib");
+ setTitle("WRT Library");
+ // setImageDescriptor(JavaPluginImages.DESC_WIZBAN_ADD_LIBRARY);
+ }
+
+ public boolean finish() {
+ return true;
+ }
+
+ public IIncludePathEntry getSelection() {
+ System.out
+ .println("Unimplemented method:BaseLibraryWizardPage.getSelection");
+ return null;
+ }
+
+ public void setSelection(IIncludePathEntry containerEntry) {
+ }
+
+ public void createControl(Composite parent) {
+ Composite composite = new Composite(parent, SWT.NONE);
+ composite.setFont(parent.getFont());
+ DialogField field = new DialogField();
+
+ field
+ .setLabelText("WRT Library added to Project.\n\n - This library supports WRT APIs for Symbian platform.");
+ LayoutUtil.doDefaultLayout(composite, new DialogField[] { field },
+ false, SWT.DEFAULT, SWT.DEFAULT);
+ Dialog.applyDialogFont(composite);
+ setControl(composite);
+ setDescription("WebRuntime Libraries");
+ }
+
+ public void initialize(IJavaScriptProject project,
+ IIncludePathEntry[] currentEntries) {
+ // nothing to initialize
+ }
+
+ public IIncludePathEntry[] getNewContainers() {
+ IIncludePathEntry library = JavaScriptCore.newContainerEntry(new Path(
+ CONTAINER_ID));
+ return new IIncludePathEntry[] { library };
+ }
+}
diff -r 0560e98b9bf6 -r a0e2f1f4e212 org.symbian.tools.wrttools.previewer/src/org/symbian/tools/wrttools/previewer/preview/PreviewPage.java
--- a/org.symbian.tools.wrttools.previewer/src/org/symbian/tools/wrttools/previewer/preview/PreviewPage.java Wed Jan 27 15:05:37 2010 -0800
+++ b/org.symbian.tools.wrttools.previewer/src/org/symbian/tools/wrttools/previewer/preview/PreviewPage.java Wed Jan 27 15:47:03 2010 -0800
@@ -217,7 +217,6 @@
}
private void applyProxySettings() {
-
IProxyService px = PreviewerPlugin.getDefault().getProxyService();
if(px != null){
boolean proxyEnabled = px.isProxiesEnabled();
diff -r 0560e98b9bf6 -r a0e2f1f4e212 org.symbian.tools.wrttools.previewer/src/org/symbian/tools/wrttools/previewer/preview/PreviewView.java
--- a/org.symbian.tools.wrttools.previewer/src/org/symbian/tools/wrttools/previewer/preview/PreviewView.java Wed Jan 27 15:05:37 2010 -0800
+++ b/org.symbian.tools.wrttools.previewer/src/org/symbian/tools/wrttools/previewer/preview/PreviewView.java Wed Jan 27 15:47:03 2010 -0800
@@ -183,7 +183,7 @@
}
private boolean isWrtProject(IProject project) {
- return project.getFile("wrt_preview_main.html").exists();
+ return project.getFile("wrt_preview_frame.html").exists();
}
private void loadPreferences() {
diff -r 0560e98b9bf6 -r a0e2f1f4e212 org.symbian.tools.wrttools.product/launch/WRT IDE (Product).launch
--- a/org.symbian.tools.wrttools.product/launch/WRT IDE (Product).launch Wed Jan 27 15:05:37 2010 -0800
+++ b/org.symbian.tools.wrttools.product/launch/WRT IDE (Product).launch Wed Jan 27 15:47:03 2010 -0800
@@ -1,32 +1,32 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff -r 0560e98b9bf6 -r a0e2f1f4e212 org.symbian.tools.wrttools.product/wrt-ide.product
--- a/org.symbian.tools.wrttools.product/wrt-ide.product Wed Jan 27 15:05:37 2010 -0800
+++ b/org.symbian.tools.wrttools.product/wrt-ide.product Wed Jan 27 15:47:03 2010 -0800
@@ -46,7 +46,6 @@
-
@@ -73,7 +72,7 @@
-
+
@@ -196,11 +195,9 @@
-
-
@@ -275,7 +272,6 @@
-
diff -r 0560e98b9bf6 -r a0e2f1f4e212 org.symbian.tools.wrttools/plugin.xml
--- a/org.symbian.tools.wrttools/plugin.xml Wed Jan 27 15:05:37 2010 -0800
+++ b/org.symbian.tools.wrttools/plugin.xml Wed Jan 27 15:47:03 2010 -0800
@@ -212,30 +212,35 @@
-
+
-
-
-
-
+
+
+
+
+
+
+
+
+
-
+ id="org.eclipse.wst.jsdt.ui.navigator.actions.StandardActions">
+
{
+ private IResource getCommonAncestor(IResource r1, IResource r2) {
+ if (r1 == null) {
+ return r2;
+ }
+ if (r2 == null) {
+ return null;
+ }
+ if (r1.equals(r2)) {
+ return r1;
+ }
+ IPath p1 = r1.getFullPath();
+ IPath p2 = r2.getFullPath();
+ int l1 = p1.segmentCount();
+ int l2 = p2.segmentCount();
+
+ if (l1 == 0 || l2 == 0) {
+ return null;
+ }
+ int l = Math.min(l1, l2);
+ do {
+ p1 = p1.uptoSegment(l);
+ p2 = p2.uptoSegment(l);
+ l = l - 1;
+ } while (l > 0 && (p1 != p2));
+ IWorkspaceRoot r = r1.getWorkspace().getRoot();
+ return l == 0 ? null : l == 1 ? r.getProject(p1.lastSegment()) : r
+ .getFolder(p1);
+ }
+
+ @Override
+ public boolean visit(IResourceDelta delta) throws CoreException {
+ if ((delta.getKind() & (IResourceDelta.ADDED | IResourceDelta.REMOVED)) != 0) {
+ resource = getCommonAncestor(resource, delta.getResource()
+ .getParent());
+ return false;
+ }
+ return true;
+ }
+ }
+
+ private static final class TreeElementsComparator implements
+ Comparator