[Esbox-commits] r1556 - in trunk: org.maemo.esbox.product org.maemo.esbox.scratchbox.sb1 org.maemo.esbox.scratchbox.sb1/src/org/maemo/esbox/internal/scratchbox/sb1/ui/wizard org.maemo.esbox.scratchbox.sb1/src/org/maemo/esbox/internal/scratchbox/sb1/ui/wizard/nokiabin org.maemo.esbox.scratchbox.sb2/src/org/maemo/esbox/internal/scratchbox/sb2/ui/wizard

eswartz at garage.maemo.org eswartz at garage.maemo.org
Fri May 8 01:00:37 EEST 2009


Author: eswartz
Date: 2009-05-08 01:00:37 +0300 (Fri, 08 May 2009)
New Revision: 1556

Modified:
   trunk/org.maemo.esbox.product/about.mappings
   trunk/org.maemo.esbox.product/plugin.properties
   trunk/org.maemo.esbox.scratchbox.sb1/plugin.xml
   trunk/org.maemo.esbox.scratchbox.sb1/src/org/maemo/esbox/internal/scratchbox/sb1/ui/wizard/Scratchbox1TargetInstallerSelectionWizardPage.java
   trunk/org.maemo.esbox.scratchbox.sb1/src/org/maemo/esbox/internal/scratchbox/sb1/ui/wizard/nokiabin/DiabloInstallerScriptWorkPage.java
   trunk/org.maemo.esbox.scratchbox.sb1/src/org/maemo/esbox/internal/scratchbox/sb1/ui/wizard/nokiabin/NokiaBinariesInstallerData.java
   trunk/org.maemo.esbox.scratchbox.sb1/src/org/maemo/esbox/internal/scratchbox/sb1/ui/wizard/nokiabin/SDKTargetSelectionPage.java
   trunk/org.maemo.esbox.scratchbox.sb2/src/org/maemo/esbox/internal/scratchbox/sb2/ui/wizard/NewScratchbox2TargetWizard.java
Log:
Merge revs 1553:1555 from work_Ed branch

Modified: trunk/org.maemo.esbox.product/about.mappings
===================================================================
--- trunk/org.maemo.esbox.product/about.mappings	2009-05-07 21:36:46 UTC (rev 1555)
+++ trunk/org.maemo.esbox.product/about.mappings	2009-05-07 22:00:37 UTC (rev 1556)
@@ -7,4 +7,4 @@
 # e.g. "0=20020612"
 # This value will be added automatically via the build scripts
 0=20090211-1700
-1=I20090422
+1=M4

Modified: trunk/org.maemo.esbox.product/plugin.properties
===================================================================
--- trunk/org.maemo.esbox.product/plugin.properties	2009-05-07 21:36:46 UTC (rev 1555)
+++ trunk/org.maemo.esbox.product/plugin.properties	2009-05-07 22:00:37 UTC (rev 1556)
@@ -28,7 +28,7 @@
 shortcut.samples.tooltip = Samples
 shortcut.whatsnew.tooltip = What's New
 
-productIntroTitle = Welcome to ESbox 2.0.0 (Integration)!
+productIntroTitle = Welcome to ESbox 2.0.0M4 (Beta 1)!
 productIntroBrandingText = ESbox
-introDescription-overview = ESbox is an Eclipse plug-in that helps programmers to develop applications for maemo platform on Scratchbox Apophis. 
+introDescription-overview = ESbox is a product that helps you develop applications for the Maemo platform on Scratchbox Apophis and on the Nokia Internet Tablet. 
 introDescription-tutorials = Learn how to be productive using ESbox by completing end-to-end tutorials that will guide you along the way.

Modified: trunk/org.maemo.esbox.scratchbox.sb1/plugin.xml
===================================================================
--- trunk/org.maemo.esbox.scratchbox.sb1/plugin.xml	2009-05-07 21:36:46 UTC (rev 1555)
+++ trunk/org.maemo.esbox.scratchbox.sb1/plugin.xml	2009-05-07 22:00:37 UTC (rev 1556)
@@ -93,9 +93,9 @@
             hasPages="true"
             icon="icons/full/obj16/build_target_icon.png"
             id="org.maemo.esbox.scratchbox.sb1.nokia_binaries_target_installer"
-            name="Scratchbox 1 Nokia-closed binaries">
+            name="Nokia-closed binaries">
             <description>
-               Install the Nokia-closed binaries for a given Maemo SDK into Scratchbox 1. 
+               Install the Nokia-closed binaries for a given Maemo SDK into Scratchbox. 
             </description>
       </wizard>
    </extension>

