You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@cordova.apache.org by pu...@apache.org on 2012/02/23 23:29:31 UTC

[41/50] [abbrv] wp7 commit: fixed test project

fixed test project


Project: http://git-wip-us.apache.org/repos/asf/incubator-cordova-wp7/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-cordova-wp7/commit/b9cfe074
Tree: http://git-wip-us.apache.org/repos/asf/incubator-cordova-wp7/tree/b9cfe074
Diff: http://git-wip-us.apache.org/repos/asf/incubator-cordova-wp7/diff/b9cfe074

Branch: refs/heads/master
Commit: b9cfe0744c485699a045a62dc6847157a6e51115
Parents: 1864803
Author: Jesse MacFadyen <pu...@gmail.com>
Authored: Mon Feb 13 12:53:28 2012 -0800
Committer: Jesse MacFadyen <pu...@gmail.com>
Committed: Mon Feb 13 12:53:28 2012 -0800

----------------------------------------------------------------------
 example/GapExample.csproj                          |    4 --
 example/GapSourceDictionary.xml                    |   21 ------------
 templates/custom/GapSourceDictionary.xml           |    5 ---
 tests/MobileSpecUnitTests/Calculator.cs            |    6 ++--
 .../CordovaSourceDictionary.xml                    |   26 +++++++++++++++
 tests/MobileSpecUnitTests/GapSourceDictionary.xml  |   26 ---------------
 tests/MobileSpecUnitTests/MainPage.xaml            |   25 +++++++++-----
 tests/MobileSpecUnitTests/MainPage.xaml.cs         |   12 +------
 tests/MobileSpecUnitTests/ManifestProcessor.js     |    6 ++--
 .../MobileSpecUnitTests/MobileSpecUnitTests.csproj |   18 +++++-----
 tests/MobileSpecUnitTests/MobileSpecUnitTests.sln  |    2 +-
 tests/MobileSpecUnitTests/www/index.html           |   10 ++----
 12 files changed, 62 insertions(+), 99 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-cordova-wp7/blob/b9cfe074/example/GapExample.csproj
----------------------------------------------------------------------
diff --git a/example/GapExample.csproj b/example/GapExample.csproj
index b94c638..25ed472 100644
--- a/example/GapExample.csproj
+++ b/example/GapExample.csproj
@@ -136,10 +136,6 @@
     <None Include="Properties\WMAppManifest.xml">
       <SubType>Designer</SubType>
     </None>
-    <Content Include="GapSourceDictionary.xml">
-      <CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
-      <SubType>Designer</SubType>
-    </Content>
   </ItemGroup>
   <ItemGroup>
     <Content Include="ApplicationIcon.png">

http://git-wip-us.apache.org/repos/asf/incubator-cordova-wp7/blob/b9cfe074/example/GapSourceDictionary.xml
----------------------------------------------------------------------
diff --git a/example/GapSourceDictionary.xml b/example/GapSourceDictionary.xml
deleted file mode 100644
index 8be0e3c..0000000
--- a/example/GapSourceDictionary.xml
+++ /dev/null
@@ -1,21 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- This file is auto-generated, do not edit! -jm -->
-<GapSourceDictionary>
-    <FilePath Value="www\accelerometer.html"/>
-    <FilePath Value="www\accelerometer2.html"/>
-    <FilePath Value="www\audio.html"/>
-    <FilePath Value="www\calculator.html"/>
-    <FilePath Value="www\camera.html"/>
-    <FilePath Value="www\capture.html"/>
-    <FilePath Value="www\compass.html"/>
-    <FilePath Value="www\contacts.html"/>
-    <FilePath Value="www\cordova-1.4.1.js"/>
-    <FilePath Value="www\events.html"/>
-    <FilePath Value="www\file.html"/>
-    <FilePath Value="www\index.html"/>
-    <FilePath Value="www\location.html"/>
-    <FilePath Value="www\master.css"/>
-    <FilePath Value="www\network.html"/>
-    <FilePath Value="www\notification.html"/>
-    <FilePath Value="www\storage.html"/>
-</GapSourceDictionary>

