Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Commit the Sound and MoviePlayback samples.

  • Loading branch information...
commit 30fb7b826346e1af258c8e17d93b9be861fbe98e 1 parent ac789e9
alexrp authored
Showing with 1,972 additions and 0 deletions.
  1. +1 −0  MoviePlayback/Metadata.xml
  2. +26 −0 MoviePlayback/MoviePlayback.sln
  3. +38 −0 MoviePlayback/MoviePlaybackSample/AppDelegate.cs
  4. BIN  MoviePlayback/MoviePlaybackSample/Default-Landscape.png
  5. BIN  MoviePlayback/MoviePlaybackSample/Default-Portrait.png
  6. BIN  MoviePlayback/MoviePlaybackSample/Default.png
  7. BIN  MoviePlayback/MoviePlaybackSample/Default@2x.png
  8. BIN  MoviePlayback/MoviePlaybackSample/Images/Icons/114_icon.png
  9. BIN  MoviePlayback/MoviePlaybackSample/Images/Icons/29_icon.png
  10. BIN  MoviePlayback/MoviePlaybackSample/Images/Icons/50_icon.png
  11. BIN  MoviePlayback/MoviePlaybackSample/Images/Icons/512_icon.png
  12. BIN  MoviePlayback/MoviePlaybackSample/Images/Icons/57_icon.png
  13. BIN  MoviePlayback/MoviePlaybackSample/Images/Icons/58_icon.png
  14. BIN  MoviePlayback/MoviePlaybackSample/Images/Icons/72_icon.png
  15. +38 −0 MoviePlayback/MoviePlaybackSample/Info.plist
  16. +19 −0 MoviePlayback/MoviePlaybackSample/Main.cs
  17. +102 −0 MoviePlayback/MoviePlaybackSample/MoviePlayback.csproj
  18. +76 −0 MoviePlayback/MoviePlaybackSample/MoviePlaybackSampleViewController.cs
  19. +25 −0 MoviePlayback/MoviePlaybackSample/MoviePlaybackSampleViewController.designer.cs
  20. +186 −0 MoviePlayback/MoviePlaybackSample/MoviePlaybackSampleViewController_iPad.xib
  21. +210 −0 MoviePlayback/MoviePlaybackSample/MoviePlaybackSampleViewController_iPhone.xib
  22. BIN  MoviePlayback/MoviePlaybackSample/Movies/file.m4v
  23. +13 −0 MoviePlayback/README.md
  24. BIN  MoviePlayback/Screenshots/01.png
  25. +1 −0  Sound/Metadata.xml
  26. +10 −0 Sound/README.md
  27. BIN  Sound/Screenshots/01.png
  28. BIN  Sound/Screenshots/02.png
  29. BIN  Sound/Screenshots/03.png
  30. BIN  Sound/Screenshots/04.png
  31. +26 −0 Sound/Sound.sln
  32. +39 −0 Sound/Sound/AppDelegate.cs
  33. BIN  Sound/Sound/Default-Landscape~ipad.png
  34. BIN  Sound/Sound/Default-Portrait~ipad.png
  35. BIN  Sound/Sound/Default.png
  36. BIN  Sound/Sound/Default@2x.png
  37. BIN  Sound/Sound/Images/Icons/114_icon.png
  38. BIN  Sound/Sound/Images/Icons/29_icon.png
  39. BIN  Sound/Sound/Images/Icons/50_icon.png
  40. BIN  Sound/Sound/Images/Icons/512_icon.png
  41. BIN  Sound/Sound/Images/Icons/57_icon.png
  42. BIN  Sound/Sound/Images/Icons/58_icon.png
  43. BIN  Sound/Sound/Images/Icons/72_icon.png
  44. +37 −0 Sound/Sound/Info.plist
  45. +20 −0 Sound/Sound/Main.cs
  46. +99 −0 Sound/Sound/Sound.csproj
  47. +153 −0 Sound/Sound/SoundViewController.cs
  48. +57 −0 Sound/Sound/SoundViewController.designer.cs
  49. +397 −0 Sound/Sound/SoundViewController_iPad.xib
  50. +399 −0 Sound/Sound/SoundViewController_iPhone.xib
