geronimo-scm mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From de...@apache.org
Subject svn commit: r980306 - in /geronimo/devtools/eclipse-plugin/trunk/plugins/org.apache.geronimo.st.v30.ui: META-INF/MANIFEST.MF plugin.xml src/main/java/org/apache/geronimo/st/v30/ui/handlers/DownloadOSGi.java
Date Thu, 29 Jul 2010 04:34:36 GMT
Author: delos
Date: Thu Jul 29 04:34:36 2010
New Revision: 980306

URL: http://svn.apache.org/viewvc?rev=980306&view=rev
Log:
GERONIMODEVTOOLS-619 correct blueprint editor name in extension.Thanks to Kan's patch

Modified:
    geronimo/devtools/eclipse-plugin/trunk/plugins/org.apache.geronimo.st.v30.ui/META-INF/MANIFEST.MF
    geronimo/devtools/eclipse-plugin/trunk/plugins/org.apache.geronimo.st.v30.ui/plugin.xml
    geronimo/devtools/eclipse-plugin/trunk/plugins/org.apache.geronimo.st.v30.ui/src/main/java/org/apache/geronimo/st/v30/ui/handlers/DownloadOSGi.java

Modified: geronimo/devtools/eclipse-plugin/trunk/plugins/org.apache.geronimo.st.v30.ui/META-INF/MANIFEST.MF
URL: http://svn.apache.org/viewvc/geronimo/devtools/eclipse-plugin/trunk/plugins/org.apache.geronimo.st.v30.ui/META-INF/MANIFEST.MF?rev=980306&r1=980305&r2=980306&view=diff
==============================================================================
--- geronimo/devtools/eclipse-plugin/trunk/plugins/org.apache.geronimo.st.v30.ui/META-INF/MANIFEST.MF
(original)
+++ geronimo/devtools/eclipse-plugin/trunk/plugins/org.apache.geronimo.st.v30.ui/META-INF/MANIFEST.MF
Thu Jul 29 04:34:36 2010
@@ -33,6 +33,11 @@ Require-Bundle: 
  org.eclipse.wst.server.core,
  org.eclipse.wst.server.ui,
  org.eclipse.wst.sse.ui,
- org.eclipse.wst.xml.ui
+ org.eclipse.wst.xml.ui,
+ org.eclipse.equinox.p2.ui;bundle-version="2.0.0",
+ org.eclipse.equinox.p2.operations,
+ org.eclipse.equinox.p2.metadata,
+ org.eclipse.equinox.p2.core;bundle-version="2.0.0",
+ org.eclipse.equinox.p2.repository
 Bundle-ActivationPolicy: lazy
 Bundle-Vendor: Apache Software Foundation

Modified: geronimo/devtools/eclipse-plugin/trunk/plugins/org.apache.geronimo.st.v30.ui/plugin.xml
URL: http://svn.apache.org/viewvc/geronimo/devtools/eclipse-plugin/trunk/plugins/org.apache.geronimo.st.v30.ui/plugin.xml?rev=980306&r1=980305&r2=980306&view=diff
==============================================================================
--- geronimo/devtools/eclipse-plugin/trunk/plugins/org.apache.geronimo.st.v30.ui/plugin.xml
(original)
+++ geronimo/devtools/eclipse-plugin/trunk/plugins/org.apache.geronimo.st.v30.ui/plugin.xml
Thu Jul 29 04:34:36 2010
@@ -304,7 +304,7 @@
             filenames="blueprint.xml"
             icon="icons/obj16/littleOSGi.gif"
             id="org.apache.geronimo.v30.ui.editors.BlueprintFormEditor" 
-            name="%BlueprintFormEditorName">
+            name="%BlueprintEditorName">
             <contentTypeBinding
                 contentTypeId="org.eclipse.core.runtime.xml"/>
             <contentTypeBinding