http://git-wip-us.apache.org/repos/asf/incubator-cordova-wp7/blob/b9cfe074/templates/custom/GapSourceDictionary.xml
----------------------------------------------------------------------
diff --git a/templates/custom/GapSourceDictionary.xml b/templates/custom/GapSourceDictionary.xml
deleted file mode 100644
index cef91d6..0000000
--- a/templates/custom/GapSourceDictionary.xml
+++ /dev/null
@@ -1,5 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- This file is auto-generated, do not edit! -jm -->
-<GapSourceDictionary>
-
-</GapSourceDictionary>

http://git-wip-us.apache.org/repos/asf/incubator-cordova-wp7/blob/b9cfe074/tests/MobileSpecUnitTests/Calculator.cs
----------------------------------------------------------------------
diff --git a/tests/MobileSpecUnitTests/Calculator.cs b/tests/MobileSpecUnitTests/Calculator.cs
index 6e59bcf..11e3187 100644
--- a/tests/MobileSpecUnitTests/Calculator.cs
+++ b/tests/MobileSpecUnitTests/Calculator.cs
@@ -7,9 +7,9 @@
  */
 
 using System.Runtime.Serialization;
-using WP7GapClassLib.Cordova;
-using WP7GapClassLib.Cordova.Commands;
-using WP7GapClassLib.Cordova.JSON;
+using WP7CordovaClassLib.Cordova;
+using WP7CordovaClassLib.Cordova.Commands;
+using WP7CordovaClassLib.Cordova.JSON;
 
 namespace Cordova.Extension.Commands
 {

http://git-wip-us.apache.org/repos/asf/incubator-cordova-wp7/blob/b9cfe074/tests/MobileSpecUnitTests/CordovaSourceDictionary.xml
----------------------------------------------------------------------
diff --git a/tests/MobileSpecUnitTests/CordovaSourceDictionary.xml b/tests/MobileSpecUnitTests/CordovaSourceDictionary.xml
new file mode 100644
index 0000000..baa5383
--- /dev/null
+++ b/tests/MobileSpecUnitTests/CordovaSourceDictionary.xml
@@ -0,0 +1,26 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- This file is auto-generated, do not edit! -jm -->
+<CordovaSourceDictionary>
+    <FilePath Value="www\cordova-1.4.1.js"/>
+    <FilePath Value="www\index.html"/>
+    <FilePath Value="www\master.css"/>
+    <FilePath Value="www\autotest\index.html"/>
+    <FilePath Value="www\autotest\qunit.css"/>
+    <FilePath Value="www\autotest\qunit.js"/>
+    <FilePath Value="www\autotest\test-runner.js"/>
+    <FilePath Value="www\autotest\tests\accelerometer.tests.js"/>
+    <FilePath Value="www\autotest\tests\camera.tests.js"/>
+    <FilePath Value="www\autotest\tests\capture.tests.js"/>
+    <FilePath Value="www\autotest\tests\compass.tests.js"/>
+    <FilePath Value="www\autotest\tests\contacts.tests.js"/>
+    <FilePath Value="www\autotest\tests\device.tests.js"/>
+    <FilePath Value="www\autotest\tests\file.tests.js"/>
+    <FilePath Value="www\autotest\tests\filetransfer.tests.js"/>
+    <FilePath Value="www\autotest\tests\geolocation.tests.js"/>
+    <FilePath Value="www\autotest\tests\media.tests.js"/>
+    <FilePath Value="www\autotest\tests\network.tests.js"/>
+    <FilePath Value="www\autotest\tests\notification.tests.js"/>
+    <FilePath Value="www\autotest\tests\orientation.tests.js"/>
+    <FilePath Value="www\autotest\tests\storage.tests.js"/>
+    <FilePath Value="www\autotest\tests\system.tests.js"/>
+</CordovaSourceDictionary>

http://git-wip-us.apache.org/repos/asf/incubator-cordova-wp7/blob/b9cfe074/tests/MobileSpecUnitTests/GapSourceDictionary.xml
----------------------------------------------------------------------
diff --git a/tests/MobileSpecUnitTests/GapSourceDictionary.xml b/tests/MobileSpecUnitTests/GapSourceDictionary.xml
deleted file mode 100644
index f81582f..0000000
--- a/tests/MobileSpecUnitTests/GapSourceDictionary.xml
+++ /dev/null
@@ -1,26 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- This file is auto-generated, do not edit! -jm -->
-<GapSourceDictionary>
-    <FilePath Value="www\cordova-1.4.1.js"/>
-    <FilePath Value="www\index.html"/>
-    <FilePath Value="www\master.css"/>
-    <FilePath Value="www\autotest\index.html"/>
-    <FilePath Value="www\autotest\qunit.css"/>
-    <FilePath Value="www\autotest\qunit.js"/>
-    <FilePath Value="www\autotest\test-runner.js"/>
-    <FilePath Value="www\autotest\tests\accelerometer.tests.js"/>
-    <FilePath Value="www\autotest\tests\camera.tests.js"/>
-    <FilePath Value="www\autotest\tests\capture.tests.js"/>
-    <FilePath Value="www\autotest\tests\compass.tests.js"/>
-    <FilePath Value="www\autotest\tests\contacts.tests.js"/>
-    <FilePath Value="www\autotest\tests\device.tests.js"/>
-    <FilePath Value="www\autotest\tests\file.tests.js"/>
-    <FilePath Value="www\autotest\tests\filetransfer.tests.js"/>
-    <FilePath Value="www\autotest\tests\geolocation.tests.js"/>
-    <FilePath Value="www\autotest\tests\media.tests.js"/>
-    <FilePath Value="www\autotest\tests\network.tests.js"/>
-    <FilePath Value="www\autotest\tests\notification.tests.js"/>
-    <FilePath Value="www\autotest\tests\orientation.tests.js"/>
-    <FilePath Value="www\autotest\tests\storage.tests.js"/>
-    <FilePath Value="www\autotest\tests\system.tests.js"/>
-</GapSourceDictionary>

http://git-wip-us.apache.org/repos/asf/incubator-cordova-wp7/blob/b9cfe074/tests/MobileSpecUnitTests/MainPage.xaml
----------------------------------------------------------------------
diff --git a/tests/MobileSpecUnitTests/MainPage.xaml b/tests/MobileSpecUnitTests/MainPage.xaml
index 24d2a07..b4279c5 100644
--- a/tests/MobileSpecUnitTests/MainPage.xaml
+++ b/tests/MobileSpecUnitTests/MainPage.xaml
@@ -6,22 +6,29 @@
     xmlns:shell="clr-namespace:Microsoft.Phone.Shell;assembly=Microsoft.Phone"
     xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
     xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
-    mc:Ignorable="d" d:DesignWidth="480" d:DesignHeight="768"
+    xmlns:my="clr-namespace:WP7CordovaClassLib;assembly=WP7CordovaClassLib"
     FontFamily="{StaticResource PhoneFontFamilyNormal}"
     FontSize="{StaticResource PhoneFontSizeNormal}"
     Foreground="{StaticResource PhoneForegroundBrush}"
-    SupportedOrientations="PortraitOrLandscape" Orientation="Portrait"
-    shell:SystemTray.IsVisible="True" xmlns:my="clr-namespace:WP7GapClassLib;assembly=WP7GapClassLib" DataContext="{Binding}">
+    SupportedOrientations="Portrait" Orientation="Portrait"
+    mc:Ignorable="d" d:DesignHeight="768" d:DesignWidth="480"
+    shell:SystemTray.IsVisible="True">
 
     <!--LayoutRoot is the root grid where all page content is placed-->
-    <Grid x:Name="LayoutRoot" Background="Transparent" HorizontalAlignment="Stretch">
+    <Grid x:Name="LayoutRoot" Background="Transparent">
         <Grid.RowDefinitions>
             <RowDefinition Height="*"/>
         </Grid.RowDefinitions>
-        <my:PGView HorizontalAlignment="Stretch" 
-                   Margin="0,0,0,0"  
-                   Name="PGView" 
-                   VerticalAlignment="Stretch" />
+        
+        <my:CordovaView Name="PGView" 
+                        VerticalAlignment="Stretch"
+                        HorizontalAlignment="Stretch" 
+                        Margin="0,0,0,0">
+        </my:CordovaView>       
+        
+
     </Grid>
+ 
+
 
-</phone:PhoneApplicationPage>
\ No newline at end of file
+</phone:PhoneApplicationPage>

http://git-wip-us.apache.org/repos/asf/incubator-cordova-wp7/blob/b9cfe074/tests/MobileSpecUnitTests/MainPage.xaml.cs
----------------------------------------------------------------------
diff --git a/tests/MobileSpecUnitTests/MainPage.xaml.cs b/tests/MobileSpecUnitTests/MainPage.xaml.cs
index 9985b12..2ad2f04 100644
--- a/tests/MobileSpecUnitTests/MainPage.xaml.cs
+++ b/tests/MobileSpecUnitTests/MainPage.xaml.cs
@@ -1,12 +1,4 @@
-/*
- * PhoneGap is available under *either* the terms of the modified BSD license *or* the
- * MIT License (2008). See http://opensource.org/licenses/alphabetical for full text.
- *
- * Copyright (c) 2005-2011, Nitobi Software Inc.
- * Copyright (c) 2011, Microsoft Corporation
- */
-
-using System;
+using System;
 using System.Collections.Generic;
 using System.Linq;
 using System.Net;
@@ -23,11 +15,9 @@ namespace MobileSpecUnitTests
 {
     public partial class MainPage : PhoneApplicationPage
     {
-        // Constructor
         public MainPage()
         {
             InitializeComponent();
         }
- 
     }
 }
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/incubator-cordova-wp7/blob/b9cfe074/tests/MobileSpecUnitTests/ManifestProcessor.js
----------------------------------------------------------------------
diff --git a/tests/MobileSpecUnitTests/ManifestProcessor.js b/tests/MobileSpecUnitTests/ManifestProcessor.js
index 18c2163..d794e70 100644
--- a/tests/MobileSpecUnitTests/ManifestProcessor.js
+++ b/tests/MobileSpecUnitTests/ManifestProcessor.js
@@ -16,11 +16,11 @@ var fso = WScript.CreateObject("Scripting.FileSystemObject");
 
 var folder = fso.GetFolder("..\\..\\www");
 
-var outFile = fso.CreateTextFile("..\\..\\GapSourceDictionary.xml", true);
+var outFile = fso.CreateTextFile("..\\..\\CordovaSourceDictionary.xml", true);
 
 outFile.WriteLine('<?xml version="1.0" encoding="utf-8"?>');
 outFile.WriteLine('<!-- This file is auto-generated, do not edit! -jm -->');
-outFile.WriteLine('<GapSourceDictionary>');
+outFile.WriteLine('<CordovaSourceDictionary>');
 
 function enumerateFolder(folder,parentPath)
 {
@@ -61,5 +61,5 @@ if(projectFilePath != null)
     }
 }
 
