Skip to content

Commit

Permalink
file -> new project baseline
Browse files Browse the repository at this point in the history
  • Loading branch information
ghuntley committed Aug 4, 2017
1 parent 7221f58 commit fbd4776
Show file tree
Hide file tree
Showing 76 changed files with 4,082 additions and 0 deletions.
4 changes: 4 additions & 0 deletions samples/xamarin-forms/.nuget/packages.config
@@ -0,0 +1,4 @@
<?xml version="1.0" encoding="utf-8"?>
<packages>
<package id="Xamarin.GooglePlayServices" version="27.0.0.0" />
</packages>
117 changes: 117 additions & 0 deletions samples/xamarin-forms/App.Droid/App.Droid.csproj
@@ -0,0 +1,117 @@
<?xml version="1.0" encoding="utf-8"?>
<Project ToolsVersion="4.0" DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<PropertyGroup>
<Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
<Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform>
<ProductVersion>8.0.30703</ProductVersion>
<SchemaVersion>2.0</SchemaVersion>
<ProjectGuid>{B00E7B6C-1986-4303-A96F-093EE450354A}</ProjectGuid>
<ProjectTypeGuids>{EFBA0AD7-5A72-4C68-AF49-83D382785DCF};{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}</ProjectTypeGuids>
<OutputType>Library</OutputType>
<AppDesignerFolder>Properties</AppDesignerFolder>
<RootNamespace>App.Droid</RootNamespace>
<AssemblyName>App.Droid</AssemblyName>
<FileAlignment>512</FileAlignment>
<AndroidApplication>True</AndroidApplication>
<AndroidResgenFile>Resources\Resource.Designer.cs</AndroidResgenFile>
<GenerateSerializationAssemblies>Off</GenerateSerializationAssemblies>
<AndroidUseLatestPlatformSdk>True</AndroidUseLatestPlatformSdk>
<TargetFrameworkVersion>v7.1</TargetFrameworkVersion>
<AndroidManifest>Properties\AndroidManifest.xml</AndroidManifest>
</PropertyGroup>
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">
<DebugSymbols>True</DebugSymbols>
<DebugType>Full</DebugType>
<Optimize>False</Optimize>
<OutputPath>bin\Debug\</OutputPath>
<DefineConstants>DEBUG;TRACE</DefineConstants>
<ErrorReport>prompt</ErrorReport>
<WarningLevel>4</WarningLevel>
<AndroidUseSharedRuntime>True</AndroidUseSharedRuntime>
<AndroidLinkMode>None</AndroidLinkMode>
<EmbedAssembliesIntoApk>False</EmbedAssembliesIntoApk>
</PropertyGroup>
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">
<DebugType>PdbOnly</DebugType>
<DebugSymbols>True</DebugSymbols>
<Optimize>True</Optimize>
<OutputPath>bin\Release\</OutputPath>
<DefineConstants>TRACE</DefineConstants>
<ErrorReport>prompt</ErrorReport>
<WarningLevel>4</WarningLevel>
<AndroidUseSharedRuntime>False</AndroidUseSharedRuntime>
<AndroidLinkMode>SdkOnly</AndroidLinkMode>
<EmbedAssembliesIntoApk>True</EmbedAssembliesIntoApk>
</PropertyGroup>
<ItemGroup>
<Reference Include="Microsoft.CSharp" />
<Reference Include="Mono.Android" />
<Reference Include="mscorlib" />
<Reference Include="System" />
<Reference Include="System.Core" />
<Reference Include="System.Xml.Linq" />
<Reference Include="System.Xml" />
</ItemGroup>
<ItemGroup>
<Compile Include="MainActivity.cs" />
<Compile Include="Resources\Resource.Designer.cs" />
<Compile Include="Properties\AssemblyInfo.cs" />
</ItemGroup>
<ItemGroup>
<None Include="GettingStarted.Xamarin" />
<None Include="Resources\AboutResources.txt" />
<None Include="Assets\AboutAssets.txt" />
</ItemGroup>
<ItemGroup>
<AndroidResource Include="Resources\layout\Main.axml">
<SubType>Designer</SubType>
</AndroidResource>
</ItemGroup>
<ItemGroup>
<AndroidResource Include="Resources\values\Strings.xml" />
</ItemGroup>
<ItemGroup>
<AndroidResource Include="Resources\drawable\Icon.png" />
</ItemGroup>
<ItemGroup>
<None Include="Properties\AndroidManifest.xml" />
</ItemGroup>
<ItemGroup>
<ProjectReference Include="..\App\App.csproj">
<Project>{07439aa6-b949-4834-82bb-a7f9a32b8888}</Project>
<Name>App</Name>
</ProjectReference>
<ProjectReference Include="..\Features\Features.csproj">
<Project>{e967a2f0-e61c-4f6a-9d45-8724b75ddd81}</Project>
<Name>Features</Name>
</ProjectReference>
<ProjectReference Include="..\Services.Connected\Services.Connected.csproj">
<Project>{a0f6453c-2747-4a20-88e4-6e63026393fa}</Project>
<Name>Services.Connected</Name>
</ProjectReference>
<ProjectReference Include="..\Services.Disconnected\Services.Disconnected.csproj">
<Project>{f73c2f12-1cc9-4640-94b5-2bde7592c5ed}</Project>
<Name>Services.Disconnected</Name>
</ProjectReference>
<ProjectReference Include="..\Services.Droid\Services.Droid.csproj">
<Project>{90814c7e-aee5-4982-b07f-492ca65786d1}</Project>
<Name>Services.Droid</Name>
</ProjectReference>
<ProjectReference Include="..\Services\Services.csproj">
<Project>{21ec734a-b522-4422-908a-f1aa7db3c3bc}</Project>
<Name>Services</Name>
</ProjectReference>
<ProjectReference Include="..\Utility\Utility.csproj">
<Project>{d4eeef02-fb99-4a6f-9316-c7a829916164}</Project>
<Name>Utility</Name>
</ProjectReference>
</ItemGroup>
<Import Project="$(MSBuildExtensionsPath)\Xamarin\Android\Xamarin.Android.CSharp.targets" />
<!-- To modify your build process, add your task inside one of the targets below and uncomment it.
Other similar extension points exist, see Microsoft.Common.targets.
<Target Name="BeforeBuild">
</Target>
<Target Name="AfterBuild">
</Target>
-->
</Project>
19 changes: 19 additions & 0 deletions samples/xamarin-forms/App.Droid/Assets/AboutAssets.txt
@@ -0,0 +1,19 @@
Any raw assets you want to be deployed with your application can be placed in
this directory (and child directories) and given a Build Action of "AndroidAsset".

