Fixed bug 439579: Creating an "Installed JRE" doesn't associate javafx-src.zip to jfxrt.jar
diff --git a/org.eclipse.jdt.launching/META-INF/MANIFEST.MF b/org.eclipse.jdt.launching/META-INF/MANIFEST.MF
index 00203ec..17c7805 100644
--- a/org.eclipse.jdt.launching/META-INF/MANIFEST.MF
+++ b/org.eclipse.jdt.launching/META-INF/MANIFEST.MF
@@ -2,7 +2,7 @@
 Bundle-ManifestVersion: 2
 Bundle-Name: %pluginName
 Bundle-SymbolicName: org.eclipse.jdt.launching; singleton:=true
-Bundle-Version: 3.7.100.qualifier
+Bundle-Version: 3.7.200.qualifier
 Bundle-Activator: org.eclipse.jdt.internal.launching.LaunchingPlugin
 Bundle-Vendor: %providerName
 Bundle-Localization: plugin
diff --git a/org.eclipse.jdt.launching/launching/org/eclipse/jdt/internal/launching/JavaFxLibraryResolver.java b/org.eclipse.jdt.launching/launching/org/eclipse/jdt/internal/launching/JavaFxLibraryResolver.java
new file mode 100644
index 0000000..8b8adb2
--- /dev/null
+++ b/org.eclipse.jdt.launching/launching/org/eclipse/jdt/internal/launching/JavaFxLibraryResolver.java
@@ -0,0 +1,68 @@
+/*******************************************************************************
+ * Copyright (c) 2014 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.eclipse.jdt.internal.launching;
+
+import java.io.File;
+import java.net.MalformedURLException;
+import java.net.URL;
+
+import org.eclipse.core.runtime.IPath;
+import org.eclipse.core.runtime.Path;
+import org.eclipse.jdt.launching.ILibraryLocationResolver;
+
+public class JavaFxLibraryResolver implements ILibraryLocationResolver {
+
+	private static final String JFXRT_JAR = "jfxrt.jar"; //$NON-NLS-1$
+	private static final String JAVAFX_SRC_ZIP = "javafx-src.zip"; //$NON-NLS-1$
+	private static final String JAVAFX_8_JAVADOC = "http://docs.oracle.com/javase/8/javafx/api/"; //$NON-NLS-1$
+
+	private static boolean isJavaFx(IPath libraryPath) {
+		return JFXRT_JAR.equals(libraryPath.lastSegment());
+	}
+
+	public IPath getPackageRoot(IPath libraryPath) {
+		return Path.EMPTY;
+	}
+
+	public IPath getSourcePath(IPath libraryPath) {
+		if (isJavaFx(libraryPath)) {
+			File parent = libraryPath.toFile().getParentFile();
+			while (parent != null) {
+				File parentsrc = new File(parent, JAVAFX_SRC_ZIP);
+				if (parentsrc.isFile()) {
+					return new Path(parentsrc.getPath());
+				}
+				parent = parent.getParentFile();
+			}
+		}
+		return Path.EMPTY;
+	}
+
+	public URL getJavadocLocation(IPath libraryPath) {
+		if (isJavaFx(libraryPath)) {
+			/*
+			 * TODO: We don't know if JavaSE-1.9 will ship JavaFX in the ext folder as well. If yes, then we have to use something like
+			 * JavaRuntime#getVMInstall(IPath) and IVMInstall2#getJavaVersion() to determine the right Javadoc URL.
+			 */
+			try {
+				return new URL(JAVAFX_8_JAVADOC);
+			}
+			catch (MalformedURLException e) {
+				LaunchingPlugin.log(e);
+			}
+		}
+		return null;
+	}
+
+	public URL getIndexLocation(IPath libraryPath) {
+		return null;
+	}
+}
diff --git a/org.eclipse.jdt.launching/launching/org/eclipse/jdt/internal/launching/StandardVMType.java b/org.eclipse.jdt.launching/launching/org/eclipse/jdt/internal/launching/StandardVMType.java
index dcd7641..424b373 100644
--- a/org.eclipse.jdt.launching/launching/org/eclipse/jdt/internal/launching/StandardVMType.java
+++ b/org.eclipse.jdt.launching/launching/org/eclipse/jdt/internal/launching/StandardVMType.java
@@ -497,13 +497,15 @@
 								IPath packageRoot = Path.EMPTY;
 								URL javadocLocation = null;
 								URL indexLocation = null;