-outFile.WriteLine('</GapSourceDictionary>');
+outFile.WriteLine('</CordovaSourceDictionary>');
 

http://git-wip-us.apache.org/repos/asf/incubator-cordova-wp7/blob/b9cfe074/tests/MobileSpecUnitTests/MobileSpecUnitTests.csproj
----------------------------------------------------------------------
diff --git a/tests/MobileSpecUnitTests/MobileSpecUnitTests.csproj b/tests/MobileSpecUnitTests/MobileSpecUnitTests.csproj
index 233a264..c5c19c8 100644
--- a/tests/MobileSpecUnitTests/MobileSpecUnitTests.csproj
+++ b/tests/MobileSpecUnitTests/MobileSpecUnitTests.csproj
@@ -88,11 +88,9 @@
     <Content Include="Background.png">
       <CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
     </Content>
+    <Content Include="CordovaSourceDictionary.xml" />
     <Content Include="www\cordova-1.4.1.js" />
     <None Include="ManifestProcessor.js" />
-    <Content Include="GapSourceDictionary.xml">
-      <SubType>Designer</SubType>
-    </Content>
     <Content Include="SplashScreenImage.jpg" />
     <Content Include="www\autotest\index.html">
       <SubType>Designer</SubType>
@@ -115,17 +113,19 @@
     <Content Include="www\autotest\tests\orientation.tests.js" />
     <Content Include="www\autotest\tests\storage.tests.js" />
     <Content Include="www\autotest\tests\system.tests.js" />