View
1  MoviePlayback/Metadata.xml
@@ -0,0 +1 @@
+<?xml version="1.0" encoding="utf-8" ?>
View
26 MoviePlayback/MoviePlayback.sln
@@ -0,0 +1,26 @@
+
+Microsoft Visual Studio Solution File, Format Version 11.00
+# Visual Studio 2010
+Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "MoviePlayback", "MoviePlaybackSample\MoviePlayback.csproj", "{822B0D9D-FA7C-4BC5-9DA9-D91B0AE2CB63}"
+EndProject
+Global
+ GlobalSection(SolutionConfigurationPlatforms) = preSolution
+ Debug|iPhoneSimulator = Debug|iPhoneSimulator
+ Release|iPhoneSimulator = Release|iPhoneSimulator
+ Debug|iPhone = Debug|iPhone
+ Release|iPhone = Release|iPhone
+ EndGlobalSection
+ GlobalSection(ProjectConfigurationPlatforms) = postSolution
+ {822B0D9D-FA7C-4BC5-9DA9-D91B0AE2CB63}.Debug|iPhone.ActiveCfg = Debug|iPhone
+ {822B0D9D-FA7C-4BC5-9DA9-D91B0AE2CB63}.Debug|iPhone.Build.0 = Debug|iPhone
+ {822B0D9D-FA7C-4BC5-9DA9-D91B0AE2CB63}.Debug|iPhoneSimulator.ActiveCfg = Debug|iPhoneSimulator
+ {822B0D9D-FA7C-4BC5-9DA9-D91B0AE2CB63}.Debug|iPhoneSimulator.Build.0 = Debug|iPhoneSimulator
+ {822B0D9D-FA7C-4BC5-9DA9-D91B0AE2CB63}.Release|iPhone.ActiveCfg = Release|iPhone
+ {822B0D9D-FA7C-4BC5-9DA9-D91B0AE2CB63}.Release|iPhone.Build.0 = Release|iPhone
+ {822B0D9D-FA7C-4BC5-9DA9-D91B0AE2CB63}.Release|iPhoneSimulator.ActiveCfg = Release|iPhoneSimulator
+ {822B0D9D-FA7C-4BC5-9DA9-D91B0AE2CB63}.Release|iPhoneSimulator.Build.0 = Release|iPhoneSimulator
+ EndGlobalSection
+ GlobalSection(MonoDevelopProperties) = preSolution
+ StartupItem = MoviePlaybackSample\MoviePlayback.csproj
+ EndGlobalSection
+EndGlobal
View
38 MoviePlayback/MoviePlaybackSample/AppDelegate.cs
@@ -0,0 +1,38 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using MonoTouch.Foundation;
+using MonoTouch.UIKit;
+
+namespace MoviePlaybackSample
+{
+ // The UIApplicationDelegate for the application. This class is responsible for launching the
+ // User Interface of the application, as well as listening (and optionally responding) to
+ // application events from iOS.
+ [Register ("AppDelegate")]
+ public partial class AppDelegate : UIApplicationDelegate
+ {
+ // class-level declarations
+ UIWindow window;
+ MoviePlaybackSampleViewController viewController;
+
+ //
+ // This method is invoked when the application has loaded and is ready to run. In this
+ // method you should instantiate the window, load the UI into it and then make the window
+ // visible.
+ //
+ // You have 17 seconds to return from this method, or iOS will terminate your application.
+ //
+ public override bool FinishedLaunching (UIApplication app, NSDictionary options)
+ {
+ window = new UIWindow (UIScreen.MainScreen.Bounds);
+
+ viewController = new MoviePlaybackSampleViewController ();
+ window.RootViewController = viewController;
+ window.MakeKeyAndVisible ();
+
+ return true;
+ }
+ }
+}
+
View
BIN  MoviePlayback/MoviePlaybackSample/Default-Landscape.png
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
View
BIN  MoviePlayback/MoviePlaybackSample/Default-Portrait.png
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
View
BIN  MoviePlayback/MoviePlaybackSample/Default.png
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
View
BIN  MoviePlayback/MoviePlaybackSample/Default@2x.png
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
View
BIN  MoviePlayback/MoviePlaybackSample/Images/Icons/114_icon.png
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
View
BIN  MoviePlayback/MoviePlaybackSample/Images/Icons/29_icon.png
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
View
BIN  MoviePlayback/MoviePlaybackSample/Images/Icons/50_icon.png
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
View
BIN  MoviePlayback/MoviePlaybackSample/Images/Icons/512_icon.png
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
View
BIN  MoviePlayback/MoviePlaybackSample/Images/Icons/57_icon.png
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
View
BIN  MoviePlayback/MoviePlaybackSample/Images/Icons/58_icon.png
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
View
BIN  MoviePlayback/MoviePlaybackSample/Images/Icons/72_icon.png
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
View
38 MoviePlayback/MoviePlaybackSample/Info.plist
@@ -0,0 +1,38 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
+<plist version="1.0">
+<dict>
+ <key>CFBundleDisplayName</key>
+ <string>MoviePlaybackSample</string>
+ <key>CFBundleIconFiles</key>
+ <array>
+ <string>Images/Icons/57_icon.png</string>
+ <string>Images/Icons/114_icon.png</string>
+ <string>Images/Icons/72_icon.png</string>
+ <string>Images/Icons/29_icon.png</string>
+ <string>Images/Icons/58_icon.png</string>
+ <string>Images/Icons/50_icon.png</string>
+ <string>Images/Icons/512_icon.png</string>
+ </array>
+ <key>CFBundleIdentifier</key>
+ <string>583bff79-dc04-4c39-9348-ec1d66e93b41</string>
+ <key>UIDeviceFamily</key>
+ <array>
+ <integer>1</integer>
+ <integer>2</integer>
+ </array>
+ <key>UISupportedInterfaceOrientations</key>
+ <array>
+ <string>UIInterfaceOrientationPortrait</string>
+ <string>UIInterfaceOrientationLandscapeLeft</string>
+ <string>UIInterfaceOrientationLandscapeRight</string>
+ </array>
+ <key>UISupportedInterfaceOrientations~ipad</key>
+ <array>
+ <string>UIInterfaceOrientationPortrait</string>
+ <string>UIInterfaceOrientationPortraitUpsideDown</string>
+ <string>UIInterfaceOrientationLandscapeLeft</string>
+ <string>UIInterfaceOrientationLandscapeRight</string>
+ </array>
+</dict>
+</plist>
View
19 MoviePlayback/MoviePlaybackSample/Main.cs
@@ -0,0 +1,19 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using MonoTouch.Foundation;
+using MonoTouch.UIKit;
+
+namespace MoviePlaybackSample
+{
+ public class Application
+ {
+ // This is the main entry point of the application.
+ static void Main (string[] args)
+ {
+ // if you want to use a different Application Delegate class from "AppDelegate"
+ // you can specify it here.
+ UIApplication.Main (args, null, "AppDelegate");
+ }
+ }
+}
View
102 MoviePlayback/MoviePlaybackSample/MoviePlayback.csproj
@@ -0,0 +1,102 @@
+<?xml version="1.0" encoding="utf-8"?>
+<Project DefaultTargets="Build" ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
+ <PropertyGroup>
+ <Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
+ <Platform Condition=" '$(Platform)' == '' ">iPhoneSimulator</Platform>
+ <ProductVersion>10.0.0</ProductVersion>
+ <SchemaVersion>2.0</SchemaVersion>
+ <ProjectGuid>{822B0D9D-FA7C-4BC5-9DA9-D91B0AE2CB63}</ProjectGuid>
+ <ProjectTypeGuids>{6BC8ED88-2882-458C-8E55-DFD12B67127B};{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}</ProjectTypeGuids>
+ <OutputType>Exe</OutputType>
+ <RootNamespace>MoviePlaybackSample</RootNamespace>
+ <AssemblyName>MoviePlaybackSample</AssemblyName>
+ </PropertyGroup>
+ <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|iPhoneSimulator' ">
+ <DebugSymbols>true</DebugSymbols>
+ <DebugType>full</DebugType>
+ <Optimize>false</Optimize>
+ <OutputPath>bin\iPhoneSimulator\Debug</OutputPath>
+ <DefineConstants>DEBUG;</DefineConstants>
+ <ErrorReport>prompt</ErrorReport>
+ <WarningLevel>4</WarningLevel>
+ <ConsolePause>false</ConsolePause>
+ <MtouchDebug>true</MtouchDebug>
+ <MtouchProfiling>true</MtouchProfiling>
+ <MtouchLink>None</MtouchLink>
+ <MtouchI18n />
+ </PropertyGroup>
+ <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|iPhoneSimulator' ">
+ <DebugType>none</DebugType>
+ <Optimize>false</Optimize>
+ <OutputPath>bin\iPhoneSimulator\Release</OutputPath>
+ <ErrorReport>prompt</ErrorReport>
+ <WarningLevel>4</WarningLevel>
+ <ConsolePause>false</ConsolePause>
+ <MtouchLink>None</MtouchLink>
+ </PropertyGroup>
+ <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|iPhone' ">
+ <DebugSymbols>true</DebugSymbols>
+ <DebugType>full</DebugType>
+ <Optimize>false</Optimize>
+ <OutputPath>bin\iPhone\Debug</OutputPath>
+ <DefineConstants>DEBUG;</DefineConstants>
+ <ErrorReport>prompt</ErrorReport>
+ <WarningLevel>4</WarningLevel>
+ <ConsolePause>false</ConsolePause>
+ <CodesignKey>iPhone Developer</CodesignKey>
+ <MtouchDebug>true</MtouchDebug>
+ <MtouchProfiling>true</MtouchProfiling>
+ <IpaPackageName />
+ <MtouchI18n />
+ </PropertyGroup>
+ <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|iPhone' ">
+ <DebugType>none</DebugType>
+ <Optimize>false</Optimize>
+ <OutputPath>bin\iPhone\Release</OutputPath>
+ <ErrorReport>prompt</ErrorReport>
+ <WarningLevel>4</WarningLevel>
+ <ConsolePause>false</ConsolePause>
+ <CodesignKey>iPhone Developer</CodesignKey>
+ </PropertyGroup>
+ <ItemGroup>
+ <Reference Include="System" />
+ <Reference Include="System.Xml" />
+ <Reference Include="System.Core" />
+ <Reference Include="monotouch" />
+ </ItemGroup>
+ <ItemGroup>
+ <None Include="Info.plist" />
+ </ItemGroup>
+ <ItemGroup>
+ <Compile Include="Main.cs" />
+ <Compile Include="AppDelegate.cs" />
+ <Compile Include="MoviePlaybackSampleViewController.cs" />
+ <Compile Include="MoviePlaybackSampleViewController.designer.cs">
+ <DependentUpon>MoviePlaybackSampleViewController.cs</DependentUpon>
+ </Compile>
+ </ItemGroup>
+ <ItemGroup>
+ <InterfaceDefinition Include="MoviePlaybackSampleViewController_iPhone.xib" />
+ <InterfaceDefinition Include="MoviePlaybackSampleViewController_iPad.xib" />
+ </ItemGroup>
+ <Import Project="$(MSBuildBinPath)\Microsoft.CSharp.targets" />
+ <ItemGroup>
+ <Folder Include="Images\" />
+ <Folder Include="Images\Icons\" />
+ <Folder Include="Movies\" />
+ </ItemGroup>
+ <ItemGroup>
+ <Content Include="Images\Icons\29_icon.png" />
+ <Content Include="Images\Icons\50_icon.png" />
+ <Content Include="Images\Icons\57_icon.png" />
+ <Content Include="Images\Icons\58_icon.png" />
+ <Content Include="Images\Icons\72_icon.png" />
+ <Content Include="Images\Icons\114_icon.png" />
+ <Content Include="Images\Icons\512_icon.png" />
+ <Content Include="Movies\file.m4v" />
+ <Content Include="Default.png" />
+ <Content Include="Default%402x.png" />
+ <Content Include="Default-Portrait.png" />
+ <Content Include="Default-Landscape.png" />
+ </ItemGroup>
+</Project>
View
76 MoviePlayback/MoviePlaybackSample/MoviePlaybackSampleViewController.cs
@@ -0,0 +1,76 @@
+using MonoTouch.UIKit;
+using System.Drawing;
+using System;
+using MonoTouch.Foundation;
+using MonoTouch.MediaPlayer;
+
+namespace MoviePlaybackSample
+{
+ public partial class MoviePlaybackSampleViewController : UIViewController
+ {
+ //class level declarations
+ MPMoviePlayerController mp = new MPMoviePlayerController();
+
+ static bool UserInterfaceIdiomIsPhone {
+ get { return UIDevice.CurrentDevice.UserInterfaceIdiom == UIUserInterfaceIdiom.Phone; }
+ }
+
+ public MoviePlaybackSampleViewController ()
+ : base (UserInterfaceIdiomIsPhone ? "MoviePlaybackSampleViewController_iPhone" : "MoviePlaybackSampleViewController_iPad", null)
+ {
+ }
+
+ public override void ViewDidLoad ()
+ {
+
+ base.ViewDidLoad ();
+
+ //Button Events
+ playMovieButton.TouchUpInside += delegate {
+
+ try{
+
+ //Set already instantiated MPMoviePlayerController to playback from Movies/file.m4v
+ mp = new MPMoviePlayerController (NSUrl.FromFilename("Movies/file.m4v"));
+
+ //enable AirPlay
+ mp.AllowsAirPlay = true;
+
+ //Add the MPMoviePlayerController View
+ this.View.AddSubview(mp.View);
+
+ //set the view to be full screen and show animated
+ mp.SetFullscreen(true, true);
+
+ //MPMoviePlayer must be set to PrepareToPlay before playback
+ mp.PrepareToPlay();
+
+ //Play Movie
+ mp.Play();
+
+ }catch{
+
+ Console.WriteLine("There was a problem playing back Video");
+
+ }
+
+ };
+
+ }
+
+ public override void ViewDidUnload ()
+ {
+ base.ViewDidUnload ();
+ }
+
+ public override bool ShouldAutorotateToInterfaceOrientation (UIInterfaceOrientation toInterfaceOrientation)
+ {
+ // Return true for supported orientations
+ if (UserInterfaceIdiomIsPhone) {
+ return (toInterfaceOrientation != UIInterfaceOrientation.PortraitUpsideDown);
+ } else {
+ return true;
+ }
+ }
+ }
+}
View
25 MoviePlayback/MoviePlaybackSample/MoviePlaybackSampleViewController.designer.cs
@@ -0,0 +1,25 @@
+// WARNING
+//
+// This file has been generated automatically by MonoDevelop to store outlets and
+// actions made in the Xcode designer. If it is removed, they will be lost.
+// Manual changes to this file may not be handled correctly.
+//
+using MonoTouch.Foundation;
+
+namespace MoviePlaybackSample
+{
+ [Register ("MoviePlaybackSampleViewController")]
+ partial class MoviePlaybackSampleViewController
+ {
+ [Outlet]
+ MonoTouch.UIKit.UIButton playMovieButton { get; set; }
+
+ void ReleaseDesignerOutlets ()
+ {
+ if (playMovieButton != null) {
+ playMovieButton.Dispose ();
+ playMovieButton = null;
+ }
+ }
+ }
+}
View
186 MoviePlayback/MoviePlaybackSample/MoviePlaybackSampleViewController_iPad.xib
@@ -0,0 +1,186 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<archive type="com.apple.InterfaceBuilder3.CocoaTouch.iPad.XIB" version="8.00">
+ <data>
+ <int key="IBDocument.SystemTarget">1280</int>
+ <string key="IBDocument.SystemVersion">10K549</string>
+ <string key="IBDocument.InterfaceBuilderVersion">1938</string>
+ <string key="IBDocument.AppKitVersion">1038.36</string>
+ <string key="IBDocument.HIToolboxVersion">461.00</string>
+ <object class="NSMutableDictionary" key="IBDocument.PluginVersions">
+ <string key="NS.key.0">com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string>
+ <string key="NS.object.0">933</string>
+ </object>
+ <array key="IBDocument.IntegratedClassDependencies">
+ <string>IBProxyObject</string>
+ <string>IBUIView</string>
+ <string>IBUIButton</string>
+ </array>
+ <array key="IBDocument.PluginDependencies">
+ <string>com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string>
+ </array>
+ <object class="NSMutableDictionary" key="IBDocument.Metadata">
+ <string key="NS.key.0">PluginDependencyRecalculationVersion</string>
+ <integer value="1" key="NS.object.0"/>
+ </object>
+ <array class="NSMutableArray" key="IBDocument.RootObjects" id="1000">
+ <object class="IBProxyObject" id="841351856">
+ <string key="IBProxiedObjectIdentifier">IBFilesOwner</string>
+ <string key="targetRuntimeIdentifier">IBIPadFramework</string>
+ </object>
+ <object class="IBProxyObject" id="606714003">
+ <string key="IBProxiedObjectIdentifier">IBFirstResponder</string>
+ <string key="targetRuntimeIdentifier">IBIPadFramework</string>
+ </object>
+ <object class="IBUIView" id="766721923">
+ <reference key="NSNextResponder"/>
+ <int key="NSvFlags">274</int>
+ <array class="NSMutableArray" key="NSSubviews">
+ <object class="IBUIButton" id="142714019">
+ <reference key="NSNextResponder" ref="766721923"/>
+ <int key="NSvFlags">292</int>
+ <string key="NSFrame">{{299, 189}, {102, 37}}</string>
+ <reference key="NSSuperview" ref="766721923"/>
+ <reference key="NSWindow"/>
+ <bool key="IBUIOpaque">NO</bool>
+ <string key="targetRuntimeIdentifier">IBIPadFramework</string>
+ <int key="IBUIContentHorizontalAlignment">0</int>
+ <int key="IBUIContentVerticalAlignment">0</int>
+ <int key="IBUIButtonType">1</int>
+ <string key="IBUINormalTitle">Play Movie</string>
+ <object class="NSColor" key="IBUIHighlightedTitleColor">
+ <int key="NSColorSpace">3</int>
+ <bytes key="NSWhite">MQA</bytes>
+ </object>
+ <object class="NSColor" key="IBUINormalTitleColor">
+ <int key="NSColorSpace">1</int>
+ <bytes key="NSRGB">MC4xOTYwNzg0MzQ2IDAuMzA5ODAzOTMyOSAwLjUyMTU2ODY1NgA</bytes>
+ </object>
+ <object class="NSColor" key="IBUINormalTitleShadowColor">
+ <int key="NSColorSpace">3</int>
+ <bytes key="NSWhite">MC41AA</bytes>
+ </object>
+ <object class="IBUIFontDescription" key="IBUIFontDescription">
+ <int key="type">2</int>
+ <double key="pointSize">15</double>
+ </object>
+ <object class="NSFont" key="IBUIFont">
+ <string key="NSName">Helvetica-Bold</string>
+ <double key="NSSize">15</double>
+ <int key="NSfFlags">16</int>
+ </object>
+ </object>
+ </array>
+ <string key="NSFrame">{{0, 20}, {768, 1004}}</string>
+ <reference key="NSSuperview"/>
+ <reference key="NSWindow"/>
+ <reference key="NSNextKeyView" ref="142714019"/>
+ <object class="NSColor" key="IBUIBackgroundColor">
+ <int key="NSColorSpace">3</int>
+ <bytes key="NSWhite">MQA</bytes>
+ <object class="NSColorSpace" key="NSCustomColorSpace">
+ <int key="NSID">2</int>
+ </object>
+ </object>
+ <object class="IBUISimulatedStatusBarMetrics" key="IBUISimulatedStatusBarMetrics">
+ <int key="IBUIStatusBarStyle">2</int>
+ </object>
+ <string key="targetRuntimeIdentifier">IBIPadFramework</string>
+ </object>
+ </array>
+ <object class="IBObjectContainer" key="IBDocument.Objects">
+ <array class="NSMutableArray" key="connectionRecords">
+ <object class="IBConnectionRecord">
+ <object class="IBCocoaTouchOutletConnection" key="connection">
+ <string key="label">view</string>
+ <reference key="source" ref="841351856"/>
+ <reference key="destination" ref="766721923"/>
+ </object>
+ <int key="connectionID">3</int>
+ </object>
+ <object class="IBConnectionRecord">
+ <object class="IBCocoaTouchOutletConnection" key="connection">
+ <string key="label">playMovieButton</string>
+ <reference key="source" ref="841351856"/>
+ <reference key="destination" ref="142714019"/>
+ </object>
+ <int key="connectionID">6</int>
+ </object>
+ </array>
+ <object class="IBMutableOrderedSet" key="objectRecords">
+ <array key="orderedObjects">
+ <object class="IBObjectRecord">
+ <int key="objectID">0</int>
+ <array key="object" id="0"/>
+ <reference key="children" ref="1000"/>
+ <nil key="parent"/>
+ </object>
+ <object class="IBObjectRecord">
+ <int key="objectID">-1</int>
+ <reference key="object" ref="841351856"/>
+ <reference key="parent" ref="0"/>
+ <string key="objectName">File's Owner</string>
+ </object>
+ <object class="IBObjectRecord">
+ <int key="objectID">-2</int>
+ <reference key="object" ref="606714003"/>
+ <reference key="parent" ref="0"/>
+ </object>
+ <object class="IBObjectRecord">
+ <int key="objectID">2</int>
+ <reference key="object" ref="766721923"/>
+ <array class="NSMutableArray" key="children">
+ <reference ref="142714019"/>
+ </array>
+ <reference key="parent" ref="0"/>
+ </object>
+ <object class="IBObjectRecord">
+ <int key="objectID">4</int>
+ <reference key="object" ref="142714019"/>
+ <reference key="parent" ref="766721923"/>
+ </object>
+ </array>
+ </object>
+ <dictionary class="NSMutableDictionary" key="flattenedProperties">
+ <string key="-1.CustomClassName">MoviePlaybackSampleViewController</string>
+ <string key="-1.IBPluginDependency">com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string>
+ <string key="-2.CustomClassName">UIResponder</string>
+ <string key="-2.IBPluginDependency">com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string>
+ <string key="2.IBPluginDependency">com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string>
+ <string key="4.IBPluginDependency">com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string>
+ </dictionary>
+ <dictionary class="NSMutableDictionary" key="unlocalizedProperties"/>
+ <nil key="activeLocalization"/>
+ <dictionary class="NSMutableDictionary" key="localizations"/>
+ <nil key="sourceID"/>
+ <int key="maxID">6</int>
+ </object>
+ <object class="IBClassDescriber" key="IBDocument.Classes">
+ <array class="NSMutableArray" key="referencedPartialClassDescriptions">
+ <object class="IBPartialClassDescription">
+ <string key="className">MoviePlaybackSampleViewController</string>
+ <string key="superclassName">UIViewController</string>
+ <object class="NSMutableDictionary" key="outlets">
+ <string key="NS.key.0">playMovieButton</string>
+ <string key="NS.object.0">UIButton</string>
+ </object>
+ <object class="NSMutableDictionary" key="toOneOutletInfosByName">
+ <string key="NS.key.0">playMovieButton</string>
+ <object class="IBToOneOutletInfo" key="NS.object.0">
+ <string key="name">playMovieButton</string>
+ <string key="candidateClassName">UIButton</string>
+ </object>
+ </object>
+ <object class="IBClassDescriptionSource" key="sourceIdentifier">
+ <string key="majorKey">IBProjectSource</string>
+ <string key="minorKey">./Classes/MoviePlaybackSampleViewController.h</string>
+ </object>
+ </object>
+ </array>
+ </object>
+ <int key="IBDocument.localizationMode">0</int>
+ <string key="IBDocument.TargetRuntimeIdentifier">IBIPadFramework</string>
+ <bool key="IBDocument.PluginDeclaredDependenciesTrackSystemTargetVersion">YES</bool>
+ <int key="IBDocument.defaultPropertyAccessControl">3</int>
+ <string key="IBCocoaTouchPluginVersion">933</string>
+ </data>
+</archive>
View
210 MoviePlayback/MoviePlaybackSample/MoviePlaybackSampleViewController_iPhone.xib
@@ -0,0 +1,210 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<archive type="com.apple.InterfaceBuilder3.CocoaTouch.XIB" version="8.00">
+ <data>
+ <int key="IBDocument.SystemTarget">1280</int>
+ <string key="IBDocument.SystemVersion">10K549</string>
+ <string key="IBDocument.InterfaceBuilderVersion">1938</string>
+ <string key="IBDocument.AppKitVersion">1038.36</string>
+ <string key="IBDocument.HIToolboxVersion">461.00</string>
+ <object class="NSMutableDictionary" key="IBDocument.PluginVersions">
+ <string key="NS.key.0">com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string>
+ <string key="NS.object.0">933</string>
+ </object>
+ <array key="IBDocument.IntegratedClassDependencies">
+ <string>IBProxyObject</string>
+ <string>IBUIView</string>
+ <string>IBUIButton</string>
+ </array>
+ <array key="IBDocument.PluginDependencies">
+ <string>com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string>
+ </array>
+ <object class="NSMutableDictionary" key="IBDocument.Metadata">
+ <string key="NS.key.0">PluginDependencyRecalculationVersion</string>
+ <integer value="1" key="NS.object.0"/>
+ </object>
+ <array class="NSMutableArray" key="IBDocument.RootObjects" id="1000">
+ <object class="IBProxyObject" id="372490531">
+ <string key="IBProxiedObjectIdentifier">IBFilesOwner</string>
+ <string key="targetRuntimeIdentifier">IBCocoaTouchFramework</string>
+ </object>
+ <object class="IBProxyObject" id="843779117">
+ <string key="IBProxiedObjectIdentifier">IBFirstResponder</string>
+ <string key="targetRuntimeIdentifier">IBCocoaTouchFramework</string>
+ </object>
+ <object class="IBUIView" id="774585933">
+ <reference key="NSNextResponder"/>
+ <int key="NSvFlags">274</int>
+ <array class="NSMutableArray" key="NSSubviews">
+ <object class="IBUIView" id="488693319">
+ <reference key="NSNextResponder" ref="774585933"/>
+ <int key="NSvFlags">274</int>
+ <array class="NSMutableArray" key="NSSubviews">
+ <object class="IBUIButton" id="549518939">
+ <reference key="NSNextResponder" ref="488693319"/>
+ <int key="NSvFlags">292</int>
+ <string key="NSFrame">{{109, 74}, {102, 37}}</string>
+ <reference key="NSSuperview" ref="488693319"/>
+ <reference key="NSWindow"/>
+ <bool key="IBUIOpaque">NO</bool>
+ <string key="targetRuntimeIdentifier">IBCocoaTouchFramework</string>
+ <int key="IBUIContentHorizontalAlignment">0</int>
+ <int key="IBUIContentVerticalAlignment">0</int>
+ <int key="IBUIButtonType">1</int>
+ <string key="IBUINormalTitle">Play Movie</string>
+ <object class="NSColor" key="IBUIHighlightedTitleColor">
+ <int key="NSColorSpace">3</int>
+ <bytes key="NSWhite">MQA</bytes>
+ </object>
+ <object class="NSColor" key="IBUINormalTitleColor">
+ <int key="NSColorSpace">1</int>
+ <bytes key="NSRGB">MC4xOTYwNzg0MzQ2IDAuMzA5ODAzOTMyOSAwLjUyMTU2ODY1NgA</bytes>
+ </object>
+ <object class="NSColor" key="IBUINormalTitleShadowColor">
+ <int key="NSColorSpace">3</int>
+ <bytes key="NSWhite">MC41AA</bytes>
+ </object>
+ <object class="IBUIFontDescription" key="IBUIFontDescription">
+ <int key="type">2</int>
+ <double key="pointSize">15</double>
+ </object>
+ <object class="NSFont" key="IBUIFont">
+ <string key="NSName">Helvetica-Bold</string>
+ <double key="NSSize">15</double>
+ <int key="NSfFlags">16</int>
+ </object>
+ </object>
+ </array>
+ <string key="NSFrameSize">{320, 460}</string>
+ <reference key="NSSuperview" ref="774585933"/>
+ <reference key="NSWindow"/>
+ <reference key="NSNextKeyView" ref="549518939"/>
+ <object class="NSColor" key="IBUIBackgroundColor">
+ <int key="NSColorSpace">3</int>
+ <bytes key="NSWhite">MQA</bytes>
+ <object class="NSColorSpace" key="NSCustomColorSpace" id="1803268">
+ <int key="NSID">2</int>
+ </object>
+ </object>
+ <string key="targetRuntimeIdentifier">IBCocoaTouchFramework</string>
+ </object>
+ </array>
+ <string key="NSFrame">{{0, 20}, {320, 460}}</string>
+ <reference key="NSSuperview"/>
+ <reference key="NSWindow"/>
+ <reference key="NSNextKeyView" ref="488693319"/>
+ <object class="NSColor" key="IBUIBackgroundColor">
+ <int key="NSColorSpace">3</int>
+ <bytes key="NSWhite">MC43NQA</bytes>
+ <reference key="NSCustomColorSpace" ref="1803268"/>
+ </object>
+ <bool key="IBUIClearsContextBeforeDrawing">NO</bool>
+ <object class="IBUISimulatedStatusBarMetrics" key="IBUISimulatedStatusBarMetrics"/>
+ <string key="targetRuntimeIdentifier">IBCocoaTouchFramework</string>
+ </object>
+ </array>
+ <object class="IBObjectContainer" key="IBDocument.Objects">
+ <array class="NSMutableArray" key="connectionRecords">
+ <object class="IBConnectionRecord">
+ <object class="IBCocoaTouchOutletConnection" key="connection">
+ <string key="label">view</string>
+ <reference key="source" ref="372490531"/>
+ <reference key="destination" ref="774585933"/>
+ </object>
+ <int key="connectionID">7</int>
+ </object>
+ <object class="IBConnectionRecord">
+ <object class="IBCocoaTouchOutletConnection" key="connection">
+ <string key="label">playMovieButton</string>
+ <reference key="source" ref="372490531"/>
+ <reference key="destination" ref="549518939"/>
+ </object>
+ <int key="connectionID">11</int>
+ </object>
+ </array>
+ <object class="IBMutableOrderedSet" key="objectRecords">
+ <array key="orderedObjects">
+ <object class="IBObjectRecord">
+ <int key="objectID">0</int>
+ <array key="object" id="0"/>
+ <reference key="children" ref="1000"/>
+ <nil key="parent"/>
+ </object>
+ <object class="IBObjectRecord">
+ <int key="objectID">-1</int>
+ <reference key="object" ref="372490531"/>
+ <reference key="parent" ref="0"/>
+ <string key="objectName">File's Owner</string>
+ </object>
+ <object class="IBObjectRecord">
+ <int key="objectID">-2</int>
+ <reference key="object" ref="843779117"/>
+ <reference key="parent" ref="0"/>
+ </object>
+ <object class="IBObjectRecord">
+ <int key="objectID">6</int>
+ <reference key="object" ref="774585933"/>
+ <array class="NSMutableArray" key="children">
+ <reference ref="488693319"/>
+ </array>
+ <reference key="parent" ref="0"/>
+ </object>
+ <object class="IBObjectRecord">
+ <int key="objectID">8</int>
+ <reference key="object" ref="488693319"/>
+ <array class="NSMutableArray" key="children">
+ <reference ref="549518939"/>
+ </array>
+ <reference key="parent" ref="774585933"/>
+ </object>
+ <object class="IBObjectRecord">
+ <int key="objectID">9</int>
+ <reference key="object" ref="549518939"/>
+ <reference key="parent" ref="488693319"/>
+ </object>
+ </array>
+ </object>
+ <dictionary class="NSMutableDictionary" key="flattenedProperties">
+ <string key="-1.CustomClassName">MoviePlaybackSampleViewController</string>
+ <string key="-1.IBPluginDependency">com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string>
+ <string key="-2.CustomClassName">UIResponder</string>
+ <string key="-2.IBPluginDependency">com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string>
+ <string key="6.IBPluginDependency">com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string>
+ <string key="8.IBPluginDependency">com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string>
+ <string key="9.IBPluginDependency">com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string>
+ </dictionary>
+ <dictionary class="NSMutableDictionary" key="unlocalizedProperties"/>
+ <nil key="activeLocalization"/>
+ <dictionary class="NSMutableDictionary" key="localizations"/>
+ <nil key="sourceID"/>
+ <int key="maxID">11</int>
+ </object>
+ <object class="IBClassDescriber" key="IBDocument.Classes">
+ <array class="NSMutableArray" key="referencedPartialClassDescriptions">
+ <object class="IBPartialClassDescription">
+ <string key="className">MoviePlaybackSampleViewController</string>
+ <string key="superclassName">UIViewController</string>
+ <object class="NSMutableDictionary" key="outlets">
+ <string key="NS.key.0">playMovieButton</string>
+ <string key="NS.object.0">UIButton</string>
+ </object>
+ <object class="NSMutableDictionary" key="toOneOutletInfosByName">
+ <string key="NS.key.0">playMovieButton</string>
+ <object class="IBToOneOutletInfo" key="NS.object.0">
+ <string key="name">playMovieButton</string>
+ <string key="candidateClassName">UIButton</string>
+ </object>
+ </object>
+ <object class="IBClassDescriptionSource" key="sourceIdentifier">
+ <string key="majorKey">IBProjectSource</string>
+ <string key="minorKey">./Classes/MoviePlaybackSampleViewController.h</string>
+ </object>
+ </object>
+ </array>
+ </object>
+ <int key="IBDocument.localizationMode">0</int>
+ <string key="IBDocument.TargetRuntimeIdentifier">IBCocoaTouchFramework</string>
+ <bool key="IBDocument.PluginDeclaredDependenciesTrackSystemTargetVersion">YES</bool>
+ <int key="IBDocument.defaultPropertyAccessControl">3</int>
+ <string key="IBCocoaTouchPluginVersion">933</string>
+ </data>
+</archive>
View
BIN  MoviePlayback/MoviePlaybackSample/Movies/file.m4v
Binary file not shown
View
13 MoviePlayback/README.md
@@ -0,0 +1,13 @@
+MoviePlayback
+=============
+
+MoviePlayback is an example on how to use the MPMoviePlayerController
+class to play any standard movie type that iOS supports.
+
+The example also shows how to enable Airplay for displayed movies from
+within your applications.
+
+Authors
+-------
+
+James Bentley
View
BIN  MoviePlayback/Screenshots/01.png
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
View
1  Sound/Metadata.xml
@@ -0,0 +1 @@
+<?xml version="1.0" encoding="utf-8" ?>
View
10 Sound/README.md
@@ -0,0 +1,10 @@
+Sound
+=====
+
+Sound is a simple example of how to record an AAC file using the iPhone
+microphone or externally attached recording hardware and then play it back.
+
+Authors
+-------
+
+James Bentley, Bryan Costanich
View
BIN  Sound/Screenshots/01.png
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
View
BIN  Sound/Screenshots/02.png
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
View
BIN  Sound/Screenshots/03.png
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
View
BIN  Sound/Screenshots/04.png
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
View
26 Sound/Sound.sln
@@ -0,0 +1,26 @@
+
+Microsoft Visual Studio Solution File, Format Version 11.00
+# Visual Studio 2010
+Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Sound", "Sound\Sound.csproj", "{55F46846-CDA1-4BC2-9C40-0458BC6F909C}"
+EndProject
+Global
+ GlobalSection(SolutionConfigurationPlatforms) = preSolution
+ Debug|iPhoneSimulator = Debug|iPhoneSimulator
+ Release|iPhoneSimulator = Release|iPhoneSimulator
+ Debug|iPhone = Debug|iPhone
+ Release|iPhone = Release|iPhone
+ EndGlobalSection
+ GlobalSection(ProjectConfigurationPlatforms) = postSolution
+ {55F46846-CDA1-4BC2-9C40-0458BC6F909C}.Debug|iPhone.ActiveCfg = Debug|iPhone
+ {55F46846-CDA1-4BC2-9C40-0458BC6F909C}.Debug|iPhone.Build.0 = Debug|iPhone
+ {55F46846-CDA1-4BC2-9C40-0458BC6F909C}.Debug|iPhoneSimulator.ActiveCfg = Debug|iPhoneSimulator
+ {55F46846-CDA1-4BC2-9C40-0458BC6F909C}.Debug|iPhoneSimulator.Build.0 = Debug|iPhoneSimulator
+ {55F46846-CDA1-4BC2-9C40-0458BC6F909C}.Release|iPhone.ActiveCfg = Release|iPhone
+ {55F46846-CDA1-4BC2-9C40-0458BC6F909C}.Release|iPhone.Build.0 = Release|iPhone
+ {55F46846-CDA1-4BC2-9C40-0458BC6F909C}.Release|iPhoneSimulator.ActiveCfg = Release|iPhoneSimulator
+ {55F46846-CDA1-4BC2-9C40-0458BC6F909C}.Release|iPhoneSimulator.Build.0 = Release|iPhoneSimulator
+ EndGlobalSection
+ GlobalSection(MonoDevelopProperties) = preSolution
+ StartupItem = Sound\Sound.csproj
+ EndGlobalSection
+EndGlobal
View
39 Sound/Sound/AppDelegate.cs
@@ -0,0 +1,39 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+
+using MonoTouch.Foundation;
+using MonoTouch.UIKit;
+
+namespace Sound
+{
+ // The UIApplicationDelegate for the application. This class is responsible for launching the
+ // User Interface of the application, as well as listening (and optionally responding) to
+ // application events from iOS.
+ [Register ("AppDelegate")]
+ public partial class AppDelegate : UIApplicationDelegate
+ {
+ // class-level declarations
+ UIWindow window;
+ SoundViewController viewController;
+
+ //
+ // This method is invoked when the application has loaded and is ready to run. In this
+ // method you should instantiate the window, load the UI into it and then make the window
+ // visible.
+ //
+ // You have 17 seconds to return from this method, or iOS will terminate your application.
+ //
+ public override bool FinishedLaunching (UIApplication app, NSDictionary options)
+ {
+ window = new UIWindow (UIScreen.MainScreen.Bounds);
+
+ viewController = new SoundViewController ();
+ window.RootViewController = viewController;
+ window.MakeKeyAndVisible ();
+
+ return true;
+ }
+ }
+}
+
View
BIN  Sound/Sound/Default-Landscape~ipad.png
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
View
BIN  Sound/Sound/Default-Portrait~ipad.png
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
View
BIN  Sound/Sound/Default.png
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
View
BIN  Sound/Sound/Default@2x.png
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
View
BIN  Sound/Sound/Images/Icons/114_icon.png
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
View
BIN  Sound/Sound/Images/Icons/29_icon.png
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
View
BIN  Sound/Sound/Images/Icons/50_icon.png
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
View
BIN  Sound/Sound/Images/Icons/512_icon.png
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
View
BIN  Sound/Sound/Images/Icons/57_icon.png
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
View
BIN  Sound/Sound/Images/Icons/58_icon.png
Diff not rendered
View
BIN  Sound/Sound/Images/Icons/72_icon.png
Diff not rendered
View
37 Sound/Sound/Info.plist
@@ -0,0 +1,37 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
+<plist version="1.0">
+<dict>
+ <key>CFBundleDisplayName</key>
+ <string>Sound</string>
+ <key>CFBundleIconFiles</key>
+ <array>
+ <string>Images/Icons/57_icon.png</string>
+ <string>Images/Icons/114_icon.png</string>
+ <string>Images/Icons/72_icon.png</string>
+ <string>Images/Icons/29_icon.png</string>
+ <string>Images/Icons/58_icon.png</string>
+ <string>Images/Icons/50_icon.png</string>
+ <string>Images/Icons/512_icon.png</string>
+ </array>
+ <key>UIDeviceFamily</key>
+ <array>
+ <integer>1</integer>
+ <integer>2</integer>
+ </array>
+ <key>UISupportedInterfaceOrientations</key>
+ <array>
+ <string>UIInterfaceOrientationPortrait</string>
+ <string>UIInterfaceOrientationPortraitUpsideDown</string>
+ <string>UIInterfaceOrientationLandscapeLeft</string>
+ <string>UIInterfaceOrientationLandscapeRight</string>
+ </array>
+ <key>UISupportedInterfaceOrientations~ipad</key>
+ <array>
+ <string>UIInterfaceOrientationPortrait</string>
+ <string>UIInterfaceOrientationPortraitUpsideDown</string>
+ <string>UIInterfaceOrientationLandscapeLeft</string>
+ <string>UIInterfaceOrientationLandscapeRight</string>
+ </array>
+</dict>
+</plist>
View
20 Sound/Sound/Main.cs
@@ -0,0 +1,20 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+
+using MonoTouch.Foundation;
+using MonoTouch.UIKit;
+
+namespace Sound
+{
+ public class Application
+ {
+ // This is the main entry point of the application.
+ static void Main (string[] args)
+ {
+ // if you want to use a different Application Delegate class from "AppDelegate"
+ // you can specify it here.
+ UIApplication.Main (args, null, "AppDelegate");
+ }
+ }
+}
View
99 Sound/Sound/Sound.csproj
@@ -0,0 +1,99 @@
+<?xml version="1.0" encoding="utf-8"?>
+<Project DefaultTargets="Build" ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
+ <PropertyGroup>
+ <Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
+ <Platform Condition=" '$(Platform)' == '' ">iPhoneSimulator</Platform>
+ <ProductVersion>10.0.0</ProductVersion>
+ <SchemaVersion>2.0</SchemaVersion>
+ <ProjectGuid>{55F46846-CDA1-4BC2-9C40-0458BC6F909C}</ProjectGuid>
+ <ProjectTypeGuids>{6BC8ED88-2882-458C-8E55-DFD12B67127B};{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}</ProjectTypeGuids>
+ <OutputType>Exe</OutputType>
+ <RootNamespace>Sound</RootNamespace>
+ <AssemblyName>Sound</AssemblyName>
+ </PropertyGroup>
+ <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|iPhoneSimulator' ">
+ <DebugSymbols>true</DebugSymbols>
+ <DebugType>full</DebugType>
+ <Optimize>false</Optimize>
+ <OutputPath>bin\iPhoneSimulator\Debug</OutputPath>
+ <DefineConstants>DEBUG;</DefineConstants>
+ <ErrorReport>prompt</ErrorReport>
+ <WarningLevel>4</WarningLevel>
+ <ConsolePause>false</ConsolePause>
+ <MtouchDebug>true</MtouchDebug>
+ <MtouchProfiling>true</MtouchProfiling>
+ <MtouchLink>None</MtouchLink>
+ </PropertyGroup>
+ <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|iPhoneSimulator' ">
+ <DebugType>none</DebugType>
+ <Optimize>false</Optimize>
+ <OutputPath>bin\iPhoneSimulator\Release</OutputPath>
+ <ErrorReport>prompt</ErrorReport>
+ <WarningLevel>4</WarningLevel>
+ <ConsolePause>false</ConsolePause>
+ <MtouchLink>None</MtouchLink>
+ </PropertyGroup>
+ <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|iPhone' ">
+ <DebugSymbols>true</DebugSymbols>
+ <DebugType>full</DebugType>
+ <Optimize>false</Optimize>
+ <OutputPath>bin\iPhone\Debug</OutputPath>
+ <DefineConstants>DEBUG;</DefineConstants>
+ <ErrorReport>prompt</ErrorReport>
+ <WarningLevel>4</WarningLevel>
+ <ConsolePause>false</ConsolePause>
+ <CodesignKey>iPhone Developer</CodesignKey>
+ <MtouchDebug>true</MtouchDebug>
+ <MtouchProfiling>true</MtouchProfiling>
+ <IpaPackageName />
+ <MtouchI18n />
+ </PropertyGroup>
+ <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|iPhone' ">
+ <DebugType>none</DebugType>
+ <Optimize>false</Optimize>
+ <OutputPath>bin\iPhone\Release</OutputPath>
+ <ErrorReport>prompt</ErrorReport>
+ <WarningLevel>4</WarningLevel>
+ <ConsolePause>false</ConsolePause>
+ <CodesignKey>iPhone Developer</CodesignKey>
+ </PropertyGroup>
+ <ItemGroup>
+ <Reference Include="System" />
+ <Reference Include="System.Xml" />
+ <Reference Include="System.Core" />
+ <Reference Include="monotouch" />
+ </ItemGroup>
+ <ItemGroup>
+ <None Include="Info.plist" />
+ </ItemGroup>
+ <ItemGroup>
+ <Compile Include="Main.cs" />
+ <Compile Include="AppDelegate.cs" />
+ <Compile Include="SoundViewController.cs" />
+ <Compile Include="SoundViewController.designer.cs">
+ <DependentUpon>SoundViewController.cs</DependentUpon>
+ </Compile>
+ </ItemGroup>
+ <ItemGroup>
+ <InterfaceDefinition Include="SoundViewController_iPhone.xib" />
+ <InterfaceDefinition Include="SoundViewController_iPad.xib" />
+ </ItemGroup>
+ <Import Project="$(MSBuildBinPath)\Microsoft.CSharp.targets" />
+ <ItemGroup>
+ <Content Include="Default-Landscape~ipad.png" />
+ <Content Include="Default-Portrait~ipad.png" />
+ <Content Include="Default.png" />
+ <Content Include="Default%402x.png" />
+ <Content Include="Images\Icons\29_icon.png" />
+ <Content Include="Images\Icons\50_icon.png" />
+ <Content Include="Images\Icons\57_icon.png" />
+ <Content Include="Images\Icons\58_icon.png" />
+ <Content Include="Images\Icons\72_icon.png" />
+ <Content Include="Images\Icons\114_icon.png" />
+ <Content Include="Images\Icons\512_icon.png" />
+ </ItemGroup>
+ <ItemGroup>
+ <Folder Include="Images\" />
+ <Folder Include="Images\Icons\" />
+ </ItemGroup>
+</Project>
View
153 Sound/Sound/SoundViewController.cs
@@ -0,0 +1,153 @@
+using System;
+using System.Drawing;
+
+using MonoTouch.Foundation;
+using MonoTouch.UIKit;
+using MonoTouch.AVFoundation;
+using System.Diagnostics;
+using System.IO;
+using MonoTouch.AudioToolbox;
+
+namespace Sound
+{
+ public partial class SoundViewController : UIViewController
+ {
+ // declarations
+ AVAudioRecorder recorder;
+ AVPlayer player;
+ NSDictionary settings;
+ Stopwatch stopwatch = null;
+ NSUrl audioFilePath = null;
+
+ static bool UserInterfaceIdiomIsPhone {
+ get { return UIDevice.CurrentDevice.UserInterfaceIdiom == UIUserInterfaceIdiom.Phone; }
+ }
+
+ public SoundViewController ()
+ : base (UserInterfaceIdiomIsPhone ? "SoundViewController_iPhone" : "SoundViewController_iPad", null)
+ {
+ }
+
+ public override void ViewDidLoad ()
+ {
+ base.ViewDidLoad ();
+
+ this.RecordingStatusLabel.Text = "";
+ this.LengthOfRecordingLabel.Text = "";
+
+ // start recording wireup
+ this.StartRecordingButton.TouchUpInside += (sender, e) => {
+ Console.WriteLine("Begin Recording");
+
+ this.PrepareAudioRecording();
+ this.recorder.Record();
+
+ this.stopwatch = new Stopwatch();
+ this.stopwatch.Start();
+ this.LengthOfRecordingLabel.Text = "";
+ this.RecordingStatusLabel.Text = "Recording";
+ this.StartRecordingButton.Enabled = false;
+ this.StopRecordingButton.Enabled = true;
+ this.PlayRecordedSoundButton.Enabled = false;
+ };
+
+ // stop recording wireup
+ this.StopRecordingButton.TouchUpInside += (sender, e) => {
+ this.recorder.Stop();
+
+ recorder.FinishedRecording += delegate {
+ recorder.Dispose();
+ Console.WriteLine("Done Recording");
+ };
+
+ this.LengthOfRecordingLabel.Text = string.Format("{0:hh\\:mm\\:ss}", this.stopwatch.Elapsed);
+ this.stopwatch.Stop();
+ this.RecordingStatusLabel.Text = "";
+ this.StartRecordingButton.Enabled = true;
+ this.StopRecordingButton.Enabled = false;
+ this.PlayRecordedSoundButton.Enabled = true;
+ };
+
+ // play recorded sound wireup
+ this.PlayRecordedSoundButton.TouchUpInside += (sender, e) => {
+ try {
+
+ Console.WriteLine("Playing Back Recording " + this.audioFilePath.ToString());
+
+ // The following line prevents the audio from stopping
+ // when the device autolocks. will also make sure that it plays, even
+ // if the device is in mute
+ AudioSession.Category = AudioSessionCategory.MediaPlayback;
+ AudioSession.RoutingOverride = AudioSessionRoutingOverride.Speaker;
+
+ this.player = new AVPlayer (this.audioFilePath);
+ this.player.Play();
+
+ } catch (Exception ex) {
+ Console.WriteLine("There was a problem playing back audio: ");
+ Console.WriteLine(ex.Message);
+ }
+
+ };
+ }
+
+ public override void ViewDidUnload ()
+ {
+ base.ViewDidUnload ();
+
+ // Clear any references to subviews of the main view in order to
+ // allow the Garbage Collector to collect them sooner.
+ //
+ // e.g. myOutlet.Dispose (); myOutlet = null;
+
+ ReleaseDesignerOutlets ();
+ }
+
+ public override bool ShouldAutorotateToInterfaceOrientation (UIInterfaceOrientation toInterfaceOrientation)
+ {
+ return true;
+ }
+
+ protected void PrepareAudioRecording()
+ {
+ //Declare string for application temp path and tack on the file extension
+ string fileName = string.Format ("Myfile{0}.aac", DateTime.Now.ToString ("yyyyMMddHHmmss"));
+ string tempRecording = NSBundle.MainBundle.BundlePath + "/../tmp/" + fileName;
+
+ Console.WriteLine(tempRecording);
+ this.audioFilePath = NSUrl.FromFilename(tempRecording);
+
+ //set up the NSObject Array of values that will be combined with the keys to make the NSDictionary
+ NSObject[] values = new NSObject[]
+ {
+ NSNumber.FromFloat(44100.0f),
+ NSNumber.FromInt32((int)MonoTouch.AudioToolbox.AudioFormatType.MPEG4AAC),
+ NSNumber.FromInt32(1),
+ NSNumber.FromInt32((int)AVAudioQuality.High)
+ };
+ //Set up the NSObject Array of keys that will be combined with the values to make the NSDictionary
+ NSObject[] keys = new NSObject[]
+ {
+ AVAudioSettings.AVSampleRateKey,
+ AVAudioSettings.AVFormatIDKey,
+ AVAudioSettings.AVNumberOfChannelsKey,
+ AVAudioSettings.AVEncoderAudioQualityKey
+ };
+ //Set Settings with the Values and Keys to create the NSDictionary
+ settings = NSDictionary.FromObjectsAndKeys (values, keys);
+
+ //Set recorder parameters
+ NSError error;
+ recorder = AVAudioRecorder.ToUrl(this.audioFilePath, settings, out error);
+ if (recorder == null){
+ Console.WriteLine (error);
+ return;
+ }
+
+ //Set Recorder to Prepare To Record
+ recorder.PrepareToRecord();
+
+ }
+ }
+}
+
View
57 Sound/Sound/SoundViewController.designer.cs
@@ -0,0 +1,57 @@
+// WARNING
+//
+// This file has been generated automatically by MonoDevelop to store outlets and
+// actions made in the Xcode designer. If it is removed, they will be lost.
+// Manual changes to this file may not be handled correctly.
+//
+using MonoTouch.Foundation;
+
+namespace Sound
+{
+ [Register ("SoundViewController")]
+ partial class SoundViewController
+ {
+ [Outlet]
+ MonoTouch.UIKit.UIButton StartRecordingButton { get; set; }
+
+ [Outlet]
+ MonoTouch.UIKit.UIButton StopRecordingButton { get; set; }
+
+ [Outlet]
+ MonoTouch.UIKit.UIButton PlayRecordedSoundButton { get; set; }
+
+ [Outlet]
+ MonoTouch.UIKit.UILabel RecordingStatusLabel { get; set; }
+
+ [Outlet]
+ MonoTouch.UIKit.UILabel LengthOfRecordingLabel { get; set; }
+
+ void ReleaseDesignerOutlets ()
+ {
+ if (StartRecordingButton != null) {
+ StartRecordingButton.Dispose ();
+ StartRecordingButton = null;
+ }
+
+ if (StopRecordingButton != null) {
+ StopRecordingButton.Dispose ();
+ StopRecordingButton = null;
+ }
+
+ if (PlayRecordedSoundButton != null) {
+ PlayRecordedSoundButton.Dispose ();
+ PlayRecordedSoundButton = null;
+ }
+
+ if (RecordingStatusLabel != null) {
+ RecordingStatusLabel.Dispose ();
+ RecordingStatusLabel = null;
+ }
+
+ if (LengthOfRecordingLabel != null) {
+ LengthOfRecordingLabel.Dispose ();
+ LengthOfRecordingLabel = null;
+ }
+ }
+ }
+}
View
397 Sound/Sound/SoundViewController_iPad.xib
@@ -0,0 +1,397 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<archive type="com.apple.InterfaceBuilder3.CocoaTouch.iPad.XIB" version="8.00">
+ <data>
+ <int key="IBDocument.SystemTarget">1280</int>
+ <string key="IBDocument.SystemVersion">11C74</string>
+ <string key="IBDocument.InterfaceBuilderVersion">1938</string>
+ <string key="IBDocument.AppKitVersion">1138.23</string>
+ <string key="IBDocument.HIToolboxVersion">567.00</string>
+ <object class="NSMutableDictionary" key="IBDocument.PluginVersions">
+ <string key="NS.key.0">com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string>
+ <string key="NS.object.0">933</string>
+ </object>
+ <array key="IBDocument.IntegratedClassDependencies">
+ <string>IBUIButton</string>
+ <string>IBUIView</string>
+ <string>IBUILabel</string>
+ <string>IBProxyObject</string>
+ </array>
+ <array key="IBDocument.PluginDependencies">
+ <string>com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string>
+ </array>
+ <object class="NSMutableDictionary" key="IBDocument.Metadata">
+ <string key="NS.key.0">PluginDependencyRecalculationVersion</string>
+ <integer value="1" key="NS.object.0"/>
+ </object>
+ <array class="NSMutableArray" key="IBDocument.RootObjects" id="1000">
+ <object class="IBProxyObject" id="841351856">
+ <string key="IBProxiedObjectIdentifier">IBFilesOwner</string>
+ <string key="targetRuntimeIdentifier">IBIPadFramework</string>
+ </object>
+ <object class="IBProxyObject" id="606714003">
+ <string key="IBProxiedObjectIdentifier">IBFirstResponder</string>
+ <string key="targetRuntimeIdentifier">IBIPadFramework</string>
+ </object>
+ <object class="IBUIView" id="766721923">
+ <reference key="NSNextResponder"/>
+ <int key="NSvFlags">274</int>
+ <array class="NSMutableArray" key="NSSubviews">
+ <object class="IBUIButton" id="162782301">
+ <reference key="NSNextResponder" ref="766721923"/>
+ <int key="NSvFlags">292</int>
+ <string key="NSFrame">{{20, 65}, {138, 37}}</string>
+ <reference key="NSSuperview" ref="766721923"/>
+ <reference key="NSWindow"/>
+ <string key="NSReuseIdentifierKey">_NS:241</string>
+ <bool key="IBUIOpaque">NO</bool>
+ <string key="targetRuntimeIdentifier">IBIPadFramework</string>
+ <int key="IBUIContentHorizontalAlignment">0</int>
+ <int key="IBUIContentVerticalAlignment">0</int>
+ <int key="IBUIButtonType">1</int>
+ <string key="IBUINormalTitle">Start Recording</string>
+ <object class="NSColor" key="IBUIHighlightedTitleColor" id="757995457">
+ <int key="NSColorSpace">3</int>
+ <bytes key="NSWhite">MQA</bytes>
+ </object>
+ <object class="NSColor" key="IBUINormalTitleColor">
+ <int key="NSColorSpace">1</int>
+ <bytes key="NSRGB">MC4xOTYwNzg0MzQ2IDAuMzA5ODAzOTMyOSAwLjUyMTU2ODY1NgA</bytes>
+ </object>
+ <object class="NSColor" key="IBUINormalTitleShadowColor" id="1043672624">
+ <int key="NSColorSpace">3</int>
+ <bytes key="NSWhite">MC41AA</bytes>
+ </object>
+ <object class="IBUIFontDescription" key="IBUIFontDescription" id="1069305593">
+ <int key="type">2</int>
+ <double key="pointSize">15</double>
+ </object>
+ <object class="NSFont" key="IBUIFont" id="200537518">
+ <string key="NSName">Helvetica-Bold</string>
+ <double key="NSSize">15</double>
+ <int key="NSfFlags">16</int>
+ </object>
+ </object>
+ <object class="IBUIButton" id="844452562">
+ <reference key="NSNextResponder" ref="766721923"/>
+ <int key="NSvFlags">292</int>
+ <string key="NSFrame">{{20, 110}, {138, 37}}</string>
+ <reference key="NSSuperview" ref="766721923"/>
+ <reference key="NSWindow"/>
+ <string key="NSReuseIdentifierKey">_NS:241</string>
+ <bool key="IBUIOpaque">NO</bool>
+ <string key="targetRuntimeIdentifier">IBIPadFramework</string>
+ <bool key="IBUIEnabled">NO</bool>
+ <int key="IBUIContentHorizontalAlignment">0</int>
+ <int key="IBUIContentVerticalAlignment">0</int>
+ <int key="IBUIButtonType">1</int>
+ <string key="IBUINormalTitle">Stop Recording</string>
+ <reference key="IBUIHighlightedTitleColor" ref="757995457"/>
+ <object class="NSColor" key="IBUINormalTitleColor">
+ <int key="NSColorSpace">1</int>
+ <bytes key="NSRGB">MC4xOTYwNzg0MzQ2IDAuMzA5ODAzOTMyOSAwLjUyMTU2ODY1NgA</bytes>
+ </object>
+ <reference key="IBUINormalTitleShadowColor" ref="1043672624"/>
+ <reference key="IBUIFontDescription" ref="1069305593"/>
+ <reference key="IBUIFont" ref="200537518"/>
+ </object>
+ <object class="IBUIButton" id="365991205">
+ <reference key="NSNextResponder" ref="766721923"/>
+ <int key="NSvFlags">292</int>
+ <string key="NSFrame">{{20, 211}, {180, 37}}</string>
+ <reference key="NSSuperview" ref="766721923"/>
+ <reference key="NSWindow"/>
+ <string key="NSReuseIdentifierKey">_NS:241</string>
+ <bool key="IBUIOpaque">NO</bool>
+ <string key="targetRuntimeIdentifier">IBIPadFramework</string>
+ <bool key="IBUIEnabled">NO</bool>
+ <int key="IBUIContentHorizontalAlignment">0</int>
+ <int key="IBUIContentVerticalAlignment">0</int>
+ <int key="IBUIButtonType">1</int>
+ <string key="IBUINormalTitle">Play Recorded Sound</string>
+ <reference key="IBUIHighlightedTitleColor" ref="757995457"/>
+ <object class="NSColor" key="IBUINormalTitleColor">
+ <int key="NSColorSpace">1</int>
+ <bytes key="NSRGB">MC4xOTYwNzg0MzQ2IDAuMzA5ODAzOTMyOSAwLjUyMTU2ODY1NgA</bytes>
+ </object>
+ <reference key="IBUINormalTitleShadowColor" ref="1043672624"/>
+ <reference key="IBUIFontDescription" ref="1069305593"/>
+ <reference key="IBUIFont" ref="200537518"/>
+ </object>
+ <object class="IBUILabel" id="476028786">
+ <reference key="NSNextResponder" ref="766721923"/>
+ <int key="NSvFlags">292</int>
+ <string key="NSFrame">{{20, 20}, {728, 37}}</string>
+ <reference key="NSSuperview" ref="766721923"/>
+ <reference key="NSWindow"/>
+ <string key="NSReuseIdentifierKey">_NS:345</string>
+ <bool key="IBUIOpaque">NO</bool>
+ <bool key="IBUIClipsSubviews">YES</bool>
+ <int key="IBUIContentMode">7</int>
+ <bool key="IBUIUserInteractionEnabled">NO</bool>
+ <string key="targetRuntimeIdentifier">IBIPadFramework</string>
+ <string key="IBUIText">Recording and Playing Sound</string>
+ <object class="NSColor" key="IBUITextColor" id="496699527">
+ <int key="NSColorSpace">1</int>
+ <bytes key="NSRGB">MCAwIDAAA</bytes>
+ </object>
+ <nil key="IBUIHighlightedColor"/>
+ <int key="IBUIBaselineAdjustment">1</int>
+ <float key="IBUIMinimumFontSize">10</float>
+ <int key="IBUITextAlignment">1</int>
+ <object class="IBUIFontDescription" key="IBUIFontDescription">
+ <int key="type">1</int>
+ <double key="pointSize">29</double>
+ </object>
+ <object class="NSFont" key="IBUIFont">
+ <string key="NSName">Helvetica</string>
+ <double key="NSSize">29</double>
+ <int key="NSfFlags">16</int>
+ </object>
+ </object>
+ <object class="IBUILabel" id="791953716">
+ <reference key="NSNextResponder" ref="766721923"/>
+ <int key="NSvFlags">292</int>
+ <string key="NSFrame">{{166, 72}, {226, 21}}</string>
+ <reference key="NSSuperview" ref="766721923"/>
+ <reference key="NSWindow"/>
+ <string key="NSReuseIdentifierKey">_NS:345</string>
+ <bool key="IBUIOpaque">NO</bool>
+ <bool key="IBUIClipsSubviews">YES</bool>
+ <int key="IBUIContentMode">7</int>
+ <bool key="IBUIUserInteractionEnabled">NO</bool>
+ <string key="targetRuntimeIdentifier">IBIPadFramework</string>
+ <string key="IBUIText">[status]</string>
+ <reference key="IBUITextColor" ref="496699527"/>
+ <nil key="IBUIHighlightedColor"/>
+ <int key="IBUIBaselineAdjustment">1</int>
+ <float key="IBUIMinimumFontSize">10</float>
+ <object class="IBUIFontDescription" key="IBUIFontDescription" id="151985453">
+ <int key="type">1</int>
+ <double key="pointSize">17</double>
+ </object>
+ <object class="NSFont" key="IBUIFont" id="1042979833">
+ <string key="NSName">Helvetica</string>
+ <double key="NSSize">17</double>
+ <int key="NSfFlags">16</int>
+ </object>
+ </object>
+ <object class="IBUILabel" id="974731178">
+ <reference key="NSNextResponder" ref="766721923"/>
+ <int key="NSvFlags">292</int>
+ <string key="NSFrame">{{166, 117}, {226, 21}}</string>
+ <reference key="NSSuperview" ref="766721923"/>
+ <reference key="NSWindow"/>
+ <string key="NSReuseIdentifierKey">_NS:345</string>
+ <bool key="IBUIOpaque">NO</bool>
+ <bool key="IBUIClipsSubviews">YES</bool>
+ <int key="IBUIContentMode">7</int>
+ <bool key="IBUIUserInteractionEnabled">NO</bool>
+ <string key="targetRuntimeIdentifier">IBIPadFramework</string>
+ <string key="IBUIText">[length of recording]</string>
+ <reference key="IBUITextColor" ref="496699527"/>
+ <nil key="IBUIHighlightedColor"/>
+ <int key="IBUIBaselineAdjustment">1</int>
+ <float key="IBUIMinimumFontSize">10</float>
+ <reference key="IBUIFontDescription" ref="151985453"/>
+ <reference key="IBUIFont" ref="1042979833"/>
+ </object>
+ </array>
+ <string key="NSFrame">{{0, 20}, {768, 1004}}</string>
+ <reference key="NSSuperview"/>
+ <reference key="NSWindow"/>
+ <reference key="NSNextKeyView"/>
+ <object class="NSColor" key="IBUIBackgroundColor">
+ <int key="NSColorSpace">3</int>
+ <bytes key="NSWhite">MQA</bytes>
+ <object class="NSColorSpace" key="NSCustomColorSpace">
+ <int key="NSID">2</int>
+ </object>
+ </object>
+ <object class="IBUISimulatedStatusBarMetrics" key="IBUISimulatedStatusBarMetrics">
+ <int key="IBUIStatusBarStyle">2</int>
+ </object>
+ <string key="targetRuntimeIdentifier">IBIPadFramework</string>
+ </object>
+ </array>
+ <object class="IBObjectContainer" key="IBDocument.Objects">
+ <array class="NSMutableArray" key="connectionRecords">
+ <object class="IBConnectionRecord">
+ <object class="IBCocoaTouchOutletConnection" key="connection">
+ <string key="label">view</string>
+ <reference key="source" ref="841351856"/>
+ <reference key="destination" ref="766721923"/>
+ </object>
+ <int key="connectionID">3</int>
+ </object>
+ <object class="IBConnectionRecord">
+ <object class="IBCocoaTouchOutletConnection" key="connection">
+ <string key="label">StartRecordingButton</string>
+ <reference key="source" ref="841351856"/>
+ <reference key="destination" ref="162782301"/>
+ </object>
+ <int key="connectionID">11</int>
+ </object>
+ <object class="IBConnectionRecord">
+ <object class="IBCocoaTouchOutletConnection" key="connection">
+ <string key="label">StopRecordingButton</string>
+ <reference key="source" ref="841351856"/>
+ <reference key="destination" ref="844452562"/>
+ </object>
+ <int key="connectionID">12</int>
+ </object>
+ <object class="IBConnectionRecord">
+ <object class="IBCocoaTouchOutletConnection" key="connection">
+ <string key="label">PlayRecordedSoundButton</string>
+ <reference key="source" ref="841351856"/>
+ <reference key="destination" ref="365991205"/>
+ </object>
+ <int key="connectionID">13</int>
+ </object>
+ <object class="IBConnectionRecord">
+ <object class="IBCocoaTouchOutletConnection" key="connection">
+ <string key="label">RecordingStatusLabel</string>
+ <reference key="source" ref="841351856"/>
+ <reference key="destination" ref="791953716"/>
+ </object>
+ <int key="connectionID">14</int>
+ </object>
+ <object class="IBConnectionRecord">
+ <object class="IBCocoaTouchOutletConnection" key="connection">
+ <string key="label">LengthOfRecordingLabel</string>
+ <reference key="source" ref="841351856"/>
+ <reference key="destination" ref="974731178"/>
+ </object>
+ <int key="connectionID">15</int>
+ </object>
+ </array>
+ <object class="IBMutableOrderedSet" key="objectRecords">
+ <array key="orderedObjects">
+ <object class="IBObjectRecord">
+ <int key="objectID">0</int>
+ <array key="object" id="0"/>
+ <reference key="children" ref="1000"/>
+ <nil key="parent"/>
+ </object>
+ <object class="IBObjectRecord">
+ <int key="objectID">-1</int>
+ <reference key="object" ref="841351856"/>
+ <reference key="parent" ref="0"/>
+ <string key="objectName">File's Owner</string>
+ </object>
+ <object class="IBObjectRecord">
+ <int key="objectID">-2</int>
+ <reference key="object" ref="606714003"/>
+ <reference key="parent" ref="0"/>
+ </object>
+ <object class="IBObjectRecord">
+ <int key="objectID">2</int>
+ <reference key="object" ref="766721923"/>
+ <array class="NSMutableArray" key="children">
+ <reference ref="476028786"/>
+ <reference ref="162782301"/>
+ <reference ref="844452562"/>
+ <reference ref="791953716"/>
+ <reference ref="974731178"/>
+ <reference ref="365991205"/>
+ </array>
+ <reference key="parent" ref="0"/>
+ </object>
+ <object class="IBObjectRecord">
+ <int key="objectID">4</int>
+ <reference key="object" ref="162782301"/>
+ <reference key="parent" ref="766721923"/>
+ </object>
+ <object class="IBObjectRecord">
+ <int key="objectID">5</int>
+ <reference key="object" ref="476028786"/>
+ <reference key="parent" ref="766721923"/>
+ </object>
+ <object class="IBObjectRecord">
+ <int key="objectID">6</int>
+ <reference key="object" ref="844452562"/>
+ <reference key="parent" ref="766721923"/>
+ </object>
+ <object class="IBObjectRecord">
+ <int key="objectID">8</int>
+ <reference key="object" ref="791953716"/>
+ <reference key="parent" ref="766721923"/>
+ </object>
+ <object class="IBObjectRecord">
+ <int key="objectID">9</int>
+ <reference key="object" ref="974731178"/>
+ <reference key="parent" ref="766721923"/>
+ </object>
+ <object class="IBObjectRecord">
+ <int key="objectID">10</int>
+ <reference key="object" ref="365991205"/>
+ <reference key="parent" ref="766721923"/>
+ </object>
+ </array>
+ </object>
+ <dictionary class="NSMutableDictionary" key="flattenedProperties">
+ <string key="-1.CustomClassName">SoundViewController</string>
+ <string key="-1.IBPluginDependency">com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string>
+ <string key="-2.CustomClassName">UIResponder</string>
+ <string key="-2.IBPluginDependency">com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string>
+ <string key="10.IBPluginDependency">com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string>
+ <string key="2.IBPluginDependency">com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string>
+ <string key="4.IBPluginDependency">com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string>
+ <string key="5.IBPluginDependency">com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string>
+ <string key="6.IBPluginDependency">com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string>
+ <string key="8.IBPluginDependency">com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string>
+ <string key="9.IBPluginDependency">com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string>
+ </dictionary>
+ <dictionary class="NSMutableDictionary" key="unlocalizedProperties"/>
+ <nil key="activeLocalization"/>
+ <dictionary class="NSMutableDictionary" key="localizations"/>
+ <nil key="sourceID"/>
+ <int key="maxID">15</int>
+ </object>
+ <object class="IBClassDescriber" key="IBDocument.Classes">
+ <array class="NSMutableArray" key="referencedPartialClassDescriptions">
+ <object class="IBPartialClassDescription">
+ <string key="className">SoundViewController</string>
+ <string key="superclassName">UIViewController</string>
+ <dictionary class="NSMutableDictionary" key="outlets">
+ <string key="LengthOfRecordingLabel">UILabel</string>
+ <string key="PlayRecordedSoundButton">UIButton</string>
+ <string key="RecordingStatusLabel">UILabel</string>
+ <string key="StartRecordingButton">UIButton</string>
+ <string key="StopRecordingButton">UIButton</string>
+ </dictionary>
+ <dictionary class="NSMutableDictionary" key="toOneOutletInfosByName">
+ <object class="IBToOneOutletInfo" key="LengthOfRecordingLabel">
+ <string key="name">LengthOfRecordingLabel</string>
+ <string key="candidateClassName">UILabel</string>
+ </object>
+ <object class="IBToOneOutletInfo" key="PlayRecordedSoundButton">
+ <string key="name">PlayRecordedSoundButton</string>
+ <string key="candidateClassName">UIButton</string>
+ </object>
+ <object class="IBToOneOutletInfo" key="RecordingStatusLabel">
+ <string key="name">RecordingStatusLabel</string>
+ <string key="candidateClassName">UILabel</string>
+ </object>
+ <object class="IBToOneOutletInfo" key="StartRecordingButton">
+ <string key="name">StartRecordingButton</string>
+ <string key="candidateClassName">UIButton</string>
+ </object>
+ <object class="IBToOneOutletInfo" key="StopRecordingButton">
+ <string key="name">StopRecordingButton</string>
+ <string key="candidateClassName">UIButton</string>
+ </object>
+ </dictionary>
+ <object class="IBClassDescriptionSource" key="sourceIdentifier">
+ <string key="majorKey">IBProjectSource</string>
+ <string key="minorKey">./Classes/SoundViewController.h</string>
+ </object>
+ </object>
+ </array>
+ </object>
+ <int key="IBDocument.localizationMode">0</int>
+ <string key="IBDocument.TargetRuntimeIdentifier">IBIPadFramework</string>
+ <bool key="IBDocument.PluginDeclaredDependenciesTrackSystemTargetVersion">YES</bool>
+ <int key="IBDocument.defaultPropertyAccessControl">3</int>
+ <string key="IBCocoaTouchPluginVersion">933</string>
+ </data>
+</archive>
View
399 Sound/Sound/SoundViewController_iPhone.xib
@@ -0,0 +1,399 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<archive type="com.apple.InterfaceBuilder3.CocoaTouch.XIB" version="8.00">
+ <data>
+ <int key="IBDocument.SystemTarget">1280</int>
+ <string key="IBDocument.SystemVersion">11C74</string>
+ <string key="IBDocument.InterfaceBuilderVersion">1938</string>
+ <string key="IBDocument.AppKitVersion">1138.23</string>
+ <string key="IBDocument.HIToolboxVersion">567.00</string>
+ <object class="NSMutableDictionary" key="IBDocument.PluginVersions">
+ <string key="NS.key.0">com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string>
+ <string key="NS.object.0">933</string>
+ </object>
+ <array key="IBDocument.IntegratedClassDependencies">
+ <string>IBUIButton</string>
+ <string>IBUIView</string>
+ <string>IBUILabel</string>
+ <string>IBProxyObject</string>
+ </array>
+ <array key="IBDocument.PluginDependencies">
+ <string>com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string>
+ </array>
+ <object class="NSMutableDictionary" key="IBDocument.Metadata">
+ <string key="NS.key.0">PluginDependencyRecalculationVersion</string>
+ <integer value="1" key="NS.object.0"/>
+ </object>
+ <array class="NSMutableArray" key="IBDocument.RootObjects" id="1000">
+ <object class="IBProxyObject" id="372490531">
+ <string key="IBProxiedObjectIdentifier">IBFilesOwner</string>
+ <string key="targetRuntimeIdentifier">IBCocoaTouchFramework</string>
+ </object>
+ <object class="IBProxyObject" id="843779117">
+ <string key="IBProxiedObjectIdentifier">IBFirstResponder</string>
+ <string key="targetRuntimeIdentifier">IBCocoaTouchFramework</string>
+ </object>
+ <object class="IBUIView" id="774585933">
+ <reference key="NSNextResponder"/>
+ <int key="NSvFlags">274</int>
+ <array class="NSMutableArray" key="NSSubviews">
+ <object class="IBUIButton" id="306469809">
+ <reference key="NSNextResponder" ref="774585933"/>
+ <int key="NSvFlags">292</int>
+ <string key="NSFrame">{{20, 65}, {138, 37}}</string>
+ <reference key="NSSuperview" ref="774585933"/>
+ <reference key="NSWindow"/>
+ <reference key="NSNextKeyView" ref="570163933"/>
+ <string key="NSReuseIdentifierKey">_NS:241</string>
+ <bool key="IBUIOpaque">NO</bool>
+ <string key="targetRuntimeIdentifier">IBCocoaTouchFramework</string>
+ <int key="IBUIContentHorizontalAlignment">0</int>
+ <int key="IBUIContentVerticalAlignment">0</int>
+ <int key="IBUIButtonType">1</int>
+ <string key="IBUINormalTitle">Start Recording</string>
+ <object class="NSColor" key="IBUIHighlightedTitleColor" id="630288911">
+ <int key="NSColorSpace">3</int>
+ <bytes key="NSWhite">MQA</bytes>
+ </object>
+ <object class="NSColor" key="IBUINormalTitleColor">
+ <int key="NSColorSpace">1</int>
+ <bytes key="NSRGB">MC4xOTYwNzg0MzQ2IDAuMzA5ODAzOTMyOSAwLjUyMTU2ODY1NgA</bytes>
+ </object>
+ <object class="NSColor" key="IBUINormalTitleShadowColor" id="683155734">
+ <int key="NSColorSpace">3</int>
+ <bytes key="NSWhite">MC41AA</bytes>
+ </object>
+ <object class="IBUIFontDescription" key="IBUIFontDescription" id="206696436">
+ <int key="type">2</int>
+ <double key="pointSize">15</double>
+ </object>
+ <object class="NSFont" key="IBUIFont" id="436047561">
+ <string key="NSName">Helvetica-Bold</string>
+ <double key="NSSize">15</double>
+ <int key="NSfFlags">16</int>
+ </object>
+ </object>
+ <object class="IBUIButton" id="809481525">
+ <reference key="NSNextResponder" ref="774585933"/>
+ <int key="NSvFlags">292</int>
+ <string key="NSFrame">{{20, 110}, {138, 37}}</string>
+ <reference key="NSSuperview" ref="774585933"/>
+ <reference key="NSWindow"/>
+ <reference key="NSNextKeyView" ref="65969832"/>
+ <string key="NSReuseIdentifierKey">_NS:241</string>
+ <bool key="IBUIOpaque">NO</bool>
+ <string key="targetRuntimeIdentifier">IBCocoaTouchFramework</string>
+ <bool key="IBUIEnabled">NO</bool>
+ <int key="IBUIContentHorizontalAlignment">0</int>
+ <int key="IBUIContentVerticalAlignment">0</int>
+ <int key="IBUIButtonType">1</int>
+ <string key="IBUINormalTitle">Stop Recording</string>
+ <reference key="IBUIHighlightedTitleColor" ref="630288911"/>
+ <object class="NSColor" key="IBUINormalTitleColor">
+ <int key="NSColorSpace">1</int>
+ <bytes key="NSRGB">MC4xOTYwNzg0MzQ2IDAuMzA5ODAzOTMyOSAwLjUyMTU2ODY1NgA</bytes>
+ </object>
+ <reference key="IBUINormalTitleShadowColor" ref="683155734"/>
+ <reference key="IBUIFontDescription" ref="206696436"/>
+ <reference key="IBUIFont" ref="436047561"/>
+ </object>
+ <object class="IBUIButton" id="606986209">
+ <reference key="NSNextResponder" ref="774585933"/>
+ <int key="NSvFlags">292</int>
+ <string key="NSFrame">{{20, 186}, {180, 37}}</string>
+ <reference key="NSSuperview" ref="774585933"/>
+ <reference key="NSWindow"/>
+ <reference key="NSNextKeyView"/>
+ <string key="NSReuseIdentifierKey">_NS:241</string>
+ <bool key="IBUIOpaque">NO</bool>
+ <string key="targetRuntimeIdentifier">IBCocoaTouchFramework</string>
+ <bool key="IBUIEnabled">NO</bool>
+ <int key="IBUIContentHorizontalAlignment">0</int>
+ <int key="IBUIContentVerticalAlignment">0</int>
+ <int key="IBUIButtonType">1</int>
+ <string key="IBUINormalTitle">Play Recorded Sound</string>
+ <reference key="IBUIHighlightedTitleColor" ref="630288911"/>
+ <object class="NSColor" key="IBUINormalTitleColor">
+ <int key="NSColorSpace">1</int>
+ <bytes key="NSRGB">MC4xOTYwNzg0MzQ2IDAuMzA5ODAzOTMyOSAwLjUyMTU2ODY1NgA</bytes>
+ </object>
+ <reference key="IBUINormalTitleShadowColor" ref="683155734"/>
+ <reference key="IBUIFontDescription" ref="206696436"/>
+ <reference key="IBUIFont" ref="436047561"/>
+ </object>
+ <object class="IBUILabel" id="947365637">
+ <reference key="NSNextResponder" ref="774585933"/>
+ <int key="NSvFlags">290</int>
+ <string key="NSFrame">{{20, 20}, {285, 37}}</string>
+ <reference key="NSSuperview" ref="774585933"/>
+ <reference key="NSWindow"/>
+ <reference key="NSNextKeyView" ref="306469809"/>
+ <string key="NSReuseIdentifierKey">_NS:345</string>
+ <bool key="IBUIOpaque">NO</bool>
+ <bool key="IBUIClipsSubviews">YES</bool>
+ <int key="IBUIContentMode">7</int>
+ <bool key="IBUIUserInteractionEnabled">NO</bool>
+ <string key="targetRuntimeIdentifier">IBCocoaTouchFramework</string>
+ <string key="IBUIText">Recording and Playing Sound</string>
+ <object class="NSColor" key="IBUITextColor" id="725235514">
+ <int key="NSColorSpace">1</int>
+ <bytes key="NSRGB">MCAwIDAAA</bytes>
+ </object>
+ <nil key="IBUIHighlightedColor"/>
+ <int key="IBUIBaselineAdjustment">1</int>
+ <float key="IBUIMinimumFontSize">10</float>
+ <int key="IBUITextAlignment">1</int>
+ <object class="IBUIFontDescription" key="IBUIFontDescription">
+ <int key="type">1</int>
+ <double key="pointSize">29</double>
+ </object>
+ <object class="NSFont" key="IBUIFont">
+ <string key="NSName">Helvetica</string>
+ <double key="NSSize">29</double>
+ <int key="NSfFlags">16</int>
+ </object>
+ </object>
+ <object class="IBUILabel" id="570163933">
+ <reference key="NSNextResponder" ref="774585933"/>
+ <int key="NSvFlags">292</int>
+ <string key="NSFrame">{{166, 72}, {139, 21}}</string>
+ <reference key="NSSuperview" ref="774585933"/>
+ <reference key="NSWindow"/>
+ <reference key="NSNextKeyView" ref="809481525"/>
+ <string key="NSReuseIdentifierKey">_NS:345</string>
+ <bool key="IBUIOpaque">NO</bool>
+ <bool key="IBUIClipsSubviews">YES</bool>
+ <int key="IBUIContentMode">7</int>
+ <bool key="IBUIUserInteractionEnabled">NO</bool>
+ <string key="targetRuntimeIdentifier">IBCocoaTouchFramework</string>
+ <string key="IBUIText">[status]</string>
+ <reference key="IBUITextColor" ref="725235514"/>
+ <nil key="IBUIHighlightedColor"/>
+ <int key="IBUIBaselineAdjustment">1</int>
+ <float key="IBUIMinimumFontSize">10</float>
+ <object class="IBUIFontDescription" key="IBUIFontDescription" id="452993698">
+ <int key="type">1</int>
+ <double key="pointSize">17</double>
+ </object>
+ <object class="NSFont" key="IBUIFont" id="1066788558">
+ <string key="NSName">Helvetica</string>
+ <double key="NSSize">17</double>
+ <int key="NSfFlags">16</int>
+ </object>
+ </object>
+ <object class="IBUILabel" id="65969832">
+ <reference key="NSNextResponder" ref="774585933"/>
+ <int key="NSvFlags">292</int>
+ <string key="NSFrame">{{166, 117}, {139, 21}}</string>
+ <reference key="NSSuperview" ref="774585933"/>
+ <reference key="NSWindow"/>
+ <reference key="NSNextKeyView" ref="606986209"/>
+ <string key="NSReuseIdentifierKey">_NS:345</string>
+ <bool key="IBUIOpaque">NO</bool>
+ <bool key="IBUIClipsSubviews">YES</bool>
+ <int key="IBUIContentMode">7</int>
+ <bool key="IBUIUserInteractionEnabled">NO</bool>
+ <string key="targetRuntimeIdentifier">IBCocoaTouchFramework</string>
+ <string key="IBUIText">[length of recording]</string>
+ <reference key="IBUITextColor" ref="725235514"/>
+ <nil key="IBUIHighlightedColor"/>
+ <int key="IBUIBaselineAdjustment">1</int>
+ <float key="IBUIMinimumFontSize">10</float>
+ <reference key="IBUIFontDescription" ref="452993698"/>
+ <reference key="IBUIFont" ref="1066788558"/>
+ </object>
+ </array>
+ <string key="NSFrame">{{0, 20}, {320, 460}}</string>
+ <reference key="NSSuperview"/>
+ <reference key="NSWindow"/>
+ <reference key="NSNextKeyView" ref="947365637"/>
+ <object class="NSColor" key="IBUIBackgroundColor">
+ <int key="NSColorSpace">1</int>
+ <bytes key="NSRGB">MSAxIDEAA</bytes>
+ </object>
+ <bool key="IBUIClearsContextBeforeDrawing">NO</bool>
+ <object class="IBUISimulatedStatusBarMetrics" key="IBUISimulatedStatusBarMetrics"/>
+ <string key="targetRuntimeIdentifier">IBCocoaTouchFramework</string>
+ </object>
+ </array>
+ <object class="IBObjectContainer" key="IBDocument.Objects">
+ <array class="NSMutableArray" key="connectionRecords">
+ <object class="IBConnectionRecord">
+ <object class="IBCocoaTouchOutletConnection" key="connection">
+ <string key="label">view</string>
+ <reference key="source" ref="372490531"/>
+ <reference key="destination" ref="774585933"/>
+ </object>
+ <int key="connectionID">7</int>
+ </object>
+ <object class="IBConnectionRecord">