Modified: trunk/org.maemo.esbox.scratchbox.sb1/src/org/maemo/esbox/internal/scratchbox/sb1/ui/wizard/Scratchbox1TargetInstallerSelectionWizardPage.java
===================================================================
--- trunk/org.maemo.esbox.scratchbox.sb1/src/org/maemo/esbox/internal/scratchbox/sb1/ui/wizard/Scratchbox1TargetInstallerSelectionWizardPage.java	2009-05-07 21:36:46 UTC (rev 1555)
+++ trunk/org.maemo.esbox.scratchbox.sb1/src/org/maemo/esbox/internal/scratchbox/sb1/ui/wizard/Scratchbox1TargetInstallerSelectionWizardPage.java	2009-05-07 22:00:37 UTC (rev 1556)
@@ -178,7 +178,7 @@
 
 			public void selectionChanged(SelectionChangedEvent event) {
 				sdk = ((IScratchbox1SDK) ((IStructuredSelection) event.getSelection()).getFirstElement());
-				if (targetInstallerData != null)
+				if (targetInstallerData != null && sdk != null)
 					targetInstallerData.setScratchbox1SDK(sdk);
 				validatePage();
 			}
@@ -449,6 +449,8 @@
 			setErrorMessage("A platform must be selected");
 			return;
 		}