-    <Content Include="www\index.html" />
+    <Content Include="www\index.html">
+      <SubType>Designer</SubType>
+    </Content>
     <Content Include="www\master.css" />
   </ItemGroup>
   <ItemGroup>
-    <ProjectReference Include="..\..\framework\WP7GapClassLib.csproj">
-      <Project>{FC6A1A70-892D-46AD-9E4A-9793F72AF780}</Project>
-      <Name>WP7GapClassLib</Name>
-    </ProjectReference>
+    <Service Include="{508349B6-6B84-4DF5-91F0-309BEEBAD82D}" />
   </ItemGroup>
   <ItemGroup>
-    <Service Include="{508349B6-6B84-4DF5-91F0-309BEEBAD82D}" />
+    <ProjectReference Include="..\..\framework\WP7CordovaClassLib.csproj">
+      <Project>{FC6A1A70-892D-46AD-9E4A-9793F72AF780}</Project>
+      <Name>WP7CordovaClassLib</Name>
+    </ProjectReference>
   </ItemGroup>
   <Import Project="$(MSBuildExtensionsPath)\Microsoft\Silverlight for Phone\$(TargetFrameworkVersion)\Microsoft.Silverlight.$(TargetFrameworkProfile).Overrides.targets" />
   <Import Project="$(MSBuildExtensionsPath)\Microsoft\Silverlight for Phone\$(TargetFrameworkVersion)\Microsoft.Silverlight.CSharp.targets" />