Modified: geronimo/devtools/eclipse-plugin/trunk/plugins/org.apache.geronimo.st.v30.ui/src/main/java/org/apache/geronimo/st/v30/ui/handlers/DownloadOSGi.java
URL: http://svn.apache.org/viewvc/geronimo/devtools/eclipse-plugin/trunk/plugins/org.apache.geronimo.st.v30.ui/src/main/java/org/apache/geronimo/st/v30/ui/handlers/DownloadOSGi.java?rev=980306&r1=980305&r2=980306&view=diff
==============================================================================
--- geronimo/devtools/eclipse-plugin/trunk/plugins/org.apache.geronimo.st.v30.ui/src/main/java/org/apache/geronimo/st/v30/ui/handlers/DownloadOSGi.java
(original)
+++ geronimo/devtools/eclipse-plugin/trunk/plugins/org.apache.geronimo.st.v30.ui/src/main/java/org/apache/geronimo/st/v30/ui/handlers/DownloadOSGi.java
Thu Jul 29 04:34:36 2010
@@ -17,6 +17,8 @@
 package org.apache.geronimo.st.v30.ui.handlers;
 
 import java.net.MalformedURLException;
+import java.net.URI;
+import java.net.URISyntaxException;
 import java.net.URL;
 
 import org.apache.geronimo.st.v30.ui.internal.Messages;
@@ -24,10 +26,16 @@ import org.apache.geronimo.st.v30.ui.int
 import org.eclipse.core.commands.AbstractHandler;
 import org.eclipse.core.commands.ExecutionEvent;
 import org.eclipse.core.commands.ExecutionException;
+import org.eclipse.equinox.p2.ui.ProvisioningUI;
 import org.eclipse.ui.PartInitException;
 import org.eclipse.ui.browser.IWebBrowser;
 import org.eclipse.ui.browser.IWorkbenchBrowserSupport;
 import org.eclipse.ui.internal.browser.WorkbenchBrowserSupport;
+import org.eclipse.equinox.p2.operations.InstallOperation;
+import org.eclipse.equinox.p2.operations.RepositoryTracker;
+import org.eclipse.equinox.p2.metadata.IInstallableUnit;
+import org.eclipse.equinox.p2.core.ProvisionException;
+import org.eclipse.equinox.p2.repository.metadata.IMetadataRepository;
 
 /**
  * Handler to download the OSGi Application Development tools (i.e., Aries free tooling)
@@ -44,17 +52,34 @@ public class DownloadOSGi extends Abstra
 
         String url = Messages.DownloadOSGiURL;
 
-        try {
             int style = IWorkbenchBrowserSupport.AS_EXTERNAL | IWorkbenchBrowserSupport.STATUS;
-            IWebBrowser browser = WorkbenchBrowserSupport.getInstance().createBrowser(style,
"", "", "");
-            browser.openURL(new URL(url));
-        }
-        catch (MalformedURLException e) {
-            e.printStackTrace();
-        }
-        catch (PartInitException e) {
-            e.printStackTrace();
-        }
+//            IWebBrowser browser = WorkbenchBrowserSupport.getInstance().createBrowser(style,
"", "", "");
+//            browser.openURL(new URL(url));
+            ProvisioningUI provisioningUI = ProvisioningUI.getDefaultUI();
+            RepositoryTracker tracker = provisioningUI.getRepositoryTracker();
+            URI[] uri=new URI[1];
+            try {
+                uri[0]=new URI("http://public.dhe.ibm.com/ibmdl/export/pub/software/rational/OSGiAppTools");
+            } catch (URISyntaxException e) {
+                // TODO Auto-generated catch block
+                e.printStackTrace();
+            }
+            tracker.addRepository(uri[0], null, provisioningUI.getSession());
+           // InstallOperation installOperation = provisioningUI.getInstallOperation(null,uri);
+            provisioningUI.openInstallWizard(null, null, null);
+            try {
+                provisioningUI.loadMetadataRepository(uri[0],true,null);
+            } catch (ProvisionException e) {
+                // TODO Auto-generated catch block
+                e.printStackTrace();
+            }
+           // tracker.refreshRepositories(arg0, provisioningUI., arg2);
+//        catch (MalformedURLException e) {
+//            e.printStackTrace();
+//        }
+//        catch (PartInitException e) {
+//            e.printStackTrace();
+//        }
 
         Trace.tracePoint("Exit", "DownloadOSGi.execute");
         return null;



Mime
View raw message