diff options
author | Michael Hutchinson <mhutchinson@novell.com> | 2010-01-26 06:01:01 +0300 |
---|---|---|
committer | Michael Hutchinson <mhutchinson@novell.com> | 2010-01-26 06:01:01 +0300 |
commit | c9e1079f39074c5f75ac4c81a7ade4721701485b (patch) | |
tree | fb397048347d6dae1e896472a7b3a4372bd4e30a | |
parent | d494a3bd74313715e629cac4bd0cc6e7e2681d91 (diff) | |
parent | 4dae9e04a95dd9fa029be6957540a9f0d3cd6856 (diff) |
Backport:
149597 - Fix displaying I18N options
149700 - Make main nib picker editable so it can be cleared
150079 - Add MonoDoc source for MonoTouch docs
150159 - Added more project templates
svn path=/branches/monodevelop/extras/MonoDevelop.IPhone/2.2/; revision=150188
12 files changed, 2286 insertions, 18 deletions
diff --git a/extras/MonoDevelop.IPhone/MonoDevelop.IPhone/ChangeLog b/extras/MonoDevelop.IPhone/MonoDevelop.IPhone/ChangeLog index 5edd1696e7..5e749a2096 100644 --- a/extras/MonoDevelop.IPhone/MonoDevelop.IPhone/ChangeLog +++ b/extras/MonoDevelop.IPhone/MonoDevelop.IPhone/ChangeLog @@ -1,3 +1,35 @@ +2010-01-25 Michael Hutchinson <mhutchinson@novell.com> + + * MonoDevelop.IPhone.csproj: + * MonoDevelop.IPhone.addin.xml: + * Templates/IPhoneProject.xpt.xml: + * Templates/IPhoneOpenGLProject.xpt.xml: + * Templates/IPhoneUtilityProject.xpt.xml: + * Templates/IPhoneNavBasedProject.xpt.xml: Added 3 new project + templates. + + * Templates/IPhoneViewXib.xft.xml: + * Templates/IPhoneApplicationXib.xft.xml: + * Templates/IPhoneViewController.xft.xml: Small tweaks. + + * Templates/IPhoneWindowBasedProject.xpt.xml: Renamed the + default project template to match Xcode. + +2010-01-22 Michael Hutchinson <mhutchinson@novell.com> + + * MonoDevelop.IPhone.addin.xml: Add a MonoDoc source for the + MonoTouch docs, so that MD can load them even after the Mono + framework directory is upgraded. + +2010-01-16 Michael Hutchinson <mhutchinson@novell.com> + + * Gui/IPhoneOptionsPanel.cs: Make the main nib picker entry + editable so that it can be cleared. + +2010-01-14 Michael Hutchinson <mhutchinson@novell.com> + + * Gui/IPhoneBuildOptionsPanel.cs: Fix displaying i18n options. + 2010-01-13 Michael Hutchinson <mhutchinson@novell.com> * IPhoneBuildExtension.cs: Treat empty identity as "developer diff --git a/extras/MonoDevelop.IPhone/MonoDevelop.IPhone/Gui/IPhoneBuildOptionsPanel.cs b/extras/MonoDevelop.IPhone/MonoDevelop.IPhone/Gui/IPhoneBuildOptionsPanel.cs index db12fc51c3..cccc44d5ef 100644 --- a/extras/MonoDevelop.IPhone/MonoDevelop.IPhone/Gui/IPhoneBuildOptionsPanel.cs +++ b/extras/MonoDevelop.IPhone/MonoDevelop.IPhone/Gui/IPhoneBuildOptionsPanel.cs @@ -128,13 +128,14 @@ namespace MonoDevelop.IPhone.Gui void LoadI18nValues (string values) { store.Clear (); - - if (values == null) - return; - var arr = values.Split (','); - - foreach (string s in i18n) - store.AppendValues (s, arr.Contains (s)); + if (values == null) { + foreach (string s in i18n) + store.AppendValues (s, false); + } else { + var arr = values.Split (','); + foreach (string s in i18n) + store.AppendValues (s, arr.Contains (s)); + } } string GetI18nValues () diff --git a/extras/MonoDevelop.IPhone/MonoDevelop.IPhone/Gui/IPhoneOptionsPanel.cs b/extras/MonoDevelop.IPhone/MonoDevelop.IPhone/Gui/IPhoneOptionsPanel.cs index d1a768fec2..70a3b7c027 100644 --- a/extras/MonoDevelop.IPhone/MonoDevelop.IPhone/Gui/IPhoneOptionsPanel.cs +++ b/extras/MonoDevelop.IPhone/MonoDevelop.IPhone/Gui/IPhoneOptionsPanel.cs @@ -72,6 +72,7 @@ namespace MonoDevelop.IPhone.Gui displayNameEntry.Text = proj.BundleDisplayName ?? ""; mainNibPicker.Project = proj; + mainNibPicker.EntryIsEditable = true; mainNibPicker.DefaultFilter = "*.xib"; mainNibPicker.DialogTitle = GettextCatalog.GetString ("Select main interface file..."); mainNibPicker.SelectedFile = proj.MainNibFile.ToString () ?? ""; diff --git a/extras/MonoDevelop.IPhone/MonoDevelop.IPhone/MonoDevelop.IPhone.addin.xml b/extras/MonoDevelop.IPhone/MonoDevelop.IPhone/MonoDevelop.IPhone.addin.xml index ba64e31c39..9a8f72328f 100644 --- a/extras/MonoDevelop.IPhone/MonoDevelop.IPhone/MonoDevelop.IPhone.addin.xml +++ b/extras/MonoDevelop.IPhone/MonoDevelop.IPhone/MonoDevelop.IPhone.addin.xml @@ -40,8 +40,14 @@ <Extension path = "/MonoDevelop/Ide/ProjectTemplates"> <Condition id="MonoTouchInstalled"> - <ProjectTemplate id = "IPhoneProject" - resource = "IPhoneProject.xpt.xml" /> + <ProjectTemplate id = "IPhoneWindowBasedProject" + resource = "IPhoneWindowBasedProject.xpt.xml" /> + <ProjectTemplate id = "IPhoneOpenGLProject" + resource = "IPhoneOpenGLProject.xpt.xml" /> + <ProjectTemplate id = "IPhoneNavBasedProject" + resource = "IPhoneNavBasedProject.xpt.xml" /> + <ProjectTemplate id = "IPhoneUtilityProject" + resource = "IPhoneUtilityProject.xpt.xml" /> <ProjectTemplate id = "IPhoneLibraryProject" resource = "IPhoneLibraryProject.xpt.xml" /> <ProjectTemplate id = "IPhoneProject-Empty" @@ -159,4 +165,10 @@ <StockIcon stockid = "iphone-project-options-panel" resource = "iphone-project-options-panel-16.png" size="Menu" /> <StockIcon stockid = "iphone-project-options-panel" resource = "iphone-project-options-panel-24.png" size="Button" /> </Extension> + + <Extension path = "/MonoDevelop/ProjectModel/MonoDocSources"> + <Condition id="MonoTouchInstalled"> + <Source directory="/Developer/MonoTouch/usr/share/doc/MonoTouch/" /> + </Condition> + </Extension> </Addin> diff --git a/extras/MonoDevelop.IPhone/MonoDevelop.IPhone/MonoDevelop.IPhone.csproj b/extras/MonoDevelop.IPhone/MonoDevelop.IPhone/MonoDevelop.IPhone.csproj index 83cdf873f0..68ecf17726 100644 --- a/extras/MonoDevelop.IPhone/MonoDevelop.IPhone/MonoDevelop.IPhone.csproj +++ b/extras/MonoDevelop.IPhone/MonoDevelop.IPhone/MonoDevelop.IPhone.csproj @@ -137,9 +137,6 @@ <EmbeddedResource Include="Templates\IPhoneApplicationPList.xft.xml"> <LogicalName>IPhoneApplicationPList.xft.xml</LogicalName> </EmbeddedResource> - <EmbeddedResource Include="Templates\IPhoneProject.xpt.xml"> - <LogicalName>IPhoneProject.xpt.xml</LogicalName> - </EmbeddedResource> <EmbeddedResource Include="Templates\IPhoneProjectEmpty.xpt.xml"> <LogicalName>IPhoneProjectEmpty.xpt.xml</LogicalName> </EmbeddedResource> @@ -212,6 +209,18 @@ <EmbeddedResource Include="Templates\IPhoneLibraryProject.xpt.xml"> <LogicalName>IPhoneLibraryProject.xpt.xml</LogicalName> </EmbeddedResource> + <EmbeddedResource Include="Templates\IPhoneWindowBasedProject.xpt.xml"> + <LogicalName>IPhoneWindowBasedProject.xpt.xml</LogicalName> + </EmbeddedResource> + <EmbeddedResource Include="Templates\IPhoneOpenGLProject.xpt.xml"> + <LogicalName>IPhoneOpenGLProject.xpt.xml</LogicalName> + </EmbeddedResource> + <EmbeddedResource Include="Templates\IPhoneNavBasedProject.xpt.xml"> + <LogicalName>IPhoneNavBasedProject.xpt.xml</LogicalName> + </EmbeddedResource> + <EmbeddedResource Include="Templates\IPhoneUtilityProject.xpt.xml"> + <LogicalName>IPhoneUtilityProject.xpt.xml</LogicalName> + </EmbeddedResource> </ItemGroup> <ItemGroup> <Folder Include="Templates\" /> diff --git a/extras/MonoDevelop.IPhone/MonoDevelop.IPhone/Templates/IPhoneApplicationXib.xft.xml b/extras/MonoDevelop.IPhone/MonoDevelop.IPhone/Templates/IPhoneApplicationXib.xft.xml index dc869a2d46..833bb57997 100644 --- a/extras/MonoDevelop.IPhone/MonoDevelop.IPhone/Templates/IPhoneApplicationXib.xft.xml +++ b/extras/MonoDevelop.IPhone/MonoDevelop.IPhone/Templates/IPhoneApplicationXib.xft.xml @@ -18,7 +18,7 @@ <!-- Template Content --> <TemplateFiles> - <File name="MainWindow.xib.designer.${LanguageExtension}" DependsOn="${Name}.xib" SuppressAutoOpen="True" + <File name="MainWindow.xib.designer.cs" DependsOn="${Name}.xib" SuppressAutoOpen="True" ShowAutogenerationNotice="True" AddStandardHeader="False" ><![CDATA[ namespace ${Namespace} { diff --git a/extras/MonoDevelop.IPhone/MonoDevelop.IPhone/Templates/IPhoneNavBasedProject.xpt.xml b/extras/MonoDevelop.IPhone/MonoDevelop.IPhone/Templates/IPhoneNavBasedProject.xpt.xml new file mode 100644 index 0000000000..70d313b185 --- /dev/null +++ b/extras/MonoDevelop.IPhone/MonoDevelop.IPhone/Templates/IPhoneNavBasedProject.xpt.xml @@ -0,0 +1,755 @@ +<?xml version="1.0"?> +<Template originator="Michael Hutchinson" + created="2009/06/08"> + + <!-- Template Header --> + <TemplateConfiguration> + <_Name>iPhone Navigation-based Project</_Name> + <_Category>C#/iPhone</_Category> + <Icon>md-project-iphone</Icon> + <LanguageName>C#</LanguageName> + <_Description>Navigation-based project for iPhone and iPod Touch.</_Description> + </TemplateConfiguration> + + <!-- Actions --> + <Actions> + </Actions> + + <!-- Template Content --> + <Combine name = "${ProjectName}" directory = "."> + <Options> + <StartupProject>${ProjectName}</StartupProject> + </Options> + + <Project name = "${ProjectName}" directory = "." type = "IPhone"> + <Options MainNibFile="MainWindow.nib" /> + <References> + <Reference type="Gac" refto="System, Version=2.0.5.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e" /> + <Reference type="Gac" refto="System.Xml, Version=2.0.5.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e" /> + <Reference type="Gac" refto="System.Core, Version=2.0.5.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e" /> + <Reference type="Gac" refto="monotouch" /> + </References> + <Files> + <File name="Main.cs"> +<![CDATA[ +using System; +using System.Collections.Generic; +using System.Linq; +using MonoTouch.Foundation; +using MonoTouch.UIKit; + +namespace ${Namespace} +{ + public class Application + { + static void Main (string[] args) + { + UIApplication.Main (args); + } + } + + // The name AppDelegate is referenced in the MainWindow.xib file. + public partial class AppDelegate : UIApplicationDelegate + { + // This method is invoked when the application has loaded its UI and its ready to run + public override bool FinishedLaunching (UIApplication app, NSDictionary options) + { + + window.AddSubview (navigationController.View); + window.MakeKeyAndVisible (); + + return true; + } + + // This method is required in iPhoneOS 3.0 + public override void OnActivated (UIApplication application) + { + } + + /* + public override void WillTerminate (UIApplication application) + { + //Save data here + } + */ + } +} +]]> + </File> + <File name="MainWindow.xib.designer.cs" + DependsOn="MainWindow.xib" + SuppressAutoOpen="True" + ShowAutogenerationNotice="True" + AddStandardHeader="False"> +<![CDATA[ +namespace ${Namespace} { + + + // Base type probably should be MonoTouch.Foundation.NSObject or subclass + [MonoTouch.Foundation.Register("AppDelegate")] + public partial class AppDelegate { + + #pragma warning disable 0169 + [MonoTouch.Foundation.Connect("window")] + private MonoTouch.UIKit.UIWindow window { + get { + return ((MonoTouch.UIKit.UIWindow)(this.GetNativeField("window"))); + } + set { + this.SetNativeField("window", value); + } + } + + [MonoTouch.Foundation.Connect("navigationController")] + private MonoTouch.UIKit.UINavigationController navigationController { + get { + return ((MonoTouch.UIKit.UINavigationController)(this.GetNativeField("navigationController"))); + } + set { + this.SetNativeField("navigationController", value); + } + } + } +} +]]> + </File> + <File name="MainWindow.xib" + SuppressAutoOpen="True"> +<![CDATA[ +<?xml version="1.0" encoding="UTF-8"?> +<archive type="com.apple.InterfaceBuilder3.CocoaTouch.XIB" version="7.10"> + <data> + <int key="IBDocument.SystemTarget">784</int> + <string key="IBDocument.SystemVersion">10A394</string> + <string key="IBDocument.InterfaceBuilderVersion">732</string> + <string key="IBDocument.AppKitVersion">1027.1</string> + <string key="IBDocument.HIToolboxVersion">430.00</string> + <object class="NSMutableDictionary" key="IBDocument.PluginVersions"> + <string key="NS.key.0">com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string> + <string key="NS.object.0">60</string> + </object> + <object class="NSMutableArray" key="IBDocument.EditedObjectIDs"> + <bool key="EncodedWithXMLCoder">YES</bool> + <integer value="13"/> + </object> + <object class="NSArray" key="IBDocument.PluginDependencies"> + <bool key="EncodedWithXMLCoder">YES</bool> + <string>com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string> + </object> + <object class="NSMutableDictionary" key="IBDocument.Metadata"> + <bool key="EncodedWithXMLCoder">YES</bool> + <object class="NSArray" key="dict.sortedKeys" id="0"> + <bool key="EncodedWithXMLCoder">YES</bool> + </object> + <object class="NSMutableArray" key="dict.values"> + <bool key="EncodedWithXMLCoder">YES</bool> + </object> + </object> + <object class="NSMutableArray" key="IBDocument.RootObjects" id="1000"> + <bool key="EncodedWithXMLCoder">YES</bool> + <object class="IBProxyObject" id="841351856"> + <string key="IBProxiedObjectIdentifier">IBFilesOwner</string> + </object> + <object class="IBProxyObject" id="302016328"> + <string key="IBProxiedObjectIdentifier">IBFirstResponder</string> + </object> + <object class="IBUICustomObject" id="664661524"/> + <object class="IBUIWindow" id="380026005"> + <nil key="NSNextResponder"/> + <int key="NSvFlags">1316</int> + <object class="NSPSMatrix" key="NSFrameMatrix"/> + <string key="NSFrameSize">{320, 480}</string> + <object class="NSColor" key="IBUIBackgroundColor"> + <int key="NSColorSpace">1</int> + <bytes key="NSRGB">MSAxIDEAA</bytes> + </object> + <bool key="IBUIOpaque">NO</bool> + <bool key="IBUIClearsContextBeforeDrawing">NO</bool> + <object class="IBUISimulatedStatusBarMetrics" key="IBUISimulatedStatusBarMetrics"/> + </object> + <object class="IBUINavigationController" id="701001926"> + <object class="IBUISimulatedStatusBarMetrics" key="IBUISimulatedStatusBarMetrics"/> + <object class="IBUINavigationBar" key="IBUINavigationBar" id="207850653"> + <nil key="NSNextResponder"/> + <int key="NSvFlags">256</int> + <string key="NSFrameSize">{0, 0}</string> + <bool key="IBUIOpaque">NO</bool> + <bool key="IBUIClipsSubviews">YES</bool> + <bool key="IBUIMultipleTouchEnabled">YES</bool> + </object> + <object class="NSMutableArray" key="IBUIViewControllers"> + <bool key="EncodedWithXMLCoder">YES</bool> + <object class="IBUIViewController" id="619226028"> + <object class="IBUINavigationItem" key="IBUINavigationItem" id="394667715"> + <reference key="IBUINavigationBar"/> + </object> + <reference key="IBUIParentViewController" ref="701001926"/> + <string key="IBUINibName">RootViewController</string> + <object class="IBUISimulatedStatusBarMetrics" key="IBUISimulatedStatusBarMetrics"/> + </object> + </object> + </object> + </object> + <object class="IBObjectContainer" key="IBDocument.Objects"> + <object class="NSMutableArray" key="connectionRecords"> + <bool key="EncodedWithXMLCoder">YES</bool> + <object class="IBConnectionRecord"> + <object class="IBCocoaTouchOutletConnection" key="connection"> + <string key="label">delegate</string> + <reference key="source" ref="841351856"/> + <reference key="destination" ref="664661524"/> + </object> + <int key="connectionID">4</int> + </object> + <object class="IBConnectionRecord"> + <object class="IBCocoaTouchOutletConnection" key="connection"> + <string key="label">window</string> + <reference key="source" ref="664661524"/> + <reference key="destination" ref="380026005"/> + </object> + <int key="connectionID">5</int> + </object> + <object class="IBConnectionRecord"> + <object class="IBCocoaTouchOutletConnection" key="connection"> + <string key="label">navigationController</string> + <reference key="source" ref="664661524"/> + <reference key="destination" ref="701001926"/> + </object> + <int key="connectionID">15</int> + </object> + </object> + <object class="IBMutableOrderedSet" key="objectRecords"> + <object class="NSArray" key="orderedObjects"> + <bool key="EncodedWithXMLCoder">YES</bool> + <object class="IBObjectRecord"> + <int key="objectID">0</int> + <reference key="object" ref="0"/> + <reference key="children" ref="1000"/> + <nil key="parent"/> + </object> + <object class="IBObjectRecord"> + <int key="objectID">2</int> + <reference key="object" ref="380026005"/> + <object class="NSMutableArray" key="children"> + <bool key="EncodedWithXMLCoder">YES</bool> + </object> + <reference key="parent" ref="0"/> + </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">3</int> + <reference key="object" ref="664661524"/> + <reference key="parent" ref="0"/> + </object> + <object class="IBObjectRecord"> + <int key="objectID">-2</int> + <reference key="object" ref="302016328"/> + <reference key="parent" ref="0"/> + </object> + <object class="IBObjectRecord"> + <int key="objectID">9</int> + <reference key="object" ref="701001926"/> + <object class="NSMutableArray" key="children"> + <bool key="EncodedWithXMLCoder">YES</bool> + <reference ref="207850653"/> + <reference ref="619226028"/> + </object> + <reference key="parent" ref="0"/> + </object> + <object class="IBObjectRecord"> + <int key="objectID">11</int> + <reference key="object" ref="207850653"/> + <reference key="parent" ref="701001926"/> + </object> + <object class="IBObjectRecord"> + <int key="objectID">13</int> + <reference key="object" ref="619226028"/> + <object class="NSMutableArray" key="children"> + <bool key="EncodedWithXMLCoder">YES</bool> + <reference ref="394667715"/> + </object> + <reference key="parent" ref="701001926"/> + </object> + <object class="IBObjectRecord"> + <int key="objectID">14</int> + <reference key="object" ref="394667715"/> + <reference key="parent" ref="619226028"/> + </object> + </object> + </object> + <object class="NSMutableDictionary" key="flattenedProperties"> + <bool key="EncodedWithXMLCoder">YES</bool> + <object class="NSArray" key="dict.sortedKeys"> + <bool key="EncodedWithXMLCoder">YES</bool> + <string>-1.CustomClassName</string> + <string>-2.CustomClassName</string> + <string>11.IBPluginDependency</string> + <string>13.CustomClassName</string> + <string>13.IBPluginDependency</string> + <string>2.IBAttributePlaceholdersKey</string> + <string>2.IBEditorWindowLastContentRect</string> + <string>2.IBPluginDependency</string> + <string>3.CustomClassName</string> + <string>3.IBPluginDependency</string> + <string>9.IBEditorWindowLastContentRect</string> + <string>9.IBPluginDependency</string> + </object> + <object class="NSMutableArray" key="dict.values"> + <bool key="EncodedWithXMLCoder">YES</bool> + <string>UIApplication</string> + <string>UIResponder</string> + <string>com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string> + <string>RootViewController</string> + <string>com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string> + <object class="NSMutableDictionary"> + <bool key="EncodedWithXMLCoder">YES</bool> + <reference key="dict.sortedKeys" ref="0"/> + <object class="NSMutableArray" key="dict.values"> + <bool key="EncodedWithXMLCoder">YES</bool> + </object> + </object> + <string>{{673, 376}, {320, 480}}</string> + <string>com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string> + <string>AppDelegate</string> + <string>com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string> + <string>{{500, 343}, {320, 480}}</string> + <string>com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string> + </object> + </object> + <object class="NSMutableDictionary" key="unlocalizedProperties"> + <bool key="EncodedWithXMLCoder">YES</bool> + <reference key="dict.sortedKeys" ref="0"/> + <object class="NSMutableArray" key="dict.values"> + <bool key="EncodedWithXMLCoder">YES</bool> + </object> + </object> + <nil key="activeLocalization"/> + <object class="NSMutableDictionary" key="localizations"> + <bool key="EncodedWithXMLCoder">YES</bool> + <reference key="dict.sortedKeys" ref="0"/> + <object class="NSMutableArray" key="dict.values"> + <bool key="EncodedWithXMLCoder">YES</bool> + </object> + </object> + <nil key="sourceID"/> + <int key="maxID">15</int> + </object> + <object class="IBClassDescriber" key="IBDocument.Classes"> + <object class="NSMutableArray" key="referencedPartialClassDescriptions"> + <bool key="EncodedWithXMLCoder">YES</bool> + <object class="IBPartialClassDescription"> + <string key="className">RootViewController</string> + <string key="superclassName">UITableViewController</string> + <object class="IBClassDescriptionSource" key="sourceIdentifier"> + <string key="majorKey">IBUserSource</string> + <string key="minorKey"></string> + </object> + </object> + <object class="IBPartialClassDescription"> + <string key="className">AppDelegate</string> + <string key="superclassName">NSObject</string> + <object class="NSMutableDictionary" key="outlets"> + <bool key="EncodedWithXMLCoder">YES</bool> + <object class="NSArray" key="dict.sortedKeys"> + <bool key="EncodedWithXMLCoder">YES</bool> + <string>navigationController</string> + <string>window</string> + </object> + <object class="NSMutableArray" key="dict.values"> + <bool key="EncodedWithXMLCoder">YES</bool> + <string>UINavigationController</string> + <string>UIWindow</string> + </object> + </object> + <object class="IBClassDescriptionSource" key="sourceIdentifier"> + <string key="majorKey">IBUserSource</string> + <string key="minorKey"></string> + </object> + </object> + </object> + </object> + <int key="IBDocument.localizationMode">0</int> + <object class="NSMutableDictionary" key="IBDocument.PluginDeclaredDevelopmentDependencies"> + <string key="NS.key.0">com.apple.InterfaceBuilder.CocoaTouchPlugin.InterfaceBuilder3</string> + <integer value="3100" key="NS.object.0"/> + </object> + <bool key="IBDocument.PluginDeclaredDependenciesTrackSystemTargetVersion">YES</bool> + <string key="IBDocument.LastKnownRelativeProjectPath">NavBased.xcodeproj</string> + <int key="IBDocument.defaultPropertyAccessControl">3</int> + <string key="IBCocoaTouchPluginVersion">3.1</string> + </data> +</archive> +]]> + </File> + <File name="RootViewController.xib" + SuppressAutoOpen="True"> +<![CDATA[ +<?xml version="1.0" encoding="UTF-8"?> +<archive type="com.apple.InterfaceBuilder3.CocoaTouch.XIB" version="7.10"> + <data> + <int key="IBDocument.SystemTarget">784</int> + <string key="IBDocument.SystemVersion">10A405</string> + <string key="IBDocument.InterfaceBuilderVersion">732</string> + <string key="IBDocument.AppKitVersion">1031</string> + <string key="IBDocument.HIToolboxVersion">432.00</string> + <object class="NSMutableDictionary" key="IBDocument.PluginVersions"> + <string key="NS.key.0">com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string> + <string key="NS.object.0">62</string> + </object> + <object class="NSMutableArray" key="IBDocument.EditedObjectIDs"> + <bool key="EncodedWithXMLCoder">YES</bool> + <integer value="2"/> + </object> + <object class="NSArray" key="IBDocument.PluginDependencies"> + <bool key="EncodedWithXMLCoder">YES</bool> + <string>com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string> + </object> + <object class="NSMutableDictionary" key="IBDocument.Metadata"> + <bool key="EncodedWithXMLCoder">YES</bool> + <object class="NSArray" key="dict.sortedKeys" id="0"> + <bool key="EncodedWithXMLCoder">YES</bool> + </object> + <object class="NSMutableArray" key="dict.values"> + <bool key="EncodedWithXMLCoder">YES</bool> + </object> + </object> + <object class="NSMutableArray" key="IBDocument.RootObjects" id="1000"> + <bool key="EncodedWithXMLCoder">YES</bool> + <object class="IBProxyObject" id="841351856"> + <string key="IBProxiedObjectIdentifier">IBFilesOwner</string> + </object> + <object class="IBProxyObject" id="371349661"> + <string key="IBProxiedObjectIdentifier">IBFirstResponder</string> + </object> + <object class="IBUITableView" id="709618507"> + <reference key="NSNextResponder"/> + <int key="NSvFlags">274</int> + <string key="NSFrameSize">{320, 247}</string> + <reference key="NSSuperview"/> + <object class="NSColor" key="IBUIBackgroundColor"> + <int key="NSColorSpace">3</int> + <bytes key="NSWhite">MQA</bytes> + </object> + <bool key="IBUIOpaque">NO</bool> + <bool key="IBUIClipsSubviews">YES</bool> + <bool key="IBUIClearsContextBeforeDrawing">NO</bool> + <bool key="IBUIBouncesZoom">NO</bool> + <int key="IBUISeparatorStyle">1</int> + <int key="IBUISectionIndexMinimumDisplayRowCount">0</int> + <bool key="IBUIShowsSelectionImmediatelyOnTouchBegin">YES</bool> + <float key="IBUIRowHeight">44</float> + <float key="IBUISectionHeaderHeight">22</float> + <float key="IBUISectionFooterHeight">22</float> + </object> + </object> + <object class="IBObjectContainer" key="IBDocument.Objects"> + <object class="NSMutableArray" key="connectionRecords"> + <bool key="EncodedWithXMLCoder">YES</bool> + <object class="IBConnectionRecord"> + <object class="IBCocoaTouchOutletConnection" key="connection"> + <string key="label">view</string> + <reference key="source" ref="841351856"/> + <reference key="destination" ref="709618507"/> + </object> + <int key="connectionID">3</int> + </object> + <object class="IBConnectionRecord"> + <object class="IBCocoaTouchOutletConnection" key="connection"> + <string key="label">dataSource</string> + <reference key="source" ref="709618507"/> + <reference key="destination" ref="841351856"/> + </object> + <int key="connectionID">4</int> + </object> + <object class="IBConnectionRecord"> + <object class="IBCocoaTouchOutletConnection" key="connection"> + <string key="label">delegate</string> + <reference key="source" ref="709618507"/> + <reference key="destination" ref="841351856"/> + </object> + <int key="connectionID">5</int> + </object> + </object> + <object class="IBMutableOrderedSet" key="objectRecords"> + <object class="NSArray" key="orderedObjects"> + <bool key="EncodedWithXMLCoder">YES</bool> + <object class="IBObjectRecord"> + <int key="objectID">0</int> + <reference key="object" ref="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="371349661"/> + <reference key="parent" ref="0"/> + </object> + <object class="IBObjectRecord"> + <int key="objectID">2</int> + <reference key="object" ref="709618507"/> + <reference key="parent" ref="0"/> + </object> + </object> + </object> + <object class="NSMutableDictionary" key="flattenedProperties"> + <bool key="EncodedWithXMLCoder">YES</bool> + <object class="NSArray" key="dict.sortedKeys"> + <bool key="EncodedWithXMLCoder">YES</bool> + <string>-1.CustomClassName</string> + <string>-2.CustomClassName</string> + <string>2.IBEditorWindowLastContentRect</string> + <string>2.IBPluginDependency</string> + </object> + <object class="NSMutableArray" key="dict.values"> + <bool key="EncodedWithXMLCoder">YES</bool> + <string>RootViewController</string> + <string>UIResponder</string> + <string>{{0, 598}, {320, 247}}</string> + <string>com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string> + </object> + </object> + <object class="NSMutableDictionary" key="unlocalizedProperties"> + <bool key="EncodedWithXMLCoder">YES</bool> + <reference key="dict.sortedKeys" ref="0"/> + <object class="NSMutableArray" key="dict.values"> + <bool key="EncodedWithXMLCoder">YES</bool> + </object> + </object> + <nil key="activeLocalization"/> + <object class="NSMutableDictionary" key="localizations"> + <bool key="EncodedWithXMLCoder">YES</bool> + <reference key="dict.sortedKeys" ref="0"/> + <object class="NSMutableArray" key="dict.values"> + <bool key="EncodedWithXMLCoder">YES</bool> + </object> + </object> + <nil key="sourceID"/> + <int key="maxID">5</int> + </object> + <object class="IBClassDescriber" key="IBDocument.Classes"> + <object class="NSMutableArray" key="referencedPartialClassDescriptions"> + <bool key="EncodedWithXMLCoder">YES</bool> + <object class="IBPartialClassDescription"> + <string key="className">RootViewController</string> + <string key="superclassName">UITableViewController</string> + <object class="IBClassDescriptionSource" key="sourceIdentifier"> + <string key="majorKey">IBUserSource</string> + <string key="minorKey"></string> + </object> + </object> + </object> + </object> + <int key="IBDocument.localizationMode">0</int> + <object class="NSMutableDictionary" key="IBDocument.PluginDeclaredDependencyDefaults"> + <string key="NS.key.0">com.apple.InterfaceBuilder.CocoaTouchPlugin.iPhoneOS</string> + <integer value="784" key="NS.object.0"/> + </object> + <object class="NSMutableDictionary" key="IBDocument.PluginDeclaredDevelopmentDependencies"> + <string key="NS.key.0">com.apple.InterfaceBuilder.CocoaTouchPlugin.InterfaceBuilder3</string> + <integer value="3100" key="NS.object.0"/> + </object> + <bool key="IBDocument.PluginDeclaredDependenciesTrackSystemTargetVersion">YES</bool> + <string key="IBDocument.LastKnownRelativeProjectPath">NavBased.xcodeproj</string> + <int key="IBDocument.defaultPropertyAccessControl">3</int> + <string key="IBCocoaTouchPluginVersion">3.1</string> + </data> +</archive> +]]> + </File> + <File name="RootViewController.xib.cs" + SuppressAutoOpen="True" + DependsOn="RootViewController.xib"> +<![CDATA[ +using MonoTouch.UIKit; +using System; +using MonoTouch.Foundation; + +namespace ${Namespace} +{ + partial class RootViewController : UITableViewController + { + public RootViewController (IntPtr handle) : base (handle) + { + } + + public override void ViewDidLoad () + { + base.ViewDidLoad (); + //Show an edit button + //NavigationItem.RightBarButtonItem = EditButtonItem; + + this.TableView.Source = new DataSource (this); + } + + /* + public override void ViewWillAppear (bool animated) + { + base.ViewWillAppear (animated); + } + */ + /* + public override void ViewDidAppear (bool animated) + { + base.ViewDidAppear (animated); + } + */ + /* + public override void ViewWillDisappear (bool animated) + { + base.ViewWillDisappear (animated); + } + */ + /* + public override void ViewDidDisappear (bool animated) + { + base.ViewDidDisappear (animated); + } + */ + + /* + // Override to allow orientations other than the default portrait orientation + public override bool ShouldAutorotateToInterfaceOrientation (UIInterfaceOrientation toInterfaceOrientation) + { + //return true for supported orientations + return (InterfaceOrientation == UIInterfaceOrientation.Portrait); + } + */ + + public override void DidReceiveMemoryWarning () + { + // Releases the view if it doesn't have a superview. + base.DidReceiveMemoryWarning (); + + // Release any cached data, images, etc that aren't in use. + } + + public override void ViewDidUnload () + { + // Release anything that can be recreated in viewDidLoad or on demand. + // e.g. this.myOutlet = null; + + base.ViewDidUnload (); + } + + class DataSource : UITableViewSource + { + RootViewController controller; + + public DataSource (RootViewController controller) + { + this.controller = controller; + } + + public override int NumberOfSections (UITableView tableView) + { + return 1; + } + + // Customize the number of rows in the table view + public override int RowsInSection (UITableView tableview, int section) + { + return 0; + } + + // Customize the appearance of table view cells. + public override UITableViewCell GetCell (UITableView tableView, MonoTouch.Foundation.NSIndexPath indexPath) + { + string cellIdentifier = "Cell"; + var cell = tableView.DequeueReusableCell (cellIdentifier); + if (cell != null) { + cell = new UITableViewCell (UITableViewCellStyle.Default, cellIdentifier); + } + + // Configure the cell. + + return cell; + } + + /* + // Override to support conditional editing of the table view. + public override bool CanEditRow (UITableView tableView, MonoTouch.Foundation.NSIndexPath indexPath) + { + // Return false if you do not want the specified item to be editable. + return true; + } + */ + /* + // Override to support editing the table view. + public override void CommitEditingStyle (UITableView tableView, UITableViewCellEditingStyle editingStyle, MonoTouch.Foundation.NSIndexPath indexPath) + { + if (editingStyle == UITableViewCellEditingStyle.Delete) { + controller.TableView.DeleteRows (new NSIndexPath[] { indexPath }, UITableViewRowAnimation.Fade); + } else if (editingStyle == UITableViewCellEditingStyle.Insert) { + // Create a new instance of the appropriate class, insert it into the array, and add a new row to the table view. + } + } + */ + /* + // Override to support rearranging the table view. + public override void MoveRow (UITableView tableView, NSIndexPath sourceIndexPath, NSIndexPath destinationIndexPath) + { + } + */ + /* + // Override to support conditional rearranging of the table view. + public override bool CanMoveRow (UITableView tableView, NSIndexPath indexPath) + { + // Return false if you do not want the item to be re-orderable. + return true; + } + */ + + // Override to support row selection in the table view. + public override void RowSelected (UITableView tableView, MonoTouch.Foundation.NSIndexPath indexPath) + { + // Navigation logic may go here -- for example, create and push another view controller. + // var anotherViewController = new AnotherViewController ("AnotherView", null); + //controller.NavigationController.PushViewController (anotherViewController, true); + } + } + } + +} +]]> + </File> + <File name="RootViewController.xib.designer.cs" + DependsOn="RootViewController.xib" + SuppressAutoOpen="True" + ShowAutogenerationNotice="True" + AddStandardHeader="False"> +<![CDATA[ +namespace ${Namespace} { + + // Base type probably should be MonoTouch.UIKit.UIViewController or subclass + [MonoTouch.Foundation.Register("RootViewController")] + public partial class RootViewController { + + #pragma warning disable 0169 + [MonoTouch.Foundation.Connect("view")] + private MonoTouch.UIKit.UITableView view { + get { + return ((MonoTouch.UIKit.UITableView)(this.GetNativeField("view"))); + } + set { + this.SetNativeField("view", value); + } + } + } +} +]]> + </File> + </Files> + </Project> + </Combine> +</Template> diff --git a/extras/MonoDevelop.IPhone/MonoDevelop.IPhone/Templates/IPhoneOpenGLProject.xpt.xml b/extras/MonoDevelop.IPhone/MonoDevelop.IPhone/Templates/IPhoneOpenGLProject.xpt.xml new file mode 100644 index 0000000000..e5e38d1eb7 --- /dev/null +++ b/extras/MonoDevelop.IPhone/MonoDevelop.IPhone/Templates/IPhoneOpenGLProject.xpt.xml @@ -0,0 +1,443 @@ +<?xml version="1.0"?> +<Template originator="Michael Hutchinson" + created="2009/06/08"> + + <!-- Template Header --> + <TemplateConfiguration> + <_Name>iPhone OpenGL Project</_Name> + <_Category>C#/iPhone</_Category> + <Icon>md-project-iphone</Icon> + <LanguageName>C#</LanguageName> + <_Description>OpenGL project for iPhone and iPod Touch.</_Description> + </TemplateConfiguration> + + <!-- Actions --> + <Actions> + </Actions> + + <!-- Template Content --> + <Combine name = "${ProjectName}" directory = "."> + <Options> + <StartupProject>${ProjectName}</StartupProject> + </Options> + + <Project name = "${ProjectName}" directory = "." type = "IPhone"> + <Options MainNibFile="MainWindow.nib" /> + <References> + <Reference type="Gac" refto="System, Version=2.0.5.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e" /> + <Reference type="Gac" refto="System.Xml, Version=2.0.5.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e" /> + <Reference type="Gac" refto="System.Core, Version=2.0.5.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e" /> + <Reference type="Gac" refto="monotouch" /> + <Reference type="Gac" refto="OpenTK" /> + </References> + <Files> + <File name="Main.cs"> +<![CDATA[ +using System; +using System.Collections.Generic; +using System.Linq; +using MonoTouch.Foundation; +using MonoTouch.UIKit; + +namespace ${Namespace} +{ + public class Application + { + static void Main (string[] args) + { + UIApplication.Main (args); + } + } + + // The name AppDelegate is referenced in the MainWindow.xib file. + public partial class AppDelegate : UIApplicationDelegate + { + // This method is invoked when the application has loaded its UI and is ready to run + public override void FinishedLaunching (UIApplication app) + { + glView.Run(60.0); + } + + public override void OnResignActivation (UIApplication app) + { + glView.Stop(); + glView.Run(5.0); + } + + // This method is required in iPhoneOS 3.0 + public override void OnActivated (UIApplication app) + { + glView.Stop(); + glView.Run(60.0); + } + } +} +]]> + </File> + <File name="EAGLView.cs"> +<![CDATA[ +using System; +using OpenTK.Platform.iPhoneOS; +using MonoTouch.CoreAnimation; +using OpenTK; +using OpenTK.Graphics.ES11; +using MonoTouch.Foundation; +using MonoTouch.ObjCRuntime; +using MonoTouch.OpenGLES; + +namespace ${Namespace} +{ + public partial class EAGLView : iPhoneOSGameView + { + [Export ("layerClass")] + static Class LayerClass() + { + return iPhoneOSGameView.GetLayerClass (); + } + + [Export ("initWithCoder:")] + public EAGLView (NSCoder coder) + : base (coder) + { + LayerRetainsBacking = false; + LayerColorFormat = EAGLColorFormat.RGBA8; + ContextRenderingApi = EAGLRenderingAPI.OpenGLES1; + } + + protected override void ConfigureLayer (CAEAGLLayer eaglLayer) + { + eaglLayer.Opaque = true; + } + + protected override void OnRenderFrame (FrameEventArgs e) + { + base.OnRenderFrame (e); + float[] squareVertices = { + -0.5f, -0.5f, + 0.5f, -0.5f, + -0.5f, 0.5f, + 0.5f, 0.5f, + }; + byte[] squareColors = { + 255, 255, 0, 255, + 0, 255, 255, 255, + 0, 0, 0, 0, + 255, 0, 255, 255, + }; + + MakeCurrent(); + GL.Viewport (0, 0, Size.Width, Size.Height); + + GL.MatrixMode (All.Projection); + GL.LoadIdentity (); + GL.Ortho (-1.0f, 1.0f, -1.5f, 1.5f, -1.0f, 1.0f); + GL.MatrixMode (All.Modelview); + GL.Rotate (3.0f, 0.0f, 0.0f, 1.0f); + + GL.ClearColor (0.5f, 0.5f, 0.5f, 1.0f); + GL.Clear ((uint) All.ColorBufferBit); + + GL.VertexPointer (2, All.Float, 0, squareVertices); + GL.EnableClientState (All.VertexArray); + GL.ColorPointer (4, All.UnsignedByte, 0, squareColors); + GL.EnableClientState (All.ColorArray); + + GL.DrawArrays (All.TriangleStrip, 0, 4); + + SwapBuffers(); + } + } +} +]]> + </File> + <File name="MainWindow.xib.designer.cs" + DependsOn="MainWindow.xib" + SuppressAutoOpen="True" + ShowAutogenerationNotice="True" + AddStandardHeader="False"> +<![CDATA[ +namespace ${Namespace} { + + // Base type probably should be MonoTouch.Foundation.NSObject or subclass + [MonoTouch.Foundation.Register("AppDelegate")] + public partial class AppDelegate { + + #pragma warning disable 0169 + [MonoTouch.Foundation.Connect("window")] + private MonoTouch.UIKit.UIWindow window { + get { + return ((MonoTouch.UIKit.UIWindow)(this.GetNativeField("window"))); + } + set { + this.SetNativeField("window", value); + } + } + + [MonoTouch.Foundation.Connect("glView")] + private EAGLView glView { + get { + return ((EAGLView)(this.GetNativeField("glView"))); + } + set { + this.SetNativeField("glView", value); + } + } + } + + // Base type probably should be MonoTouch.UIKit.UIView or subclass + [MonoTouch.Foundation.Register("EAGLView")] + public partial class EAGLView { + } +} +]]> + </File> + <File name="MainWindow.xib" + SuppressAutoOpen="True"> +<![CDATA[ +<?xml version="1.0" encoding="UTF-8"?> +<archive type="com.apple.InterfaceBuilder3.CocoaTouch.XIB" version="7.10"> + <data> + <int key="IBDocument.SystemTarget">768</int> + <string key="IBDocument.SystemVersion">10C540</string> + <string key="IBDocument.InterfaceBuilderVersion">740</string> + <string key="IBDocument.AppKitVersion">1038.25</string> + <string key="IBDocument.HIToolboxVersion">458.00</string> + <object class="NSMutableDictionary" key="IBDocument.PluginVersions"> + <string key="NS.key.0">com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string> + <string key="NS.object.0">62</string> + </object> + <object class="NSMutableArray" key="IBDocument.EditedObjectIDs"> + <bool key="EncodedWithXMLCoder">YES</bool> + <integer value="2"/> + </object> + <object class="NSArray" key="IBDocument.PluginDependencies"> + <bool key="EncodedWithXMLCoder">YES</bool> + <string>com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string> + </object> + <object class="NSMutableDictionary" key="IBDocument.Metadata"> + <bool key="EncodedWithXMLCoder">YES</bool> + <object class="NSArray" key="dict.sortedKeys" id="0"> + <bool key="EncodedWithXMLCoder">YES</bool> + </object> + <object class="NSMutableArray" key="dict.values"> + <bool key="EncodedWithXMLCoder">YES</bool> + </object> + </object> + <object class="NSMutableArray" key="IBDocument.RootObjects" id="1000"> + <bool key="EncodedWithXMLCoder">YES</bool> + <object class="IBProxyObject" id="841351856"> + <string key="IBProxiedObjectIdentifier">IBFilesOwner</string> + </object> + <object class="IBProxyObject" id="587066532"> + <string key="IBProxiedObjectIdentifier">IBFirstResponder</string> + </object> + <object class="IBUICustomObject" id="987256611"/> + <object class="IBUIWindow" id="380026005"> + <reference key="NSNextResponder"/> + <int key="NSvFlags">1316</int> + <object class="NSMutableArray" key="NSSubviews"> + <bool key="EncodedWithXMLCoder">YES</bool> + <object class="IBUIView" id="668263171"> + <reference key="NSNextResponder" ref="380026005"/> + <int key="NSvFlags">1298</int> + <string key="NSFrame">{{0, 20}, {320, 460}}</string> + <reference key="NSSuperview" ref="380026005"/> + <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> + <bool key="IBUIClearsContextBeforeDrawing">NO</bool> + </object> + </object> + <object class="NSPSMatrix" key="NSFrameMatrix"/> + <string key="NSFrameSize">{320, 480}</string> + <reference key="NSSuperview"/> + <object class="NSColor" key="IBUIBackgroundColor"> + <int key="NSColorSpace">1</int> + <bytes key="NSRGB">MSAxIDEAA</bytes> + </object> + <bool key="IBUIOpaque">NO</bool> + <bool key="IBUIClearsContextBeforeDrawing">NO</bool> + <object class="IBUISimulatedStatusBarMetrics" key="IBUISimulatedStatusBarMetrics"/> + </object> + </object> + <object class="IBObjectContainer" key="IBDocument.Objects"> + <object class="NSMutableArray" key="connectionRecords"> + <bool key="EncodedWithXMLCoder">YES</bool> + <object class="IBConnectionRecord"> + <object class="IBCocoaTouchOutletConnection" key="connection"> + <string key="label">delegate</string> + <reference key="source" ref="841351856"/> + <reference key="destination" ref="987256611"/> + </object> + <int key="connectionID">5</int> + </object> + <object class="IBConnectionRecord"> + <object class="IBCocoaTouchOutletConnection" key="connection"> + <string key="label">window</string> + <reference key="source" ref="987256611"/> + <reference key="destination" ref="380026005"/> + </object> + <int key="connectionID">7</int> + </object> + <object class="IBConnectionRecord"> + <object class="IBCocoaTouchOutletConnection" key="connection"> + <string key="label">glView</string> + <reference key="source" ref="987256611"/> + <reference key="destination" ref="668263171"/> + </object> + <int key="connectionID">9</int> + </object> + </object> + <object class="IBMutableOrderedSet" key="objectRecords"> + <object class="NSArray" key="orderedObjects"> + <bool key="EncodedWithXMLCoder">YES</bool> + <object class="IBObjectRecord"> + <int key="objectID">0</int> + <reference key="object" ref="0"/> + <reference key="children" ref="1000"/> + <nil key="parent"/> + </object> + <object class="IBObjectRecord"> + <int key="objectID">2</int> + <reference key="object" ref="380026005"/> + <object class="NSMutableArray" key="children"> + <bool key="EncodedWithXMLCoder">YES</bool> + <reference ref="668263171"/> + </object> + <reference key="parent" ref="0"/> + </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">4</int> + <reference key="object" ref="987256611"/> + <reference key="parent" ref="0"/> + <string key="objectName">App Delegate</string> + </object> + <object class="IBObjectRecord"> + <int key="objectID">-2</int> + <reference key="object" ref="587066532"/> + <reference key="parent" ref="0"/> + </object> + <object class="IBObjectRecord"> + <int key="objectID">8</int> + <reference key="object" ref="668263171"/> + <reference key="parent" ref="380026005"/> + </object> + </object> + </object> + <object class="NSMutableDictionary" key="flattenedProperties"> + <bool key="EncodedWithXMLCoder">YES</bool> + <object class="NSArray" key="dict.sortedKeys"> + <bool key="EncodedWithXMLCoder">YES</bool> + <string>-1.CustomClassName</string> + <string>-2.CustomClassName</string> + <string>2.IBAttributePlaceholdersKey</string> + <string>2.IBEditorWindowLastContentRect</string> + <string>2.IBPluginDependency</string> + <string>2.UIWindow.visibleAtLaunch</string> + <string>4.CustomClassName</string> + <string>4.IBPluginDependency</string> + <string>8.CustomClassName</string> + <string>8.IBPluginDependency</string> + </object> + <object class="NSMutableArray" key="dict.values"> + <bool key="EncodedWithXMLCoder">YES</bool> + <string>UIApplication</string> + <string>UIResponder</string> + <object class="NSMutableDictionary"> + <bool key="EncodedWithXMLCoder">YES</bool> + <reference key="dict.sortedKeys" ref="0"/> + <object class="NSMutableArray" key="dict.values"> + <bool key="EncodedWithXMLCoder">YES</bool> + </object> + </object> + <string>{{593, 276}, {320, 480}}</string> + <string>com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string> + <integer value="1"/> + <string>AppDelegate</string> + <string>com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string> + <string>EAGLView</string> + <string>com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string> + </object> + </object> + <object class="NSMutableDictionary" key="unlocalizedProperties"> + <bool key="EncodedWithXMLCoder">YES</bool> + <reference key="dict.sortedKeys" ref="0"/> + <object class="NSMutableArray" key="dict.values"> + <bool key="EncodedWithXMLCoder">YES</bool> + </object> + </object> + <nil key="activeLocalization"/> + <object class="NSMutableDictionary" key="localizations"> + <bool key="EncodedWithXMLCoder">YES</bool> + <reference key="dict.sortedKeys" ref="0"/> + <object class="NSMutableArray" key="dict.values"> + <bool key="EncodedWithXMLCoder">YES</bool> + </object> + </object> + <nil key="sourceID"/> + <int key="maxID">9</int> + </object> + <object class="IBClassDescriber" key="IBDocument.Classes"> + <object class="NSMutableArray" key="referencedPartialClassDescriptions"> + <bool key="EncodedWithXMLCoder">YES</bool> + <object class="IBPartialClassDescription"> + <string key="className">AppDelegate</string> + <object class="NSMutableDictionary" key="outlets"> + <bool key="EncodedWithXMLCoder">YES</bool> + <object class="NSArray" key="dict.sortedKeys"> + <bool key="EncodedWithXMLCoder">YES</bool> + <string>glView</string> + <string>window</string> + </object> + <object class="NSMutableArray" key="dict.values"> + <bool key="EncodedWithXMLCoder">YES</bool> + <string>EAGLView</string> + <string>id</string> + </object> + </object> + <object class="IBClassDescriptionSource" key="sourceIdentifier"> + <string key="majorKey">IBUserSource</string> + <string key="minorKey"/> + </object> + </object> + <object class="IBPartialClassDescription"> + <string key="className">EAGLView</string> + <string key="superclassName">UIView</string> + <object class="IBClassDescriptionSource" key="sourceIdentifier"> + <string key="majorKey">IBUserSource</string> + <string key="minorKey"/> + </object> + </object> + </object> + </object> + <int key="IBDocument.localizationMode">0</int> + <object class="NSMutableDictionary" key="IBDocument.PluginDeclaredDependencies"> + <string key="NS.key.0">com.apple.InterfaceBuilder.CocoaTouchPlugin.iPhoneOS</string> + <integer value="768" key="NS.object.0"/> + </object> + <object class="NSMutableDictionary" key="IBDocument.PluginDeclaredDevelopmentDependencies"> + <string key="NS.key.0">com.apple.InterfaceBuilder.CocoaTouchPlugin.InterfaceBuilder3</string> + <integer value="3000" key="NS.object.0"/> + </object> + <bool key="IBDocument.PluginDeclaredDependenciesTrackSystemTargetVersion">YES</bool> + <nil key="IBDocument.LastKnownRelativeProjectPath"/> + <int key="IBDocument.defaultPropertyAccessControl">3</int> + <string key="IBCocoaTouchPluginVersion">3.1</string> + </data> +</archive> +]]> + </File> + </Files> + </Project> + </Combine> +</Template> diff --git a/extras/MonoDevelop.IPhone/MonoDevelop.IPhone/Templates/IPhoneUtilityProject.xpt.xml b/extras/MonoDevelop.IPhone/MonoDevelop.IPhone/Templates/IPhoneUtilityProject.xpt.xml new file mode 100644 index 0000000000..d688b5c4be --- /dev/null +++ b/extras/MonoDevelop.IPhone/MonoDevelop.IPhone/Templates/IPhoneUtilityProject.xpt.xml @@ -0,0 +1,1015 @@ +<?xml version="1.0"?> +<Template originator="Michael Hutchinson" + created="2009/06/08"> + + <!-- Template Header --> + <TemplateConfiguration> + <_Name>iPhone Utility Project</_Name> + <_Category>C#/iPhone</_Category> + <Icon>md-project-iphone</Icon> + <LanguageName>C#</LanguageName> + <_Description>Utility project for iPhone and iPod Touch.</_Description> + </TemplateConfiguration> + + <!-- Actions --> + <Actions> + </Actions> + + <!-- Template Content --> + <Combine name = "${ProjectName}" directory = "."> + <Options> + <StartupProject>${ProjectName}</StartupProject> + </Options> + + <Project name = "${ProjectName}" directory = "." type = "IPhone"> + <Options MainNibFile="MainWindow.nib" /> + <References> + <Reference type="Gac" refto="System, Version=2.0.5.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e" /> + <Reference type="Gac" refto="System.Xml, Version=2.0.5.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e" /> + <Reference type="Gac" refto="System.Core, Version=2.0.5.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e" /> + <Reference type="Gac" refto="monotouch" /> + </References> + <Files> + <File name="Main.cs"> +<![CDATA[ +using System; +using System.Collections.Generic; +using System.Linq; +using MonoTouch.Foundation; +using MonoTouch.UIKit; + +namespace ${Namespace} +{ + public class Application + { + static void Main (string[] args) + { + UIApplication.Main (args); + } + } + + // The name AppDelegate is referenced in the MainWindow.xib file. + public partial class AppDelegate : UIApplicationDelegate + { + MainViewController mainViewController; + + // This method is invoked when the application has loaded its UI and its ready to run + public override bool FinishedLaunching (UIApplication app, NSDictionary options) + { + mainViewController = new MainViewController ("MainView", null); + mainViewController.View.Frame = UIScreen.MainScreen.ApplicationFrame; + window.AddSubview (mainViewController.View); + window.MakeKeyAndVisible (); + + return true; + } + + // This method is required in iPhoneOS 3.0 + public override void OnActivated (UIApplication application) + { + } + } +} +]]> + </File> + <File name="MainWindow.xib.designer.cs" + DependsOn="MainWindow.xib" + SuppressAutoOpen="True" + ShowAutogenerationNotice="True" + AddStandardHeader="False"> +<![CDATA[ +namespace ${Namespace} { + + // Base type probably should be MonoTouch.Foundation.NSObject or subclass + [MonoTouch.Foundation.Register("AppDelegate")] + public partial class AppDelegate { + + #pragma warning disable 0169 + [MonoTouch.Foundation.Connect("window")] + private MonoTouch.UIKit.UIWindow window { + get { + return ((MonoTouch.UIKit.UIWindow)(this.GetNativeField("window"))); + } + set { + this.SetNativeField("window", value); + } + } + } +} +]]> + </File> + <File name="MainWindow.xib" + SuppressAutoOpen="True"> +<![CDATA[ +<?xml version="1.0" encoding="UTF-8"?> +<archive type="com.apple.InterfaceBuilder3.CocoaTouch.XIB" version="7.10"> + <data> + <int key="IBDocument.SystemTarget">784</int> + <string key="IBDocument.SystemVersion">10C540</string> + <string key="IBDocument.InterfaceBuilderVersion">740</string> + <string key="IBDocument.AppKitVersion">1038.25</string> + <string key="IBDocument.HIToolboxVersion">458.00</string> + <object class="NSMutableDictionary" key="IBDocument.PluginVersions"> + <string key="NS.key.0">com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string> + <string key="NS.object.0">62</string> + </object> + <object class="NSMutableArray" key="IBDocument.EditedObjectIDs"> + <bool key="EncodedWithXMLCoder">YES</bool> + <integer value="2"/> + </object> + <object class="NSArray" key="IBDocument.PluginDependencies"> + <bool key="EncodedWithXMLCoder">YES</bool> + <string>com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string> + </object> + <object class="NSMutableDictionary" key="IBDocument.Metadata"> + <bool key="EncodedWithXMLCoder">YES</bool> + <object class="NSArray" key="dict.sortedKeys" id="0"> + <bool key="EncodedWithXMLCoder">YES</bool> + </object> + <object class="NSMutableArray" key="dict.values"> + <bool key="EncodedWithXMLCoder">YES</bool> + </object> + </object> + <object class="NSMutableArray" key="IBDocument.RootObjects" id="1000"> + <bool key="EncodedWithXMLCoder">YES</bool> + <object class="IBProxyObject" id="841351856"> + <string key="IBProxiedObjectIdentifier">IBFilesOwner</string> + </object> + <object class="IBProxyObject" id="71653367"> + <string key="IBProxiedObjectIdentifier">IBFirstResponder</string> + </object> + <object class="IBUICustomObject" id="664661524"/> + <object class="IBUIWindow" id="380026005"> + <reference key="NSNextResponder"/> + <int key="NSvFlags">1316</int> + <object class="NSPSMatrix" key="NSFrameMatrix"/> + <string key="NSFrameSize">{320, 480}</string> + <reference key="NSSuperview"/> + <object class="NSColor" key="IBUIBackgroundColor"> + <int key="NSColorSpace">1</int> + <bytes key="NSRGB">MCAwIDAAA</bytes> + </object> + <bool key="IBUIClearsContextBeforeDrawing">NO</bool> + <bool key="IBUIMultipleTouchEnabled">YES</bool> + <object class="IBUISimulatedStatusBarMetrics" key="IBUISimulatedStatusBarMetrics"/> + </object> + </object> + <object class="IBObjectContainer" key="IBDocument.Objects"> + <object class="NSMutableArray" key="connectionRecords"> + <bool key="EncodedWithXMLCoder">YES</bool> + <object class="IBConnectionRecord"> + <object class="IBCocoaTouchOutletConnection" key="connection"> + <string key="label">delegate</string> + <reference key="source" ref="841351856"/> + <reference key="destination" ref="664661524"/> + </object> + <int key="connectionID">4</int> + </object> + <object class="IBConnectionRecord"> + <object class="IBCocoaTouchOutletConnection" key="connection"> + <string key="label">window</string> + <reference key="source" ref="664661524"/> + <reference key="destination" ref="380026005"/> + </object> + <int key="connectionID">5</int> + </object> + </object> + <object class="IBMutableOrderedSet" key="objectRecords"> + <object class="NSArray" key="orderedObjects"> + <bool key="EncodedWithXMLCoder">YES</bool> + <object class="IBObjectRecord"> + <int key="objectID">0</int> + <reference key="object" ref="0"/> + <reference key="children" ref="1000"/> + <nil key="parent"/> + </object> + <object class="IBObjectRecord"> + <int key="objectID">2</int> + <reference key="object" ref="380026005"/> + <object class="NSMutableArray" key="children"> + <bool key="EncodedWithXMLCoder">YES</bool> + </object> + <reference key="parent" ref="0"/> + </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">3</int> + <reference key="object" ref="664661524"/> + <reference key="parent" ref="0"/> + </object> + <object class="IBObjectRecord"> + <int key="objectID">-2</int> + <reference key="object" ref="71653367"/> + <reference key="parent" ref="0"/> + </object> + </object> + </object> + <object class="NSMutableDictionary" key="flattenedProperties"> + <bool key="EncodedWithXMLCoder">YES</bool> + <object class="NSArray" key="dict.sortedKeys"> + <bool key="EncodedWithXMLCoder">YES</bool> + <string>-1.CustomClassName</string> + <string>-2.CustomClassName</string> + <string>2.IBAttributePlaceholdersKey</string> + <string>2.IBEditorWindowLastContentRect</string> + <string>2.IBPluginDependency</string> + <string>3.CustomClassName</string> + <string>3.IBPluginDependency</string> + </object> + <object class="NSMutableArray" key="dict.values"> + <bool key="EncodedWithXMLCoder">YES</bool> + <string>UIApplication</string> + <string>UIResponder</string> + <object class="NSMutableDictionary"> + <bool key="EncodedWithXMLCoder">YES</bool> + <reference key="dict.sortedKeys" ref="0"/> + <object class="NSMutableArray" key="dict.values"> + <bool key="EncodedWithXMLCoder">YES</bool> + </object> + </object> + <string>{{733, 276}, {320, 480}}</string> + <string>com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string> + <string>AppDelegate</string> + <string>com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string> + </object> + </object> + <object class="NSMutableDictionary" key="unlocalizedProperties"> + <bool key="EncodedWithXMLCoder">YES</bool> + <reference key="dict.sortedKeys" ref="0"/> + <object class="NSMutableArray" key="dict.values"> + <bool key="EncodedWithXMLCoder">YES</bool> + </object> + </object> + <nil key="activeLocalization"/> + <object class="NSMutableDictionary" key="localizations"> + <bool key="EncodedWithXMLCoder">YES</bool> + <reference key="dict.sortedKeys" ref="0"/> + <object class="NSMutableArray" key="dict.values"> + <bool key="EncodedWithXMLCoder">YES</bool> + </object> + </object> + <nil key="sourceID"/> + <int key="maxID">21</int> + </object> + <object class="IBClassDescriber" key="IBDocument.Classes"> + <object class="NSMutableArray" key="referencedPartialClassDescriptions"> + <bool key="EncodedWithXMLCoder">YES</bool> + <object class="IBPartialClassDescription"> + <string key="className">AppDelegate</string> + <string key="superclassName">NSObject</string> + <object class="NSMutableDictionary" key="outlets"> + <string key="NS.key.0">window</string> + <string key="NS.object.0">UIWindow</string> + </object> + <object class="IBClassDescriptionSource" key="sourceIdentifier"> + <string key="majorKey">IBUserSource</string> + <string key="minorKey"></string> + </object> + </object> + </object> + </object> + <int key="IBDocument.localizationMode">0</int> + <object class="NSMutableDictionary" key="IBDocument.PluginDeclaredDevelopmentDependencies"> + <string key="NS.key.0">com.apple.InterfaceBuilder.CocoaTouchPlugin.InterfaceBuilder3</string> + <integer value="3100" key="NS.object.0"/> + </object> + <bool key="IBDocument.PluginDeclaredDependenciesTrackSystemTargetVersion">YES</bool> + <string key="IBDocument.LastKnownRelativeProjectPath">Utility.xcodeproj</string> + <int key="IBDocument.defaultPropertyAccessControl">3</int> + <string key="IBCocoaTouchPluginVersion">3.1</string> + </data> +</archive> +]]> + </File> + <File name="MainView.xib" + SuppressAutoOpen="True"> +<![CDATA[ +<?xml version="1.0" encoding="UTF-8"?> +<archive type="com.apple.InterfaceBuilder3.CocoaTouch.XIB" version="7.10"> + <data> + <int key="IBDocument.SystemTarget">784</int> + <string key="IBDocument.SystemVersion">10A394</string> + <string key="IBDocument.InterfaceBuilderVersion">732</string> + <string key="IBDocument.AppKitVersion">1027.1</string> + <string key="IBDocument.HIToolboxVersion">430.00</string> + <object class="NSMutableDictionary" key="IBDocument.PluginVersions"> + <string key="NS.key.0">com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string> + <string key="NS.object.0">60</string> + </object> + <object class="NSMutableArray" key="IBDocument.EditedObjectIDs"> + <bool key="EncodedWithXMLCoder">YES</bool> + <integer value="34"/> + </object> + <object class="NSArray" key="IBDocument.PluginDependencies"> + <bool key="EncodedWithXMLCoder">YES</bool> + <string>com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string> + </object> + <object class="NSMutableDictionary" key="IBDocument.Metadata"> + <bool key="EncodedWithXMLCoder">YES</bool> + <object class="NSArray" key="dict.sortedKeys" id="0"> + <bool key="EncodedWithXMLCoder">YES</bool> + </object> + <object class="NSMutableArray" key="dict.values"> + <bool key="EncodedWithXMLCoder">YES</bool> + </object> + </object> + <object class="NSMutableArray" key="IBDocument.RootObjects" id="1000"> + <bool key="EncodedWithXMLCoder">YES</bool> + <object class="IBProxyObject" id="372490531"> + <string key="IBProxiedObjectIdentifier">IBFilesOwner</string> + </object> + <object class="IBProxyObject" id="815241450"> + <string key="IBProxiedObjectIdentifier">IBFirstResponder</string> + </object> + <object class="IBUIView" id="883825266"> + <reference key="NSNextResponder"/> + <int key="NSvFlags">274</int> + <object class="NSMutableArray" key="NSSubviews"> + <bool key="EncodedWithXMLCoder">YES</bool> + <object class="IBUIButton" id="558454645"> + <reference key="NSNextResponder" ref="883825266"/> + <int key="NSvFlags">292</int> + <string key="NSFrame">{{282, 421}, {18, 19}}</string> + <reference key="NSSuperview" ref="883825266"/> + <bool key="IBUIOpaque">NO</bool> + <bool key="IBUIClearsContextBeforeDrawing">NO</bool> + <int key="IBUIContentHorizontalAlignment">0</int> + <int key="IBUIContentVerticalAlignment">0</int> + <object class="NSFont" key="IBUIFont"> + <string key="NSName">Helvetica-Bold</string> + <double key="NSSize">15</double> + <int key="NSfFlags">16</int> + </object> + <int key="IBUIButtonType">3</int> + <bool key="IBUIShowsTouchWhenHighlighted">YES</bool> + <object class="NSColor" key="IBUIHighlightedTitleColor"> + <int key="NSColorSpace">1</int> + <bytes key="NSRGB">MSAxIDEAA</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">MAA</bytes> + </object> + </object> + </object> + <string key="NSFrameSize">{320, 460}</string> + <reference key="NSSuperview"/> + <object class="NSColor" key="IBUIBackgroundColor"> + <int key="NSColorSpace">3</int> + <bytes key="NSWhite">MC4yNQA</bytes> + <object class="NSColorSpace" key="NSCustomColorSpace"> + <int key="NSID">2</int> + </object> + </object> + <bool key="IBUIClearsContextBeforeDrawing">NO</bool> + <object class="IBUISimulatedStatusBarMetrics" key="IBUISimulatedStatusBarMetrics"/> + </object> + </object> + <object class="IBObjectContainer" key="IBDocument.Objects"> + <object class="NSMutableArray" key="connectionRecords"> + <bool key="EncodedWithXMLCoder">YES</bool> + <object class="IBConnectionRecord"> + <object class="IBCocoaTouchOutletConnection" key="connection"> + <string key="label">view</string> + <reference key="source" ref="372490531"/> + <reference key="destination" ref="883825266"/> + </object> + <int key="connectionID">35</int> + </object> + <object class="IBConnectionRecord"> + <object class="IBCocoaTouchEventConnection" key="connection"> + <string key="label">showInfo</string> + <reference key="source" ref="558454645"/> + <reference key="destination" ref="372490531"/> + <int key="IBEventType">7</int> + </object> + <int key="connectionID">37</int> + </object> + </object> + <object class="IBMutableOrderedSet" key="objectRecords"> + <object class="NSArray" key="orderedObjects"> + <bool key="EncodedWithXMLCoder">YES</bool> + <object class="IBObjectRecord"> + <int key="objectID">0</int> + <reference key="object" ref="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="815241450"/> + <reference key="parent" ref="0"/> + </object> + <object class="IBObjectRecord"> + <int key="objectID">34</int> + <reference key="object" ref="883825266"/> + <object class="NSMutableArray" key="children"> + <bool key="EncodedWithXMLCoder">YES</bool> + <reference ref="558454645"/> + </object> + <reference key="parent" ref="0"/> + </object> + <object class="IBObjectRecord"> + <int key="objectID">36</int> + <reference key="object" ref="558454645"/> + <reference key="parent" ref="883825266"/> + </object> + </object> + </object> + <object class="NSMutableDictionary" key="flattenedProperties"> + <bool key="EncodedWithXMLCoder">YES</bool> + <object class="NSArray" key="dict.sortedKeys"> + <bool key="EncodedWithXMLCoder">YES</bool> + <string>-1.CustomClassName</string> + <string>-2.CustomClassName</string> + <string>34.CustomClassName</string> + <string>34.IBEditorWindowLastContentRect</string> + <string>34.IBPluginDependency</string> + <string>36.IBPluginDependency</string> + </object> + <object class="NSMutableArray" key="dict.values"> + <bool key="EncodedWithXMLCoder">YES</bool> + <string>MainViewController</string> + <string>UIResponder</string> + <string>MainView</string> + <string>{{733, 526}, {320, 480}}</string> + <string>com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string> + <string>com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string> + </object> + </object> + <object class="NSMutableDictionary" key="unlocalizedProperties"> + <bool key="EncodedWithXMLCoder">YES</bool> + <reference key="dict.sortedKeys" ref="0"/> + <object class="NSMutableArray" key="dict.values"> + <bool key="EncodedWithXMLCoder">YES</bool> + </object> + </object> + <nil key="activeLocalization"/> + <object class="NSMutableDictionary" key="localizations"> + <bool key="EncodedWithXMLCoder">YES</bool> + <reference key="dict.sortedKeys" ref="0"/> + <object class="NSMutableArray" key="dict.values"> + <bool key="EncodedWithXMLCoder">YES</bool> + </object> + </object> + <nil key="sourceID"/> + <int key="maxID">37</int> + </object> + <object class="IBClassDescriber" key="IBDocument.Classes"> + <object class="NSMutableArray" key="referencedPartialClassDescriptions"> + <bool key="EncodedWithXMLCoder">YES</bool> + <object class="IBPartialClassDescription"> + <string key="className">MainView</string> + <string key="superclassName">UIView</string> + <object class="IBClassDescriptionSource" key="sourceIdentifier"> + <string key="majorKey">IBUserSource</string> + <string key="minorKey"></string> + </object> + </object> + <object class="IBPartialClassDescription"> + <string key="className">MainViewController</string> + <string key="superclassName">UIViewController</string> + <object class="NSMutableDictionary" key="actions"> + <string key="NS.key.0">showInfo</string> + <string key="NS.object.0">id</string> + </object> + <object class="IBClassDescriptionSource" key="sourceIdentifier"> + <string key="majorKey">IBUserSource</string> + <string key="minorKey"></string> + </object> + </object> + </object> + </object> + <int key="IBDocument.localizationMode">0</int> + <object class="NSMutableDictionary" key="IBDocument.PluginDeclaredDevelopmentDependencies"> + <string key="NS.key.0">com.apple.InterfaceBuilder.CocoaTouchPlugin.InterfaceBuilder3</string> + <integer value="3100" key="NS.object.0"/> + </object> + <bool key="IBDocument.PluginDeclaredDependenciesTrackSystemTargetVersion">YES</bool> + <string key="IBDocument.LastKnownRelativeProjectPath">Utility.xcodeproj</string> + <int key="IBDocument.defaultPropertyAccessControl">3</int> + <string key="IBCocoaTouchPluginVersion">3.1</string> + </data> +</archive> +]]> + </File> + <File name="MainViewController.cs" + SuppressAutoOpen="True" + DependsOn="MainView.xib"> +<![CDATA[ +using MonoTouch.UIKit; +using System.Drawing; +using MonoTouch.Foundation; +using System; + +namespace ${Namespace} +{ + public partial class MainViewController : UIViewController + { + + public MainViewController (string nibName, NSBundle bundle) : base (nibName, bundle) + { + // Custom initialization + } + + /* + // Implement viewDidLoad to do additional setup after loading the view, typically from a nib. + public override void ViewDidLoad () + { + base.ViewDidLoad (); + } + */ + + partial void showInfo (UIButton sender) + { + var controller = new FlipsideViewController ("FlipsideView", null); + controller.Done += delegate { + this.DismissModalViewControllerAnimated (true); + }; + controller.ModalTransitionStyle = UIModalTransitionStyle.FlipHorizontal; + this.PresentModalViewController (controller, true); + } + + + /* + // Override to allow orientations other than the default portrait orientation. + public override bool ShouldAutorotateToInterfaceOrientation (UIInterfaceOrientation toInterfaceOrientation) + { + // Return true for supported orientations + return (InterfaceOrientation == UIInterfaceOrientation.Portrait); + } + */ + + public override void DidReceiveMemoryWarning () + { + // Releases the view if it doesn't have a superview. + base.DidReceiveMemoryWarning (); + + // Release any cached data, images, etc that aren't in use. + } + + public override void ViewDidUnload () + { + // Release any retained subviews of the main view. + // e.g. this.myOutlet = null; + } + } +} +]]> + </File> + <File name="MainView.cs" + SuppressAutoOpen="True" + DependsOn="MainView.xib"> +<![CDATA[ +using MonoTouch.UIKit; +using System.Drawing; +using MonoTouch.Foundation; +using System; + +namespace ${Namespace} +{ + public partial class MainView : UIView + { + public MainView (IntPtr handle) : base (handle) + { + } + + public override void Draw (RectangleF rect) + { + //Drawing code + } + } +} +]]> + </File> + <File name="MainView.xib.designer.cs" + DependsOn="MainView.xib" + SuppressAutoOpen="True" + ShowAutogenerationNotice="True" + AddStandardHeader="False"> +<![CDATA[ +namespace ${Namespace} { + + // Base type probably should be MonoTouch.UIKit.UIViewController or subclass + [MonoTouch.Foundation.Register("MainViewController")] + public partial class MainViewController { + + #pragma warning disable 0169 + [MonoTouch.Foundation.Export("showInfo")] + partial void showInfo (MonoTouch.UIKit.UIButton sender); + + [MonoTouch.Foundation.Connect("view")] + private MainView view { + get { + return ((MainView)(this.GetNativeField("view"))); + } + set { + this.SetNativeField("view", value); + } + } + } + + // Base type probably should be MonoTouch.UIKit.UIView or subclass + [MonoTouch.Foundation.Register("MainView")] + public partial class MainView { + } +} +]]> + </File> + <File name="FlipsideView.xib" + SuppressAutoOpen="True"> +<![CDATA[ +<?xml version="1.0" encoding="UTF-8"?> +<archive type="com.apple.InterfaceBuilder3.CocoaTouch.XIB" version="7.10"> + <data> + <int key="IBDocument.SystemTarget">784</int> + <string key="IBDocument.SystemVersion">10C540</string> + <string key="IBDocument.InterfaceBuilderVersion">740</string> + <string key="IBDocument.AppKitVersion">1038.25</string> + <string key="IBDocument.HIToolboxVersion">458.00</string> + <object class="NSMutableDictionary" key="IBDocument.PluginVersions"> + <string key="NS.key.0">com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string> + <string key="NS.object.0">62</string> + </object> + <object class="NSMutableArray" key="IBDocument.EditedObjectIDs"> + <bool key="EncodedWithXMLCoder">YES</bool> + <integer value="40"/> + </object> + <object class="NSArray" key="IBDocument.PluginDependencies"> + <bool key="EncodedWithXMLCoder">YES</bool> + <string>com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string> + </object> + <object class="NSMutableDictionary" key="IBDocument.Metadata"> + <bool key="EncodedWithXMLCoder">YES</bool> + <object class="NSArray" key="dict.sortedKeys" id="0"> + <bool key="EncodedWithXMLCoder">YES</bool> + </object> + <object class="NSMutableArray" key="dict.values"> + <bool key="EncodedWithXMLCoder">YES</bool> + </object> + </object> + <object class="NSMutableArray" key="IBDocument.RootObjects" id="1000"> + <bool key="EncodedWithXMLCoder">YES</bool> + <object class="IBProxyObject" id="372490531"> + <string key="IBProxiedObjectIdentifier">IBFilesOwner</string> + </object> + <object class="IBProxyObject" id="340535442"> + <string key="IBProxiedObjectIdentifier">IBFirstResponder</string> + </object> + <object class="IBUIView" id="249263867"> + <reference key="NSNextResponder"/> + <int key="NSvFlags">274</int> + <object class="NSMutableArray" key="NSSubviews"> + <bool key="EncodedWithXMLCoder">YES</bool> + <object class="IBUINavigationBar" id="871675769"> + <reference key="NSNextResponder" ref="249263867"/> + <int key="NSvFlags">290</int> + <string key="NSFrameSize">{320, 44}</string> + <reference key="NSSuperview" ref="249263867"/> + <bool key="IBUIOpaque">NO</bool> + <bool key="IBUIClearsContextBeforeDrawing">NO</bool> + <int key="IBUIBarStyle">1</int> + <object class="NSArray" key="IBUIItems"> + <bool key="EncodedWithXMLCoder">YES</bool> + <object class="IBUINavigationItem" id="553200710"> + <reference key="IBUINavigationBar" ref="871675769"/> + <string key="IBUITitle">Title</string> + <object class="IBUIBarButtonItem" key="IBUILeftBarButtonItem" id="854562692"> + <int key="IBUIStyle">1</int> + <int key="IBUISystemItemIdentifier">0</int> + </object> + </object> + </object> + </object> + </object> + <string key="NSFrameSize">{320, 460}</string> + <reference key="NSSuperview"/> + <object class="NSColor" key="IBUIBackgroundColor"> + <int key="NSColorSpace">3</int> + <bytes key="NSWhite">MC4yNQA</bytes> + <object class="NSColorSpace" key="NSCustomColorSpace"> + <int key="NSID">2</int> + </object> + </object> + <bool key="IBUIClearsContextBeforeDrawing">NO</bool> + <object class="IBUISimulatedStatusBarMetrics" key="IBUISimulatedStatusBarMetrics"> + <int key="IBUIStatusBarStyle">2</int> + </object> + </object> + </object> + <object class="IBObjectContainer" key="IBDocument.Objects"> + <object class="NSMutableArray" key="connectionRecords"> + <bool key="EncodedWithXMLCoder">YES</bool> + <object class="IBConnectionRecord"> + <object class="IBCocoaTouchEventConnection" key="connection"> + <string key="label">done</string> + <reference key="source" ref="854562692"/> + <reference key="destination" ref="372490531"/> + </object> + <int key="connectionID">45</int> + </object> + <object class="IBConnectionRecord"> + <object class="IBCocoaTouchOutletConnection" key="connection"> + <string key="label">view</string> + <reference key="source" ref="372490531"/> + <reference key="destination" ref="249263867"/> + </object> + <int key="connectionID">46</int> + </object> + <object class="IBConnectionRecord"> + <object class="IBCocoaTouchOutletConnection" key="connection"> + <string key="label">view2</string> + <reference key="source" ref="372490531"/> + <reference key="destination" ref="249263867"/> + </object> + <int key="connectionID">47</int> + </object> + </object> + <object class="IBMutableOrderedSet" key="objectRecords"> + <object class="NSArray" key="orderedObjects"> + <bool key="EncodedWithXMLCoder">YES</bool> + <object class="IBObjectRecord"> + <int key="objectID">0</int> + <reference key="object" ref="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="340535442"/> + <reference key="parent" ref="0"/> + </object> + <object class="IBObjectRecord"> + <int key="objectID">40</int> + <reference key="object" ref="249263867"/> + <object class="NSMutableArray" key="children"> + <bool key="EncodedWithXMLCoder">YES</bool> + <reference ref="871675769"/> + </object> + <reference key="parent" ref="0"/> + </object> + <object class="IBObjectRecord"> + <int key="objectID">42</int> + <reference key="object" ref="871675769"/> + <object class="NSMutableArray" key="children"> + <bool key="EncodedWithXMLCoder">YES</bool> + <reference ref="553200710"/> + </object> + <reference key="parent" ref="249263867"/> + </object> + <object class="IBObjectRecord"> + <int key="objectID">43</int> + <reference key="object" ref="553200710"/> + <object class="NSMutableArray" key="children"> + <bool key="EncodedWithXMLCoder">YES</bool> + <reference ref="854562692"/> + </object> + <reference key="parent" ref="871675769"/> + </object> + <object class="IBObjectRecord"> + <int key="objectID">44</int> + <reference key="object" ref="854562692"/> + <reference key="parent" ref="553200710"/> + </object> + </object> + </object> + <object class="NSMutableDictionary" key="flattenedProperties"> + <bool key="EncodedWithXMLCoder">YES</bool> + <object class="NSArray" key="dict.sortedKeys"> + <bool key="EncodedWithXMLCoder">YES</bool> + <string>-1.CustomClassName</string> + <string>-2.CustomClassName</string> + <string>40.CustomClassName</string> + <string>40.IBEditorWindowLastContentRect</string> + <string>40.IBPluginDependency</string> + <string>42.IBPluginDependency</string> + <string>43.IBPluginDependency</string> + <string>44.IBPluginDependency</string> + </object> + <object class="NSMutableArray" key="dict.values"> + <bool key="EncodedWithXMLCoder">YES</bool> + <string>FlipsideViewController</string> + <string>UIResponder</string> + <string>FlipsideView</string> + <string>{{367, 276}, {320, 480}}</string> + <string>com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string> + <string>com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string> + <string>com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string> + <string>com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string> + </object> + </object> + <object class="NSMutableDictionary" key="unlocalizedProperties"> + <bool key="EncodedWithXMLCoder">YES</bool> + <reference key="dict.sortedKeys" ref="0"/> + <object class="NSMutableArray" key="dict.values"> + <bool key="EncodedWithXMLCoder">YES</bool> + </object> + </object> + <nil key="activeLocalization"/> + <object class="NSMutableDictionary" key="localizations"> + <bool key="EncodedWithXMLCoder">YES</bool> + <reference key="dict.sortedKeys" ref="0"/> + <object class="NSMutableArray" key="dict.values"> + <bool key="EncodedWithXMLCoder">YES</bool> + </object> + </object> + <nil key="sourceID"/> + <int key="maxID">47</int> + </object> + <object class="IBClassDescriber" key="IBDocument.Classes"> + <object class="NSMutableArray" key="referencedPartialClassDescriptions"> + <bool key="EncodedWithXMLCoder">YES</bool> + <object class="IBPartialClassDescription"> + <string key="className">FlipsideView</string> + <string key="superclassName">UIView</string> + <object class="IBClassDescriptionSource" key="sourceIdentifier"> + <string key="majorKey">IBUserSource</string> + <string key="minorKey"></string> + </object> + </object> + <object class="IBPartialClassDescription"> + <string key="className">FlipsideViewController</string> + <string key="superclassName">UIViewController</string> + <object class="NSMutableDictionary" key="actions"> + <string key="NS.key.0">done</string> + <string key="NS.object.0">id</string> + </object> + <object class="NSMutableDictionary" key="outlets"> + <string key="NS.key.0">delegate</string> + <string key="NS.object.0">id</string> + </object> + <object class="IBClassDescriptionSource" key="sourceIdentifier"> + <string key="majorKey">IBUserSource</string> + <string key="minorKey"></string> + </object> + </object> + </object> + </object> + <int key="IBDocument.localizationMode">0</int> + <object class="NSMutableDictionary" key="IBDocument.PluginDeclaredDevelopmentDependencies"> + <string key="NS.key.0">com.apple.InterfaceBuilder.CocoaTouchPlugin.InterfaceBuilder3</string> + <integer value="3100" key="NS.object.0"/> + </object> + <bool key="IBDocument.PluginDeclaredDependenciesTrackSystemTargetVersion">YES</bool> + <string key="IBDocument.LastKnownRelativeProjectPath">Utility.xcodeproj</string> + <int key="IBDocument.defaultPropertyAccessControl">3</int> + <string key="IBCocoaTouchPluginVersion">3.1</string> + </data> +</archive> +]]> + </File> + <File name="FlipsideViewController.cs" + SuppressAutoOpen="True" + DependsOn="FlipsideView.xib"> +<![CDATA[ +using MonoTouch.UIKit; +using System.Drawing; +using System; +using MonoTouch.Foundation; + + +namespace ${Namespace} +{ + + public partial class FlipsideViewController : UIViewController + { + public FlipsideViewController (string nibName, NSBundle bundle) : base (nibName, bundle) + { + } + + public override void ViewDidLoad () + { + base.ViewDidLoad (); + View.BackgroundColor = UIColor.ViewFlipsideBackgroundColor; + } + + /* + // Override to allow orientations other than the default portrait orientation. + public override bool ShouldAutorotateToInterfaceOrientation (UIInterfaceOrientation toInterfaceOrientation) + { + // Return true for supported orientations + return (InterfaceOrientation == UIInterfaceOrientation.Portrait); + } + */ + + public override void DidReceiveMemoryWarning () + { + // Releases the view if it doesn't have a superview. + base.DidReceiveMemoryWarning (); + + // Release any cached data, images, etc that aren't in use. + } + + public override void ViewDidUnload () + { + // Release any retained subviews of the main view. + // e.g. this.myOutlet = null; + } + + partial void done (UIBarButtonItem sender) + { + if (Done != null) + Done (this, EventArgs.Empty); + } + + public event EventHandler Done; + } +} +]]> + </File> + <File name="FlipsideView.cs" + SuppressAutoOpen="True" + DependsOn="FlipsideView.xib"> +<![CDATA[ +using MonoTouch.UIKit; +using System.Drawing; +using System; +using MonoTouch.Foundation; + + +namespace ${Namespace} +{ + public partial class FlipsideView : UIView + { + public FlipsideView (IntPtr handle) : base (handle) + { + } + + public override void Draw (RectangleF rect) + { + //Drawing code + } + } +} +]]> + </File> + <File name="FlipsideView.xib.designer.cs" + DependsOn="FlipsideView.xib" + SuppressAutoOpen="True" + ShowAutogenerationNotice="True" + AddStandardHeader="False"> +<![CDATA[ +namespace ${Namespace} { + + + // Base type probably should be MonoTouch.UIKit.UIViewController or subclass + [MonoTouch.Foundation.Register("FlipsideViewController")] + public partial class FlipsideViewController { + + #pragma warning disable 0169 + [MonoTouch.Foundation.Export("done")] + partial void done (MonoTouch.UIKit.UIBarButtonItem sender); + + [MonoTouch.Foundation.Connect("view")] + private FlipsideView view { + get { + return ((FlipsideView)(this.GetNativeField("view"))); + } + set { + this.SetNativeField("view", value); + } + } + + [MonoTouch.Foundation.Connect("view2")] + private FlipsideView view2 { + get { + return ((FlipsideView)(this.GetNativeField("view2"))); + } + set { + this.SetNativeField("view2", value); + } + } + } + + // Base type probably should be MonoTouch.UIKit.UIView or subclass + [MonoTouch.Foundation.Register("FlipsideView")] + public partial class FlipsideView { + } +} +]]> + </File> + </Files> + </Project> + </Combine> +</Template> diff --git a/extras/MonoDevelop.IPhone/MonoDevelop.IPhone/Templates/IPhoneViewController.xft.xml b/extras/MonoDevelop.IPhone/MonoDevelop.IPhone/Templates/IPhoneViewController.xft.xml index b653b2dfbd..6f14754669 100644 --- a/extras/MonoDevelop.IPhone/MonoDevelop.IPhone/Templates/IPhoneViewController.xft.xml +++ b/extras/MonoDevelop.IPhone/MonoDevelop.IPhone/Templates/IPhoneViewController.xft.xml @@ -31,7 +31,7 @@ namespace ${Namespace} { #region Constructors - // The IntPtr and NSCoder constructors are required for controllers that need + // The IntPtr and initWithCoder constructors are required for controllers that need // to be able to be created from a xib rather than from managed code public ${Name} (IntPtr handle) : base (handle) diff --git a/extras/MonoDevelop.IPhone/MonoDevelop.IPhone/Templates/IPhoneViewXib.xft.xml b/extras/MonoDevelop.IPhone/MonoDevelop.IPhone/Templates/IPhoneViewXib.xft.xml index e04dd3cd4d..53d75ff721 100644 --- a/extras/MonoDevelop.IPhone/MonoDevelop.IPhone/Templates/IPhoneViewXib.xft.xml +++ b/extras/MonoDevelop.IPhone/MonoDevelop.IPhone/Templates/IPhoneViewXib.xft.xml @@ -18,7 +18,7 @@ <!-- Template Content --> <TemplateFiles> - <File name="${Name}.xib.${LanguageExtension}" DependsOn="${Name}.xib" ><![CDATA[ + <File name="${Name}.xib.cs" DependsOn="${Name}.xib" ><![CDATA[ using System; using System.Collections.Generic; using System.Linq; @@ -30,7 +30,7 @@ namespace ${Namespace} } ]]></File> - <File name="${Name}.xib.designer.${LanguageExtension}" ShowAutogenerationNotice="True" + <File name="${Name}.xib.designer.cs" ShowAutogenerationNotice="True" AddStandardHeader="False" SuppressAutoOpen="True" DependsOn="${Name}.xib" ><![CDATA[ namespace ${Namespace} { diff --git a/extras/MonoDevelop.IPhone/MonoDevelop.IPhone/Templates/IPhoneProject.xpt.xml b/extras/MonoDevelop.IPhone/MonoDevelop.IPhone/Templates/IPhoneWindowBasedProject.xpt.xml index b96afec652..84da246be2 100644 --- a/extras/MonoDevelop.IPhone/MonoDevelop.IPhone/Templates/IPhoneProject.xpt.xml +++ b/extras/MonoDevelop.IPhone/MonoDevelop.IPhone/Templates/IPhoneWindowBasedProject.xpt.xml @@ -4,11 +4,11 @@ <!-- Template Header --> <TemplateConfiguration> - <_Name>iPhone MonoTouch Project</_Name> + <_Name>iPhone Window-based Project</_Name> <_Category>C#/iPhone</_Category> <Icon>md-project-iphone</Icon> <LanguageName>C#</LanguageName> - <_Description>Creates a MonoTouch project for for iPhone and iPod Touch.</_Description> + <_Description>Window-based project for iPhone and iPod Touch.</_Description> </TemplateConfiguration> <!-- Actions --> |