Permalink
Browse files

Windows Phone 8 platform added

  • Loading branch information...
timashev committed Sep 22, 2012
1 parent 572af84 commit bf96602c7aef6fafeb7accaf9b7c04b39d94c005
View
@@ -47,6 +47,9 @@ platform/wp7/*.sdf
platform/wp7/rhodes/obj/*
platform/wp7/**/obj/*
platform/wp7/IronRuby/bin/Silverlight3Debug
+platform/wp8/bin/*
+platform/wp8/*/obj/*
+platform/wp8/ipch/*
platform/symbian/rhodes/apps/*
platform/symbian/rhodes/db/*
platform/symbian/rhodes/lib/*
@@ -177,6 +180,8 @@ platform/android/**/default.properties
*.user
*.pdb
*.idb
+*.sdf
+*.opensdf
*.mode1v3
*.mode2v3
View
@@ -0,0 +1,74 @@
+
+Microsoft Visual Studio Solution File, Format Version 12.00
+# Visual Studio Express 2012 for Windows Phone
+Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "rhodes", "rhodes\rhodes.csproj", "{B3A01AFB-4608-4598-9C5F-43A9D7F42589}"
+EndProject
+Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "rhoruntime", "rhoruntime\rhoruntime.vcxproj", "{19B2CB23-B0FC-44C0-BD59-3DA4F3113585}"
+EndProject
+Global
+ GlobalSection(SolutionConfigurationPlatforms) = preSolution
+ Debug|ARM = Debug|ARM
+ Debug|Any CPU = Debug|Any CPU
+ Debug|Mixed Platforms = Debug|Mixed Platforms
+ Debug|Win32 = Debug|Win32
+ Debug|x86 = Debug|x86
+ Release|ARM = Release|ARM
+ Release|Any CPU = Release|Any CPU
+ Release|Mixed Platforms = Release|Mixed Platforms
+ Release|Win32 = Release|Win32
+ Release|x86 = Release|x86
+ EndGlobalSection
+ GlobalSection(ProjectConfigurationPlatforms) = postSolution
+ {19B2CB23-B0FC-44C0-BD59-3DA4F3113585}.Debug|ARM.ActiveCfg = Debug|ARM
+ {19B2CB23-B0FC-44C0-BD59-3DA4F3113585}.Debug|ARM.Build.0 = Debug|ARM
+ {19B2CB23-B0FC-44C0-BD59-3DA4F3113585}.Debug|Any CPU.ActiveCfg = Debug|Win32
+ {19B2CB23-B0FC-44C0-BD59-3DA4F3113585}.Debug|Mixed Platforms.ActiveCfg = Debug|Win32
+ {19B2CB23-B0FC-44C0-BD59-3DA4F3113585}.Debug|Mixed Platforms.Build.0 = Debug|Win32
+ {19B2CB23-B0FC-44C0-BD59-3DA4F3113585}.Debug|Win32.ActiveCfg = Debug|Win32
+ {19B2CB23-B0FC-44C0-BD59-3DA4F3113585}.Debug|Win32.Build.0 = Debug|Win32
+ {19B2CB23-B0FC-44C0-BD59-3DA4F3113585}.Debug|x86.ActiveCfg = Debug|Win32
+ {19B2CB23-B0FC-44C0-BD59-3DA4F3113585}.Debug|x86.Build.0 = Debug|Win32
+ {19B2CB23-B0FC-44C0-BD59-3DA4F3113585}.Release|ARM.ActiveCfg = Release|ARM
+ {19B2CB23-B0FC-44C0-BD59-3DA4F3113585}.Release|ARM.Build.0 = Release|ARM
+ {19B2CB23-B0FC-44C0-BD59-3DA4F3113585}.Release|Any CPU.ActiveCfg = Release|Win32
+ {19B2CB23-B0FC-44C0-BD59-3DA4F3113585}.Release|Mixed Platforms.ActiveCfg = Release|Win32
+ {19B2CB23-B0FC-44C0-BD59-3DA4F3113585}.Release|Mixed Platforms.Build.0 = Release|Win32
+ {19B2CB23-B0FC-44C0-BD59-3DA4F3113585}.Release|Win32.ActiveCfg = Release|Win32
+ {19B2CB23-B0FC-44C0-BD59-3DA4F3113585}.Release|Win32.Build.0 = Release|Win32
+ {19B2CB23-B0FC-44C0-BD59-3DA4F3113585}.Release|x86.ActiveCfg = Release|Win32
+ {19B2CB23-B0FC-44C0-BD59-3DA4F3113585}.Release|x86.Build.0 = Release|Win32
+ {B3A01AFB-4608-4598-9C5F-43A9D7F42589}.Debug|ARM.ActiveCfg = Debug|ARM
+ {B3A01AFB-4608-4598-9C5F-43A9D7F42589}.Debug|ARM.Build.0 = Debug|ARM
+ {B3A01AFB-4608-4598-9C5F-43A9D7F42589}.Debug|ARM.Deploy.0 = Debug|ARM
+ {B3A01AFB-4608-4598-9C5F-43A9D7F42589}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
+ {B3A01AFB-4608-4598-9C5F-43A9D7F42589}.Debug|Any CPU.Build.0 = Debug|Any CPU
+ {B3A01AFB-4608-4598-9C5F-43A9D7F42589}.Debug|Any CPU.Deploy.0 = Debug|Any CPU
+ {B3A01AFB-4608-4598-9C5F-43A9D7F42589}.Debug|Mixed Platforms.ActiveCfg = Debug|x86
+ {B3A01AFB-4608-4598-9C5F-43A9D7F42589}.Debug|Mixed Platforms.Build.0 = Debug|x86
+ {B3A01AFB-4608-4598-9C5F-43A9D7F42589}.Debug|Mixed Platforms.Deploy.0 = Debug|x86
+ {B3A01AFB-4608-4598-9C5F-43A9D7F42589}.Debug|Win32.ActiveCfg = Debug|x86
+ {B3A01AFB-4608-4598-9C5F-43A9D7F42589}.Debug|Win32.Build.0 = Debug|x86
+ {B3A01AFB-4608-4598-9C5F-43A9D7F42589}.Debug|Win32.Deploy.0 = Debug|x86
+ {B3A01AFB-4608-4598-9C5F-43A9D7F42589}.Debug|x86.ActiveCfg = Debug|x86
+ {B3A01AFB-4608-4598-9C5F-43A9D7F42589}.Debug|x86.Build.0 = Debug|x86
+ {B3A01AFB-4608-4598-9C5F-43A9D7F42589}.Debug|x86.Deploy.0 = Debug|x86
+ {B3A01AFB-4608-4598-9C5F-43A9D7F42589}.Release|ARM.ActiveCfg = Release|ARM
+ {B3A01AFB-4608-4598-9C5F-43A9D7F42589}.Release|ARM.Build.0 = Release|ARM
+ {B3A01AFB-4608-4598-9C5F-43A9D7F42589}.Release|ARM.Deploy.0 = Release|ARM
+ {B3A01AFB-4608-4598-9C5F-43A9D7F42589}.Release|Any CPU.ActiveCfg = Release|Any CPU
+ {B3A01AFB-4608-4598-9C5F-43A9D7F42589}.Release|Any CPU.Build.0 = Release|Any CPU
+ {B3A01AFB-4608-4598-9C5F-43A9D7F42589}.Release|Any CPU.Deploy.0 = Release|Any CPU
+ {B3A01AFB-4608-4598-9C5F-43A9D7F42589}.Release|Mixed Platforms.ActiveCfg = Release|x86
+ {B3A01AFB-4608-4598-9C5F-43A9D7F42589}.Release|Mixed Platforms.Build.0 = Release|x86
+ {B3A01AFB-4608-4598-9C5F-43A9D7F42589}.Release|Mixed Platforms.Deploy.0 = Release|x86
+ {B3A01AFB-4608-4598-9C5F-43A9D7F42589}.Release|Win32.ActiveCfg = Release|x86
+ {B3A01AFB-4608-4598-9C5F-43A9D7F42589}.Release|Win32.Build.0 = Release|x86
+ {B3A01AFB-4608-4598-9C5F-43A9D7F42589}.Release|Win32.Deploy.0 = Release|x86
+ {B3A01AFB-4608-4598-9C5F-43A9D7F42589}.Release|x86.ActiveCfg = Release|x86
+ {B3A01AFB-4608-4598-9C5F-43A9D7F42589}.Release|x86.Build.0 = Release|x86
+ {B3A01AFB-4608-4598-9C5F-43A9D7F42589}.Release|x86.Deploy.0 = Release|x86
+ EndGlobalSection
+ GlobalSection(SolutionProperties) = preSolution
+ HideSolutionNode = FALSE
+ EndGlobalSection
+EndGlobal
@@ -0,0 +1,20 @@
+<Application
+ x:Class="rhodes.App"
+ xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
+ xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
+ xmlns:phone="clr-namespace:Microsoft.Phone.Controls;assembly=Microsoft.Phone"
+ xmlns:shell="clr-namespace:Microsoft.Phone.Shell;assembly=Microsoft.Phone">
+
+ <!--Application Resources-->
+ <Application.Resources>
+ <local:LocalizedStrings xmlns:local="clr-namespace:rhodes" x:Key="LocalizedStrings"/>
+ </Application.Resources>
+
+ <Application.ApplicationLifetimeObjects>
+ <!--Required object that handles lifetime events for the application-->
+ <shell:PhoneApplicationService
+ Launching="Application_Launching" Closing="Application_Closing"
+ Activated="Application_Activated" Deactivated="Application_Deactivated"/>
+ </Application.ApplicationLifetimeObjects>
+
+</Application>
@@ -0,0 +1,142 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Net;
+using System.Windows;
+using System.Windows.Controls;
+using System.Windows.Documents;
+using System.Windows.Input;
+using System.Windows.Media;
+using System.Windows.Media.Animation;
+using System.Windows.Navigation;
+using System.Windows.Shapes;
+using Microsoft.Phone.Controls;
+using Microsoft.Phone.Shell;
+
+namespace rhodes
+{
+ public partial class App : Application
+ {
+ /// <summary>
+ /// Provides easy access to the root frame of the Phone Application.
+ /// </summary>
+ /// <returns>The root frame of the Phone Application.</returns>
+ public PhoneApplicationFrame RootFrame { get; private set; }
+
+ /// <summary>
+ /// Constructor for the Application object.
+ /// </summary>
+ public App()
+ {
+ // Global handler for uncaught exceptions.
+ UnhandledException += Application_UnhandledException;
+
+ // Standard Silverlight initialization
+ InitializeComponent();
+
+ // Phone-specific initialization
+ InitializePhoneApplication();
+
+ // Show graphics profiling information while debugging.
+ if (System.Diagnostics.Debugger.IsAttached)
+ {
+ // Display the current frame rate counters.
+ Application.Current.Host.Settings.EnableFrameRateCounter = true;
+
+ // Show the areas of the app that are being redrawn in each frame.
+ //Application.Current.Host.Settings.EnableRedrawRegions = true;
+
+ // Enable non-production analysis visualization mode,
+ // which shows areas of a page that are handed off to GPU with a colored overlay.
+ //Application.Current.Host.Settings.EnableCacheVisualization = true;
+
+ // Disable the application idle detection by setting the UserIdleDetectionMode property of the
+ // application's PhoneApplicationService object to Disabled.
+ // Caution:- Use this under debug mode only. Application that disables user idle detection will continue to run
+ // and consume battery power when the user is not using the phone.
+ PhoneApplicationService.Current.UserIdleDetectionMode = IdleDetectionMode.Disabled;
+ }
+
+ }
+
+ // Code to execute when the application is launching (eg, from Start)
+ // This code will not execute when the application is reactivated
+ private void Application_Launching(object sender, LaunchingEventArgs e)
+ {
+ }
+
+ // Code to execute when the application is activated (brought to foreground)
+ // This code will not execute when the application is first launched
+ private void Application_Activated(object sender, ActivatedEventArgs e)
+ {
+ }
+
+ // Code to execute when the application is deactivated (sent to background)
+ // This code will not execute when the application is closing
+ private void Application_Deactivated(object sender, DeactivatedEventArgs e)
+ {
+ }
+
+ // Code to execute when the application is closing (eg, user hit Back)
+ // This code will not execute when the application is deactivated
+ private void Application_Closing(object sender, ClosingEventArgs e)
+ {
+ }
+
+ // Code to execute if a navigation fails
+ private void RootFrame_NavigationFailed(object sender, NavigationFailedEventArgs e)
+ {
+ if (System.Diagnostics.Debugger.IsAttached)
+ {
+ // A navigation has failed; break into the debugger
+ System.Diagnostics.Debugger.Break();
+ }
+ }
+
+ // Code to execute on Unhandled Exceptions
+ private void Application_UnhandledException(object sender, ApplicationUnhandledExceptionEventArgs e)
+ {
+ if (System.Diagnostics.Debugger.IsAttached)
+ {
+ // An unhandled exception has occurred; break into the debugger
+ System.Diagnostics.Debugger.Break();
+ }
+ }
+
+ #region Phone application initialization
+
+ // Avoid double-initialization
+ private bool phoneApplicationInitialized = false;
+
+ // Do not add any additional code to this method
+ private void InitializePhoneApplication()
+ {
+ if (phoneApplicationInitialized)
+ return;
+
+ // Create the frame but don't set it as RootVisual yet; this allows the splash
+ // screen to remain active until the application is ready to render.
+ RootFrame = new PhoneApplicationFrame();
+ RootFrame.Navigated += CompleteInitializePhoneApplication;
+
+ // Handle navigation failures
+ RootFrame.NavigationFailed += RootFrame_NavigationFailed;
+
+ // Ensure we don't initialize again
+ phoneApplicationInitialized = true;
+ }
+
+ // Do not add any additional code to this method
+ private void CompleteInitializePhoneApplication(object sender, NavigationEventArgs e)
+ {
+ // Set the root visual to allow the application to render
+ if (RootVisual != RootFrame)
+ RootVisual = RootFrame;
+
+ // Remove this handler since it is no longer needed
+ RootFrame.Navigated -= CompleteInitializePhoneApplication;
+ }
+
+ #endregion
+ }
+}
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@@ -0,0 +1,11 @@
+using rhodes.Resources;
+
+namespace rhodes
+{
+ public class LocalizedStrings
+ {
+ private static AppResources _localizedResources = new AppResources();
+
+ public AppResources LocalizedResources { get { return _localizedResources; } }
+ }
+}
@@ -0,0 +1,21 @@
+<phone:PhoneApplicationPage
+ x:Class="rhodes.MainPage"
+ xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
+ xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
+ xmlns:phone="clr-namespace:Microsoft.Phone.Controls;assembly=Microsoft.Phone"
+ 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"
+ FontFamily="{StaticResource PhoneFontFamilyNormal}"
+ FontSize="{StaticResource PhoneFontSizeNormal}"
+ Foreground="{StaticResource PhoneForegroundBrush}"
+ SupportedOrientations="PortraitOrLandscape" Orientation="Portrait"
+ shell:SystemTray.IsVisible="True">
+
+ <!--LayoutRoot is the root grid where all page content is placed-->
+ <ScrollViewer x:Name="LayoutRoot" VerticalAlignment="Stretch" HorizontalAlignment="Stretch">
+ <phone:WebBrowser x:Name="RhodesWebBrowser" Source="about:blank" Height="Auto" Width="Auto"/>
+ </ScrollViewer>
+
+</phone:PhoneApplicationPage>
@@ -0,0 +1,46 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Net;
+using System.Windows;
+using System.Windows.Controls;
+using System.Windows.Documents;
+using System.Windows.Input;
+using System.Windows.Media;
+using System.Windows.Media.Animation;
+using System.Windows.Shapes;
+using Microsoft.Phone.Controls;
+using Microsoft.Phone.Shell;
+using rhodes.Resources;
+using rhoruntime;
+
+namespace rhodes
+{
+ public partial class MainPage : PhoneApplicationPage
+ {
+ public MainPage()
+ {
+ InitializeComponent();
+ try
+ {
+ var rhoruntime = new CRhoRuntime();
+ rhoruntime.SetCallback(new CallbackPointer(RhodesLoaded));
+ rhoruntime.DoCallback();
+ }
+ catch (Exception e)
+ {
+ RhodesWebBrowser.NavigateToString("<html><head><title>Exception</title></head><body>Exception: "+e.Message+"</body></html>");
+ }
+ }
+
+ public void RhodesLoaded()
+ {
+ RhodesWebBrowser.NavigateToString("<html><head><title>Loading...</title></head><body>Loading...</body></html>");
+ }
+
+ public void RhodesReloaded()
+ {
+ RhodesWebBrowser.NavigateToString("<html><head><title>Reloaded...</title></head><body>Reloaded...</body></html>");
+ }
+ }
+}
@@ -0,0 +1,6 @@
+<Deployment xmlns="http://schemas.microsoft.com/client/2007/deployment"
+ xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
+>
+ <Deployment.Parts>
+ </Deployment.Parts>
+</Deployment>
@@ -0,0 +1,37 @@
+using System.Reflection;
+using System.Runtime.CompilerServices;
+using System.Runtime.InteropServices;
+using System.Resources;
+
+// General Information about an assembly is controlled through the following
+// set of attributes. Change these attribute values to modify the information
+// associated with an assembly.
+[assembly: AssemblyTitle("rhodes")]
+[assembly: AssemblyDescription("")]
+[assembly: AssemblyConfiguration("")]
+[assembly: AssemblyCompany("Motorola Solutions, Inc.")]
+[assembly: AssemblyProduct("rhodes")]
+[assembly: AssemblyCopyright("Copyright © 2012")]
+[assembly: AssemblyTrademark("")]
+[assembly: AssemblyCulture("")]
+
+// Setting ComVisible to false makes the types in this assembly not visible
+// to COM components. If you need to access a type in this assembly from
+// COM, set the ComVisible attribute to true on that type.
+[assembly: ComVisible(false)]
+
+// The following GUID is for the ID of the typelib if this project is exposed to COM
+[assembly: Guid("d8f11645-2628-4d05-a2dc-2ef1d7f9a57f")]
+
+// Version information for an assembly consists of the following four values:
+//
+// Major Version
+// Minor Version
+// Build Number
+// Revision
+//
+// You can specify all the values or you can default the Revision and Build Numbers
+// by using the '*' as shown below:
+[assembly: AssemblyVersion("3.4.0.0")]
+[assembly: AssemblyFileVersion("3.4.0.0")]
+[assembly: NeutralResourcesLanguageAttribute("en-US")]
Oops, something went wrong.

0 comments on commit bf96602

Please sign in to comment.