+		targetInstallerData.setScratchbox1SDK(sdk);
+		
 		IFileStore sboxRoot = buildMachine.getFileSystemAccess().getFileStore(
 				new Path(targetInstallerData.getScratchboxLocation()));
 		if (!sboxRoot.fetchInfo().exists()) {

Modified: trunk/org.maemo.esbox.scratchbox.sb1/src/org/maemo/esbox/internal/scratchbox/sb1/ui/wizard/nokiabin/DiabloInstallerScriptWorkPage.java
===================================================================
--- trunk/org.maemo.esbox.scratchbox.sb1/src/org/maemo/esbox/internal/scratchbox/sb1/ui/wizard/nokiabin/DiabloInstallerScriptWorkPage.java	2009-05-07 21:36:46 UTC (rev 1555)
+++ trunk/org.maemo.esbox.scratchbox.sb1/src/org/maemo/esbox/internal/scratchbox/sb1/ui/wizard/nokiabin/DiabloInstallerScriptWorkPage.java	2009-05-07 22:00:37 UTC (rev 1556)
@@ -27,7 +27,7 @@
 import org.eclipse.swt.widgets.Link;
 import org.maemo.esbox.internal.scratchbox.sb1.Activator;
 import org.maemo.esbox.internal.scratchbox.sb1.ui.process.ValidateNokiaBinariesInstallation;
-import org.maemo.esbox.scratchbox.sb1.sdk.IScratchbox1SDK;
+import org.maemo.esbox.scratchbox.core.sdk.IScratchboxSDK;
 import org.maemo.mica.common.core.Policy;
 import org.maemo.mica.common.core.machine.IBuildMachine;
 import org.maemo.mica.common.core.sdk.ISDKTarget;
@@ -189,8 +189,8 @@
 
 			final List<ISDKTarget> targets  = (List<ISDKTarget>) getWizard()
 					.getParameter("targets_selection");
-			final IScratchbox1SDK sdk  = (IScratchbox1SDK) getWizard().getParameter("sdk_selection");
-			installerData.setScratchbox1SDK(sdk);
+			final IScratchboxSDK sdk  = (IScratchboxSDK) getWizard().getParameter("sdk_selection");
+			installerData.setScratchboxSDK(sdk);
 			
 			final IBuildMachine buildMachine = getWizard().getBuildMachine();
 			

Modified: trunk/org.maemo.esbox.scratchbox.sb1/src/org/maemo/esbox/internal/scratchbox/sb1/ui/wizard/nokiabin/NokiaBinariesInstallerData.java
===================================================================
--- trunk/org.maemo.esbox.scratchbox.sb1/src/org/maemo/esbox/internal/scratchbox/sb1/ui/wizard/nokiabin/NokiaBinariesInstallerData.java	2009-05-07 21:36:46 UTC (rev 1555)
+++ trunk/org.maemo.esbox.scratchbox.sb1/src/org/maemo/esbox/internal/scratchbox/sb1/ui/wizard/nokiabin/NokiaBinariesInstallerData.java	2009-05-07 22:00:37 UTC (rev 1556)
@@ -19,19 +19,20 @@
 import java.util.Set;
 
 import org.eclipse.core.runtime.IPath;
-import org.maemo.esbox.scratchbox.sb1.sdk.IScratchbox1SDK;
+import org.maemo.esbox.scratchbox.core.sdk.IScratchboxSDK;
 
 
 
 /**
  * @author Fabrício S Epaminondas (UFCG) 
  *
+ * TODO: move all this stuff to the scratchbox.ui plugin
  */
 public class NokiaBinariesInstallerData {
 
 	private URL installerURL;
 	private Set<String> packages;
-	private IScratchbox1SDK scratchbox1SDK;
+	private IScratchboxSDK sdk;
 
 
 
@@ -120,25 +121,25 @@
 	
 	
 	/**
-	 * @return the scratchbox1SDK
+	 * @return the scratchboxSDK
 	 */
-	public IScratchbox1SDK getScratchbox1SDK() {
-		return scratchbox1SDK;
+	public IScratchboxSDK getScratchboxSDK() {
+		return sdk;
 	}
 
 
 	/**
-	 * @param scratchbox1SDK the scratchbox1SDK to set
+	 * @param scratchboxSDK the scratchboxSDK to set
 	 */
-	public void setScratchbox1SDK(IScratchbox1SDK scratchbox1SDK) {
-		this.scratchbox1SDK = scratchbox1SDK;
+	public void setScratchboxSDK(IScratchboxSDK scratchboxSDK) {
+		this.sdk = scratchboxSDK;
 	}
 
 	/**
 	 * @return the scratchboxLocation
 	 */
 	public String getScratchboxLocation() {
-		return scratchbox1SDK.getInstallRoot().toPortableString();
+		return sdk.getInstallRoot().toPortableString();
 	}
 
 }

Modified: trunk/org.maemo.esbox.scratchbox.sb1/src/org/maemo/esbox/internal/scratchbox/sb1/ui/wizard/nokiabin/SDKTargetSelectionPage.java
===================================================================
--- trunk/org.maemo.esbox.scratchbox.sb1/src/org/maemo/esbox/internal/scratchbox/sb1/ui/wizard/nokiabin/SDKTargetSelectionPage.java	2009-05-07 21:36:46 UTC (rev 1555)
+++ trunk/org.maemo.esbox.scratchbox.sb1/src/org/maemo/esbox/internal/scratchbox/sb1/ui/wizard/nokiabin/SDKTargetSelectionPage.java	2009-05-07 22:00:37 UTC (rev 1556)
@@ -33,6 +33,7 @@
 import org.eclipse.swt.widgets.Composite;
 import org.eclipse.swt.widgets.Label;
 import org.maemo.esbox.internal.scratchbox.sb1.Activator;
+import org.maemo.esbox.scratchbox.core.sdk.IScratchboxSDK;
 import org.maemo.mica.common.core.sdk.ISDK;
 import org.maemo.mica.common.core.sdk.ISDKTarget;
 import org.maemo.mica.common.project.core.IBuildTargetFilter;
@@ -52,16 +53,11 @@
 	public static final String FREMANTLE = "FREMANTLE";
 
 	public static final String[] SDK_NAMES = new String[] { DIABLO, FREMANTLE };
-	/**
-	 * 
-	 */
-	public static final String SCRATCHBOX_1 = "scratchbox 1";
-
+	
 	private CheckboxTreeViewer targetTree;
 	private Combo fmaemoSDKCombo;
 	private String label;
-	private final MyBuildTargetFilter targetFilter = new MyBuildTargetFilter(
-			SCRATCHBOX_1, "");
+	private final MyBuildTargetFilter targetFilter = new MyBuildTargetFilter("");
 	private final WizardPage _page = this;
 	private ISDKTarget[] defaultTargets;
 
@@ -274,16 +270,14 @@
 	}
 
 	class MyBuildTargetFilter implements IBuildTargetFilter {
-		String scratchbox;
-		String sdkname;
 
-		public MyBuildTargetFilter(String scratchbox, String sdkname) {
-			this.scratchbox = scratchbox;
+		private String sdkname;
+		public MyBuildTargetFilter(String sdkname) {
 			this.sdkname = sdkname;
 		}
 
 		public boolean accept(ISDK sdk) {
-			if (sdk.getName().equalsIgnoreCase(scratchbox))
+			if (sdk instanceof IScratchboxSDK)
 				return true;
 			return false;
 		}
@@ -323,4 +317,4 @@
 		this.defaultTargets = defaultTargets;
 	}
 
-}
\ No newline at end of file
+}

Modified: trunk/org.maemo.esbox.scratchbox.sb2/src/org/maemo/esbox/internal/scratchbox/sb2/ui/wizard/NewScratchbox2TargetWizard.java
===================================================================
--- trunk/org.maemo.esbox.scratchbox.sb2/src/org/maemo/esbox/internal/scratchbox/sb2/ui/wizard/NewScratchbox2TargetWizard.java	2009-05-07 21:36:46 UTC (rev 1555)
+++ trunk/org.maemo.esbox.scratchbox.sb2/src/org/maemo/esbox/internal/scratchbox/sb2/ui/wizard/NewScratchbox2TargetWizard.java	2009-05-07 22:00:37 UTC (rev 1556)
@@ -175,6 +175,10 @@
 						// the user approved this, whether or not it existed before, so pass "true" to force installation
 						sdk.createRootstrapTarget(targetName, useHostTools,
 								true, new SubProgressMonitor(monitor, 1));
+						
+						sdk.refresh();
+						SDKFactory.getInstance().fireListeners();
+						
 						createdTarget = sdk.findSDKTarget(targetName);
 					} catch (MicaException e) {
 						throw new InvocationTargetException(e);



More information about the Esbox-commits mailing list