These files will be deployed with you package and will be accessible using Android's
AssetManager, like this:

public class ReadAsset : Activity
{
protected override void OnCreate (Bundle bundle)
{
base.OnCreate (bundle);

InputStream input = Assets.Open ("my_asset.txt");
}
}

Additionally, some Android functions will automatically load asset files:

Typeface tf = Typeface.CreateFromAsset (Context.Assets, "fonts/samplefont.ttf");
4 changes: 4 additions & 0 deletions samples/xamarin-forms/App.Droid/GettingStarted.Xamarin
@@ -0,0 +1,4 @@
<GettingStarted>
<LocalContent>GS\Android\CS\AndroidApp\GettingStarted.html</LocalContent>
<EmbeddedNavigation>false</EmbeddedNavigation>
</GettingStarted>
19 changes: 19 additions & 0 deletions samples/xamarin-forms/App.Droid/MainActivity.cs
@@ -0,0 +1,19 @@
using Android.App;
using Android.Widget;
using Android.OS;

namespace App.Droid
{
[Activity(Label = "App.Droid", MainLauncher = true, Icon = "@drawable/icon")]
public class MainActivity : Activity
{
protected override void OnCreate(Bundle bundle)
{
base.OnCreate(bundle);

// Set our view from the "main" layout resource
// SetContentView (Resource.Layout.Main);
}
}
}

@@ -0,0 +1,5 @@
<?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android="http://schemas.android.com/apk/res/android" android:versionCode="1" android:versionName="1.0" android:installLocation="auto" package="net.reactiveui.samples.reactivetwitter">
<uses-sdk android:minSdkVersion="16" />
<application android:label="ReactiveTwitter"></application>
</manifest>
30 changes: 30 additions & 0 deletions samples/xamarin-forms/App.Droid/Properties/AssemblyInfo.cs
@@ -0,0 +1,30 @@
using System.Reflection;
using System.Runtime.CompilerServices;
using System.Runtime.InteropServices;
using Android.App;

// 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("App.Droid")]
[assembly: AssemblyDescription("")]
[assembly: AssemblyConfiguration("")]
[assembly: AssemblyCompany("")]
[assembly: AssemblyProduct("App.Droid")]
[assembly: AssemblyCopyright("Copyright © 2017")]
[assembly: AssemblyTrademark("")]
[assembly: AssemblyCulture("")]
[assembly: ComVisible(false)]

// 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 Build and Revision Numbers
// by using the '*' as shown below:
// [assembly: AssemblyVersion("1.0.*")]
[assembly: AssemblyVersion("1.0.0.0")]
[assembly: AssemblyFileVersion("1.0.0.0")]
44 changes: 44 additions & 0 deletions samples/xamarin-forms/App.Droid/Resources/AboutResources.txt
@@ -0,0 +1,44 @@
Images, layout descriptions, binary blobs and string dictionaries can be included
in your application as resource files. Various Android APIs are designed to
operate on the resource IDs instead of dealing with images, strings or binary blobs
directly.

For example, a sample Android app that contains a user interface layout (main.axml),
an internationalization string table (strings.xml) and some icons (drawable-XXX/icon.png)
would keep its resources in the "Resources" directory of the application:

Resources/
drawable/
icon.png

layout/
main.axml

values/
strings.xml

In order to get the build system to recognize Android resources, set the build action to
"AndroidResource". The native Android APIs do not operate directly with filenames, but
instead operate on resource IDs. When you compile an Android application that uses resources,
the build system will package the resources for distribution and generate a class called "R"
(this is an Android convention) that contains the tokens for each one of the resources
included. For example, for the above Resources layout, this is what the R class would expose:

public class R {
public class drawable {
public const int icon = 0x123;
}

public class layout {
public const int main = 0x456;
}

public class strings {
public const int first_string = 0xabc;
public const int second_string = 0xbcd;
}
}

You would then use R.drawable.icon to reference the drawable/icon.png file, or R.layout.main
to reference the layout/main.axml file, or R.strings.first_string to reference the first
string in the dictionary file values/strings.xml.
98 changes: 98 additions & 0 deletions samples/xamarin-forms/App.Droid/Resources/Resource.designer.cs

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
7 changes: 7 additions & 0 deletions samples/xamarin-forms/App.Droid/Resources/layout/Main.axml
@@ -0,0 +1,7 @@
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:orientation="vertical"
android:layout_width="match_parent"
android:layout_height="match_parent"
>
</LinearLayout>
5 changes: 5 additions & 0 deletions samples/xamarin-forms/App.Droid/Resources/values/Strings.xml
@@ -0,0 +1,5 @@
<?xml version="1.0" encoding="utf-8"?>
<resources>
<string name="Hello">Hello World, Click Me!</string>
<string name="ApplicationName">App.Droid</string>
</resources>

0 comments on commit fbd4776

Please sign in to comment.