Replace deprecated Platform.find call in platform.ui
Change-Id: I869c7b93b578393dc01344c12f0130422945b3b5
Signed-off-by: Lars Vogel <Lars.Vogel@vogella.com>
diff --git a/bundles/org.eclipse.ui.workbench/Eclipse UI/org/eclipse/ui/internal/BrandingProperties.java b/bundles/org.eclipse.ui.workbench/Eclipse UI/org/eclipse/ui/internal/BrandingProperties.java
index ce6cce2..bb01300 100644
--- a/bundles/org.eclipse.ui.workbench/Eclipse UI/org/eclipse/ui/internal/BrandingProperties.java
+++ b/bundles/org.eclipse.ui.workbench/Eclipse UI/org/eclipse/ui/internal/BrandingProperties.java
@@ -14,9 +14,8 @@
import java.net.URL;
import java.util.ArrayList;
import java.util.StringTokenizer;
-
+import org.eclipse.core.runtime.FileLocator;
import org.eclipse.core.runtime.Path;
-import org.eclipse.core.runtime.Platform;
import org.eclipse.jface.resource.ImageDescriptor;
import org.osgi.framework.Bundle;
@@ -46,7 +45,7 @@
}
} catch (MalformedURLException e) {
if (definingBundle != null) {
- return Platform.find(definingBundle, new Path(value));
+ return FileLocator.find(definingBundle, new Path(value));
}
}
diff --git a/bundles/org.eclipse.ui.workbench/Eclipse UI/org/eclipse/ui/internal/ProductProperties.java b/bundles/org.eclipse.ui.workbench/Eclipse UI/org/eclipse/ui/internal/ProductProperties.java
index 2570faa..bb552c1 100644
--- a/bundles/org.eclipse.ui.workbench/Eclipse UI/org/eclipse/ui/internal/ProductProperties.java
+++ b/bundles/org.eclipse.ui.workbench/Eclipse UI/org/eclipse/ui/internal/ProductProperties.java
@@ -10,6 +10,7 @@
*******************************************************************************/
package org.eclipse.ui.internal;
+import com.ibm.icu.text.MessageFormat;
import java.io.IOException;
import java.io.InputStream;
import java.net.URL;
@@ -17,16 +18,13 @@
import java.util.HashMap;
import java.util.MissingResourceException;
import java.util.PropertyResourceBundle;
-
+import org.eclipse.core.runtime.FileLocator;
import org.eclipse.core.runtime.IProduct;
import org.eclipse.core.runtime.Path;
-import org.eclipse.core.runtime.Platform;
import org.eclipse.jface.resource.ImageDescriptor;
import org.eclipse.ui.branding.IProductConstants;
import org.osgi.framework.Bundle;
-import com.ibm.icu.text.MessageFormat;
-
/**
* A class that converts the strings returned by
* <code>org.eclipse.core.runtime.IProduct.getProperty</code> to the
@@ -61,7 +59,7 @@
private static HashMap mappingsMap = new HashMap(4);
private static String[] loadMappings(Bundle definingBundle) {
- URL location = Platform.find(definingBundle, new Path(
+ URL location = FileLocator.find(definingBundle, new Path(
ABOUT_MAPPINGS));
PropertyResourceBundle bundle = null;
InputStream is;
diff --git a/bundles/org.eclipse.ui.workbench/Eclipse UI/org/eclipse/ui/internal/util/BundleUtility.java b/bundles/org.eclipse.ui.workbench/Eclipse UI/org/eclipse/ui/internal/util/BundleUtility.java
index d41a33b..f120235 100644
--- a/bundles/org.eclipse.ui.workbench/Eclipse UI/org/eclipse/ui/internal/util/BundleUtility.java
+++ b/bundles/org.eclipse.ui.workbench/Eclipse UI/org/eclipse/ui/internal/util/BundleUtility.java
@@ -12,6 +12,7 @@
package org.eclipse.ui.internal.util;
import java.net.URL;
+import org.eclipse.core.runtime.FileLocator;
import org.eclipse.core.runtime.IStatus;
import org.eclipse.core.runtime.Path;
import org.eclipse.core.runtime.Platform;
@@ -61,7 +62,7 @@
if (bundle == null) {
return null;
}
- return Platform.find(bundle, new Path(path));
+ return FileLocator.find(bundle, new Path(path));
}
public static URL find(String bundleId, String path) {