diff options
author | Andrew Niefer | 2007-03-13 21:57:16 +0000 |
---|---|---|
committer | Andrew Niefer | 2007-03-13 21:57:16 +0000 |
commit | 3cf8518912fb064f582a5fa3b7ef020b2155e1b6 (patch) | |
tree | 44287c0f9863f02088a18051335d97a089a631a3 /bundles/org.eclipse.equinox.launcher | |
parent | 3c156e8434744738d7dc6ca7941378119d19f1a8 (diff) | |
download | rt.equinox.framework-3cf8518912fb064f582a5fa3b7ef020b2155e1b6.tar.gz rt.equinox.framework-3cf8518912fb064f582a5fa3b7ef020b2155e1b6.tar.xz rt.equinox.framework-3cf8518912fb064f582a5fa3b7ef020b2155e1b6.zip |
bug 172367 - WPF port
Diffstat (limited to 'bundles/org.eclipse.equinox.launcher')
10 files changed, 239 insertions, 3 deletions
diff --git a/bundles/org.eclipse.equinox.launcher/.cproject b/bundles/org.eclipse.equinox.launcher/.cproject new file mode 100644 index 000000000..36b45a49d --- /dev/null +++ b/bundles/org.eclipse.equinox.launcher/.cproject @@ -0,0 +1,120 @@ +<?xml version="1.0" encoding="UTF-8"?> +<?fileVersion 4.0.0?> + +<cproject> +<storageModule moduleId="org.eclipse.cdt.core.settings"> +<cconfiguration id="converted.config.1529602833"> +<storageModule moduleId="scannerConfiguration"> +<autodiscovery enabled="true" problemReportingEnabled="true" selectedProfileId="org.eclipse.cdt.make.core.GCCStandardMakePerProjectProfile"/> +<profile id="org.eclipse.cdt.make.core.GCCStandardMakePerProjectProfile"> +<buildOutputProvider> +<openAction enabled="true" filePath=""/> +<parser enabled="true"/> +</buildOutputProvider> +<scannerInfoProvider id="specsFile"> +<runAction arguments="-E -P -v -dD ${plugin_state_location}/${specs_file}" command="gcc" useDefault="true"/> +<parser enabled="true"/> +</scannerInfoProvider> +</profile> +<profile id="org.eclipse.cdt.make.core.GCCStandardMakePerFileProfile"> +<buildOutputProvider> +<openAction enabled="false" filePath=""/> +<parser enabled="true"/> +</buildOutputProvider> +<scannerInfoProvider id="makefileGenerator"> +<runAction arguments="-f ${project_name}_scd.mk" command="make" useDefault="true"/> +<parser enabled="false"/> +</scannerInfoProvider> +</profile> +<profile id="org.eclipse.cdt.managedbuilder.core.GCCManagedMakePerProjectProfile"> +<buildOutputProvider> +<openAction enabled="false" filePath=""/> +<parser enabled="true"/> +</buildOutputProvider> +<scannerInfoProvider id="specsFile"> +<runAction arguments="-E -P -v -dD ${plugin_state_location}/${specs_file}" command="gcc" useDefault="true"/> +<parser enabled="false"/> +</scannerInfoProvider> +</profile> +<profile id="org.eclipse.cdt.managedbuilder.core.GCCWinManagedMakePerProjectProfile"> +<buildOutputProvider> +<openAction enabled="false" filePath=""/> +<parser enabled="true"/> +</buildOutputProvider> +<scannerInfoProvider id="specsFile"> +<runAction arguments="-E -P -v -dD ${plugin_state_location}/${specs_file}" command="gcc" useDefault="true"/> +<parser enabled="false"/> +</scannerInfoProvider> +</profile> +</storageModule> +<storageModule moduleId="org.eclipse.cdt.core.pathentry"> +<pathentry kind="src" path=""/> +<pathentry kind="out" path=""/> +<pathentry kind="con" path="org.eclipse.cdt.make.core.DISCOVERED_SCANNER_INFO"/> +</storageModule> +<storageModule moduleId="org.eclipse.cdt.make.core.buildtargets"> +<buildTargets> +<target name="all-mingw" path="library/win32" targetID="org.eclipse.cdt.make.MakeTargetBuilder"> +<buildCommand>make</buildCommand> +<buildArguments>-f make_mingw.mak</buildArguments> +<buildTarget>all</buildTarget> +<stopOnError>false</stopOnError> +<useDefaultCommand>false</useDefaultCommand> +</target> +<target name="clean" path="library/win32" targetID="org.eclipse.cdt.make.MakeTargetBuilder"> +<buildCommand>make</buildCommand> +<buildArguments>-f make_mingw.mak</buildArguments> +<buildTarget>clean</buildTarget> +<stopOnError>false</stopOnError> +<useDefaultCommand>false</useDefaultCommand> +</target> +<target name="linux-all" path="library/gtk" targetID="org.eclipse.cdt.make.MakeTargetBuilder"> +<buildCommand>make</buildCommand> +<buildArguments>-f make_linux.mak</buildArguments> +<buildTarget>all</buildTarget> +<stopOnError>false</stopOnError> +<useDefaultCommand>false</useDefaultCommand> +</target> +<target name="clean" path="library/gtk" targetID="org.eclipse.cdt.make.MakeTargetBuilder"> +<buildCommand>make</buildCommand> +<buildArguments>-f make_linux.mak</buildArguments> +<buildTarget>clean</buildTarget> +<stopOnError>false</stopOnError> +<useDefaultCommand>false</useDefaultCommand> +</target> +<target name="all" path="library/carbon" targetID="org.eclipse.cdt.make.MakeTargetBuilder"> +<buildCommand>make</buildCommand> +<buildArguments>-f make_macosx.mak</buildArguments> +<buildTarget>all</buildTarget> +<stopOnError>false</stopOnError> +<useDefaultCommand>false</useDefaultCommand> +</target> +<target name="clean" path="library/carbon" targetID="org.eclipse.cdt.make.MakeTargetBuilder"> +<buildCommand>make</buildCommand> +<buildArguments>-f make_macosx.mak</buildArguments> +<buildTarget>clean</buildTarget> +<stopOnError>false</stopOnError> +<useDefaultCommand>false</useDefaultCommand> +</target> +<target name="linux-all" path="library/motif" targetID="org.eclipse.cdt.make.MakeTargetBuilder"> +<buildCommand>make</buildCommand> +<buildArguments>-f make_linux.mak</buildArguments> +<buildTarget>all</buildTarget> +<stopOnError>false</stopOnError> +<useDefaultCommand>false</useDefaultCommand> +</target> +</buildTargets> +</storageModule> +<storageModule buildSystemId="org.eclipse.cdt.core.defaultConfigDataProvider" id="converted.config.1529602833" moduleId="org.eclipse.cdt.core.settings" name="convertedConfig"> +<externalSettings/> +<extensions> +<extension id="org.eclipse.cdt.core.ELF" point="org.eclipse.cdt.core.BinaryParser"/> +<extension id="org.eclipse.cdt.core.PE" point="org.eclipse.cdt.core.BinaryParser"/> +<extension id="org.eclipse.cdt.core.MachO" point="org.eclipse.cdt.core.BinaryParser"> +<attribute key="c++filt" value="c++filt"/> +</extension> +</extensions> +</storageModule> +</cconfiguration> +</storageModule> +</cproject> diff --git a/bundles/org.eclipse.equinox.launcher/META-INF/MANIFEST.MF b/bundles/org.eclipse.equinox.launcher/META-INF/MANIFEST.MF index 694929397..2bf25da43 100644 --- a/bundles/org.eclipse.equinox.launcher/META-INF/MANIFEST.MF +++ b/bundles/org.eclipse.equinox.launcher/META-INF/MANIFEST.MF @@ -10,3 +10,6 @@ Bundle-RequiredExecutionEnvironment: J2SE-1.4, CDC-1.0/Foundation-1.0, J2SE-1.3 Bundle-Localization: launcher +Export-Package: org.eclipse.core.launcher;x-internal:=true, + org.eclipse.equinox.internal.launcher;x-internal:=true, + org.eclipse.equinox.launcher;x-internal:=true diff --git a/bundles/org.eclipse.equinox.launcher/fragments/org.eclipse.equinox.launcher.wpf.win32.x86/.classpath b/bundles/org.eclipse.equinox.launcher/fragments/org.eclipse.equinox.launcher.wpf.win32.x86/.classpath new file mode 100644 index 000000000..751c8f2e5 --- /dev/null +++ b/bundles/org.eclipse.equinox.launcher/fragments/org.eclipse.equinox.launcher.wpf.win32.x86/.classpath @@ -0,0 +1,7 @@ +<?xml version="1.0" encoding="UTF-8"?> +<classpath> + <classpathentry kind="src" path="src"/> + <classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER"/> + <classpathentry kind="con" path="org.eclipse.pde.core.requiredPlugins"/> + <classpathentry kind="output" path="bin"/> +</classpath> diff --git a/bundles/org.eclipse.equinox.launcher/fragments/org.eclipse.equinox.launcher.wpf.win32.x86/.project b/bundles/org.eclipse.equinox.launcher/fragments/org.eclipse.equinox.launcher.wpf.win32.x86/.project new file mode 100644 index 000000000..7e2a5e42a --- /dev/null +++ b/bundles/org.eclipse.equinox.launcher/fragments/org.eclipse.equinox.launcher.wpf.win32.x86/.project @@ -0,0 +1,28 @@ +<?xml version="1.0" encoding="UTF-8"?> +<projectDescription> + <name>org.eclipse.equinox.launcher.wpf.win32.x86</name> + <comment></comment> + <projects> + </projects> + <buildSpec> + <buildCommand> + <name>org.eclipse.jdt.core.javabuilder</name> + <arguments> + </arguments> + </buildCommand> + <buildCommand> + <name>org.eclipse.pde.ManifestBuilder</name> + <arguments> + </arguments> + </buildCommand> + <buildCommand> + <name>org.eclipse.pde.SchemaBuilder</name> + <arguments> + </arguments> + </buildCommand> + </buildSpec> + <natures> + <nature>org.eclipse.pde.PluginNature</nature> + <nature>org.eclipse.jdt.core.javanature</nature> + </natures> +</projectDescription> diff --git a/bundles/org.eclipse.equinox.launcher/fragments/org.eclipse.equinox.launcher.wpf.win32.x86/META-INF/MANIFEST.MF b/bundles/org.eclipse.equinox.launcher/fragments/org.eclipse.equinox.launcher.wpf.win32.x86/META-INF/MANIFEST.MF new file mode 100644 index 000000000..3cdf1d54d --- /dev/null +++ b/bundles/org.eclipse.equinox.launcher/fragments/org.eclipse.equinox.launcher.wpf.win32.x86/META-INF/MANIFEST.MF @@ -0,0 +1,9 @@ +Manifest-Version: 1.0 +Bundle-ManifestVersion: 2 +Bundle-Name: %pluginName +Bundle-Vendor: %providerName +Bundle-SymbolicName: org.eclipse.equinox.launcher.wpf.win32.x86; singleton:=true +Bundle-Version: 1.0.0.qualifier +Fragment-Host: org.eclipse.equinox.launcher;bundle-version="1.0.0" +Eclipse-PlatformFilter: (& (osgi.ws=wpf) (osgi.os=win32) (osgi.arch=x86)) +Bundle-Localization: launcher.wpf.win32.x86 diff --git a/bundles/org.eclipse.equinox.launcher/fragments/org.eclipse.equinox.launcher.wpf.win32.x86/about.html b/bundles/org.eclipse.equinox.launcher/fragments/org.eclipse.equinox.launcher.wpf.win32.x86/about.html new file mode 100644 index 000000000..395df3ba9 --- /dev/null +++ b/bundles/org.eclipse.equinox.launcher/fragments/org.eclipse.equinox.launcher.wpf.win32.x86/about.html @@ -0,0 +1,28 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" + "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"> +<head> +<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1"/> +<title>About</title> +</head> +<body lang="EN-US"> +<h2>About This Content</h2> + +<p>June 5, 2006</p> +<h3>License</h3> + +<p>The Eclipse Foundation makes available all content in this plug-in ("Content"). +Unless otherwise indicated below, the Content is provided to you under the terms and conditions of the +Eclipse Public License Version 1.0 ("EPL"). A copy of the EPL is available +at <a href="http://www.eclipse.org/org/documents/epl-v10.php">http://www.eclipse.org/legal/epl-v10.html</a>. +For purposes of the EPL, "Program" will mean the Content.</p> + +<p>If you did not receive this Content directly from the Eclipse Foundation, the Content is +being redistributed by another party ("Redistributor") and different terms and conditions may +apply to your use of any object code in the Content. Check the Redistributor’s license +that was provided with the Content. If no such license exists, contact the Redistributor. Unless otherwise +indicated below, the terms and conditions of the EPL still apply to any source code in the Content +and such source code may be obtained at <a href="http://www.eclipse.org/">http://www.eclipse.org</a>.</p> + +</body> +</html>
\ No newline at end of file diff --git a/bundles/org.eclipse.equinox.launcher/fragments/org.eclipse.equinox.launcher.wpf.win32.x86/build.properties b/bundles/org.eclipse.equinox.launcher/fragments/org.eclipse.equinox.launcher.wpf.win32.x86/build.properties new file mode 100644 index 000000000..a581c0114 --- /dev/null +++ b/bundles/org.eclipse.equinox.launcher/fragments/org.eclipse.equinox.launcher.wpf.win32.x86/build.properties @@ -0,0 +1,5 @@ +bin.includes = META-INF/,\ + eclipse_*.dll,\ + com_*.dll,\ + launcher.wpf.win32.x86.properties,\ + about.html diff --git a/bundles/org.eclipse.equinox.launcher/fragments/org.eclipse.equinox.launcher.wpf.win32.x86/launcher.wpf.win32.x86.properties b/bundles/org.eclipse.equinox.launcher/fragments/org.eclipse.equinox.launcher.wpf.win32.x86/launcher.wpf.win32.x86.properties new file mode 100644 index 000000000..e94867f6a --- /dev/null +++ b/bundles/org.eclipse.equinox.launcher/fragments/org.eclipse.equinox.launcher.wpf.win32.x86/launcher.wpf.win32.x86.properties @@ -0,0 +1,12 @@ +############################################################################### +# Copyright (c) 2007 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 +############################################################################### +pluginName = Equinox Launcher WPF Win32 X86 Fragment +providerName = Eclipse.org diff --git a/bundles/org.eclipse.equinox.launcher/src/org/eclipse/equinox/launcher/JNIBridge.java b/bundles/org.eclipse.equinox.launcher/src/org/eclipse/equinox/launcher/JNIBridge.java index 84884b714..40e073f94 100644 --- a/bundles/org.eclipse.equinox.launcher/src/org/eclipse/equinox/launcher/JNIBridge.java +++ b/bundles/org.eclipse.equinox.launcher/src/org/eclipse/equinox/launcher/JNIBridge.java @@ -22,6 +22,9 @@ public class JNIBridge { private native void _show_splash(String bitmap); private native void _takedown_splash(); + private native int OleInitialize(int reserved); + private native void OleUninitialize(); + private String library; private boolean libraryLoaded = false; public JNIBridge(String library) { @@ -31,6 +34,11 @@ public class JNIBridge { private void loadLibrary() { if(library != null) { try { + if (library.indexOf("wpf") != -1) { + String comLibrary = library.replaceAll("eclipse_", "com_"); + System.load(comLibrary); + OleInitialize(0); + } System.load(library); } catch (UnsatisfiedLinkError e ) { //failed @@ -102,4 +110,18 @@ public class JNIBridge { return false; } } + + public boolean uninitialize() { + if (libraryLoaded && library != null) { + if (library.indexOf("wpf") != -1) { + try { + OleUninitialize(); + } catch (UnsatisfiedLinkError e) { + // library not loaded + return false; + } + } + } + return true; + } } diff --git a/bundles/org.eclipse.equinox.launcher/src/org/eclipse/equinox/launcher/Main.java b/bundles/org.eclipse.equinox.launcher/src/org/eclipse/equinox/launcher/Main.java index c442dc12a..164f5f860 100644 --- a/bundles/org.eclipse.equinox.launcher/src/org/eclipse/equinox/launcher/Main.java +++ b/bundles/org.eclipse.equinox.launcher/src/org/eclipse/equinox/launcher/Main.java @@ -1147,7 +1147,9 @@ public class Main { result = 13; } finally { // always try putting down the splash screen just in case the application failed to do so - takeDownSplash(); + takeDownSplash(); + if(bridge != null) + bridge.uninitialize(); } // Return an int exit code and ensure the system property is set. System.getProperties().put(PROP_EXITCODE, Integer.toString(result)); @@ -1157,7 +1159,7 @@ public class Main { private void setExitData() { String data = System.getProperty(PROP_EXITDATA); - if (data == null) + if (data == null || bridge == null) return; bridge.setExitData(exitData, data); } @@ -1734,7 +1736,7 @@ public class Main { * Take down the splash screen. */ protected void takeDownSplash() { - if (splashDown) // splash is already down + if (splashDown || bridge == null) // splash is already down return; splashDown = bridge.takeDownSplash();; |