-								for( ILibraryLocationResolver resolver : getLibraryLocationResolvers() ) {
+								for (ILibraryLocationResolver resolver : getLibraryLocationResolvers()) {
 									try {
 										sourcePath = resolver.getSourcePath(libPath);
 										packageRoot = resolver.getPackageRoot(libPath);
 										javadocLocation = resolver.getJavadocLocation(libPath);
 										indexLocation = resolver.getIndexLocation(libPath);
-										break;
+										if (sourcePath != Path.EMPTY || packageRoot != Path.EMPTY || javadocLocation != null || indexLocation != null) {
+											break;
+										}
 									} catch(Exception e) {
 										LaunchingPlugin.log(e);
 									}
diff --git a/org.eclipse.jdt.launching/plugin.xml b/org.eclipse.jdt.launching/plugin.xml
index 2bf3289..7ca00f8 100644
--- a/org.eclipse.jdt.launching/plugin.xml
+++ b/org.eclipse.jdt.launching/plugin.xml
@@ -313,5 +313,11 @@
                resolver="org.eclipse.jdt.internal.launching.ProjectClasspathVariableResolver">
          </variable>
       </extension>
+      <extension
+            point="org.eclipse.jdt.launching.libraryLocationResolvers">
+         <resolver
+               class="org.eclipse.jdt.internal.launching.JavaFxLibraryResolver">
+         </resolver>
+      </extension>
      
 </plugin>
diff --git a/org.eclipse.jdt.launching/pom.xml b/org.eclipse.jdt.launching/pom.xml
index ca3367e..d08f1b2 100644
--- a/org.eclipse.jdt.launching/pom.xml
+++ b/org.eclipse.jdt.launching/pom.xml
@@ -1,6 +1,6 @@
 <?xml version="1.0" encoding="UTF-8"?>
 <!--
-  Copyright (c) 2012, 2013 Eclipse Foundation and others.
+  Copyright (c) 2012, 2014 Eclipse Foundation and others.
   All rights reserved. This program and the accompanying materials
   are made available under the terms of the Eclipse Distribution License v1.0
   which accompanies this distribution, and is available at
@@ -18,7 +18,7 @@
   </parent>
   <groupId>org.eclipse.jdt</groupId>
   <artifactId>org.eclipse.jdt.launching</artifactId>
-  <version>3.7.100-SNAPSHOT</version>
+  <version>3.7.200-SNAPSHOT</version>
   <packaging>eclipse-plugin</packaging>
   
   <build>
diff --git a/org.eclipse.jdt.launching/schema/libraryLocationResolvers.exsd b/org.eclipse.jdt.launching/schema/libraryLocationResolvers.exsd
index 61f02d5..ea4bde1 100644
--- a/org.eclipse.jdt.launching/schema/libraryLocationResolvers.exsd
+++ b/org.eclipse.jdt.launching/schema/libraryLocationResolvers.exsd
@@ -1,7 +1,7 @@
 <?xml version='1.0' encoding='UTF-8'?>
 <!-- Schema file written by PDE -->
 <schema targetNamespace="org.eclipse.jdt.launching" xmlns="http://www.w3.org/2001/XMLSchema">
-<annotation>
+    <annotation>
       <appInfo>
          <meta.schema plugin="org.eclipse.jdt.launching" id="libraryLocationResolvers" name="Library Location Resolver"/>
       </appInfo>
@@ -93,26 +93,6 @@
 
    <annotation>
       <appInfo>
-         <meta.section type="apiinfo"/>
-      </appInfo>
-      <documentation>
-         
-
-
-      </documentation>
-   </annotation>
-
-   <annotation>
-      <appInfo>
-         <meta.section type="implementation"/>
-      </appInfo>
-      <documentation>
-         JDT does not provide any specific library location resolvers.
-      </documentation>
-   </annotation>
-
-   <annotation>
-      <appInfo>
          <meta.section type="copyright"/>
       </appInfo>
       <documentation>