http://git-wip-us.apache.org/repos/asf/incubator-cordova-wp7/blob/b9cfe074/tests/MobileSpecUnitTests/MobileSpecUnitTests.sln
----------------------------------------------------------------------
diff --git a/tests/MobileSpecUnitTests/MobileSpecUnitTests.sln b/tests/MobileSpecUnitTests/MobileSpecUnitTests.sln
index c652dee..c2ba6fa 100644
--- a/tests/MobileSpecUnitTests/MobileSpecUnitTests.sln
+++ b/tests/MobileSpecUnitTests/MobileSpecUnitTests.sln
@@ -3,7 +3,7 @@ Microsoft Visual Studio Solution File, Format Version 11.00
 # Visual Studio 2010 Express for Windows Phone
 Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "MobileSpecUnitTests", "MobileSpecUnitTests.csproj", "{86DC5E2F-4AEE-42E3-9471-A082B9BEBEAC}"
 EndProject
-Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "WP7GapClassLib", "..\..\framework\WP7GapClassLib.csproj", "{FC6A1A70-892D-46AD-9E4A-9793F72AF780}"
+Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "WP7CordovaClassLib", "..\..\framework\WP7CordovaClassLib.csproj", "{FC6A1A70-892D-46AD-9E4A-9793F72AF780}"
 EndProject
 Global
 	GlobalSection(SolutionConfigurationPlatforms) = preSolution

http://git-wip-us.apache.org/repos/asf/incubator-cordova-wp7/blob/b9cfe074/tests/MobileSpecUnitTests/www/index.html
----------------------------------------------------------------------
diff --git a/tests/MobileSpecUnitTests/www/index.html b/tests/MobileSpecUnitTests/www/index.html
index 49b0469..2ef2940 100644
--- a/tests/MobileSpecUnitTests/www/index.html
+++ b/tests/MobileSpecUnitTests/www/index.html
@@ -1,8 +1,9 @@
-<!doctype html>
+<!DOCTYPE html>
 <html>
   <head>
     <meta name="viewport" content="width=320; user-scalable=no" />
     <meta http-equiv="Content-type" content="text/html; charset=utf-8"/>
+
     <title>PhoneGap</title>
 	  <link rel="stylesheet" href="master.css" type="text/css" media="screen" title="no title" charset="utf-8"/>
       
@@ -26,9 +27,6 @@
        
       <script type="text/javascript">
 
-
-		
-			
 			
 			function init()
 			{
@@ -69,9 +67,7 @@
 			
 			
 	  </script>
-      
-	 
-	  
+
 
   </head>
   <body onLoad="init();" id="stage" class="theme">