From 014ffb08be328f3325272f764c6e40dc4305f0cd Mon Sep 17 00:00:00 2001 From: Ian C Date: Fri, 4 Sep 2020 21:23:37 +0000 Subject: Skeleton for Cocoa app. --- R2D2/AppDelegate.cs | 39 ++ .../AppIcon.appiconset/AppIcon-128.png | Bin 0 -> 8125 bytes .../AppIcon.appiconset/AppIcon-128@2x.png | Bin 0 -> 20798 bytes .../AppIcon.appiconset/AppIcon-16.png | Bin 0 -> 711 bytes .../AppIcon.appiconset/AppIcon-16@2x.png | Bin 0 -> 1484 bytes .../AppIcon.appiconset/AppIcon-256.png | Bin 0 -> 20798 bytes .../AppIcon.appiconset/AppIcon-256@2x.png | Bin 0 -> 59335 bytes .../AppIcon.appiconset/AppIcon-32.png | Bin 0 -> 1484 bytes .../AppIcon.appiconset/AppIcon-32@2x.png | Bin 0 -> 3428 bytes .../AppIcon.appiconset/AppIcon-512.png | Bin 0 -> 59335 bytes .../AppIcon.appiconset/AppIcon-512@2x.png | Bin 0 -> 177632 bytes .../AppIcon.appiconset/Contents.json | 68 ++ R2D2/Assets.xcassets/Contents.json | 6 + R2D2/Entitlements.plist | 6 + R2D2/Info.plist | 33 + R2D2/Main.cs | 29 + R2D2/Main.storyboard | 717 +++++++++++++++++++++ R2D2/R2D2.csproj | 84 +++ R2D2/ViewController.cs | 50 ++ R2D2/ViewController.designer.cs | 18 + 20 files changed, 1050 insertions(+) create mode 100644 R2D2/AppDelegate.cs create mode 100644 R2D2/Assets.xcassets/AppIcon.appiconset/AppIcon-128.png create mode 100644 R2D2/Assets.xcassets/AppIcon.appiconset/AppIcon-128@2x.png create mode 100644 R2D2/Assets.xcassets/AppIcon.appiconset/AppIcon-16.png create mode 100644 R2D2/Assets.xcassets/AppIcon.appiconset/AppIcon-16@2x.png create mode 100644 R2D2/Assets.xcassets/AppIcon.appiconset/AppIcon-256.png create mode 100644 R2D2/Assets.xcassets/AppIcon.appiconset/AppIcon-256@2x.png create mode 100644 R2D2/Assets.xcassets/AppIcon.appiconset/AppIcon-32.png create mode 100644 R2D2/Assets.xcassets/AppIcon.appiconset/AppIcon-32@2x.png create mode 100644 R2D2/Assets.xcassets/AppIcon.appiconset/AppIcon-512.png create mode 100644 R2D2/Assets.xcassets/AppIcon.appiconset/AppIcon-512@2x.png create mode 100644 R2D2/Assets.xcassets/AppIcon.appiconset/Contents.json create mode 100644 R2D2/Assets.xcassets/Contents.json create mode 100644 R2D2/Entitlements.plist create mode 100644 R2D2/Info.plist create mode 100644 R2D2/Main.cs create mode 100644 R2D2/Main.storyboard create mode 100644 R2D2/R2D2.csproj create mode 100644 R2D2/ViewController.cs create mode 100644 R2D2/ViewController.designer.cs (limited to 'R2D2') diff --git a/R2D2/AppDelegate.cs b/R2D2/AppDelegate.cs new file mode 100644 index 0000000..39aeba9 --- /dev/null +++ b/R2D2/AppDelegate.cs @@ -0,0 +1,39 @@ +// R2D2 - Simple driver for Sphero R2D2 +// Copyright 2020 Ian Cowburn +// +// This program is free software: you can redistribute it and/or modify +// it under the terms of the GNU General Public License as published by +// the Free Software Foundation, either version 3 of the License, or +// (at your option) any later version. +// +// This program is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. +// +// You should have received a copy of the GNU General Public License +// along with this program. If not, see . +// +using AppKit; +using Foundation; + +namespace R2D2 +{ + [Register("AppDelegate")] + public class AppDelegate : NSApplicationDelegate + { + public AppDelegate() + { + } + + public override void DidFinishLaunching(NSNotification notification) + { + // Insert code here to initialize your application + } + + public override void WillTerminate(NSNotification notification) + { + // Insert code here to tear down your application + } + } +} diff --git a/R2D2/Assets.xcassets/AppIcon.appiconset/AppIcon-128.png b/R2D2/Assets.xcassets/AppIcon.appiconset/AppIcon-128.png new file mode 100644 index 0000000..d0b5a80 Binary files /dev/null and b/R2D2/Assets.xcassets/AppIcon.appiconset/AppIcon-128.png differ diff --git a/R2D2/Assets.xcassets/AppIcon.appiconset/AppIcon-128@2x.png b/R2D2/Assets.xcassets/AppIcon.appiconset/AppIcon-128@2x.png new file mode 100644 index 0000000..f4c8d29 Binary files /dev/null and b/R2D2/Assets.xcassets/AppIcon.appiconset/AppIcon-128@2x.png differ diff --git a/R2D2/Assets.xcassets/AppIcon.appiconset/AppIcon-16.png b/R2D2/Assets.xcassets/AppIcon.appiconset/AppIcon-16.png new file mode 100644 index 0000000..ebb5a0f Binary files /dev/null and b/R2D2/Assets.xcassets/AppIcon.appiconset/AppIcon-16.png differ diff --git a/R2D2/Assets.xcassets/AppIcon.appiconset/AppIcon-16@2x.png b/R2D2/Assets.xcassets/AppIcon.appiconset/AppIcon-16@2x.png new file mode 100644 index 0000000..0986d31 Binary files /dev/null and b/R2D2/Assets.xcassets/AppIcon.appiconset/AppIcon-16@2x.png differ diff --git a/R2D2/Assets.xcassets/AppIcon.appiconset/AppIcon-256.png b/R2D2/Assets.xcassets/AppIcon.appiconset/AppIcon-256.png new file mode 100644 index 0000000..f4c8d29 Binary files /dev/null and b/R2D2/Assets.xcassets/AppIcon.appiconset/AppIcon-256.png differ diff --git a/R2D2/Assets.xcassets/AppIcon.appiconset/AppIcon-256@2x.png b/R2D2/Assets.xcassets/AppIcon.appiconset/AppIcon-256@2x.png new file mode 100644 index 0000000..a142c83 Binary files /dev/null and b/R2D2/Assets.xcassets/AppIcon.appiconset/AppIcon-256@2x.png differ diff --git a/R2D2/Assets.xcassets/AppIcon.appiconset/AppIcon-32.png b/R2D2/Assets.xcassets/AppIcon.appiconset/AppIcon-32.png new file mode 100644 index 0000000..0986d31 Binary files /dev/null and b/R2D2/Assets.xcassets/AppIcon.appiconset/AppIcon-32.png differ diff --git a/R2D2/Assets.xcassets/AppIcon.appiconset/AppIcon-32@2x.png b/R2D2/Assets.xcassets/AppIcon.appiconset/AppIcon-32@2x.png new file mode 100644 index 0000000..412d6ca Binary files /dev/null and b/R2D2/Assets.xcassets/AppIcon.appiconset/AppIcon-32@2x.png differ diff --git a/R2D2/Assets.xcassets/AppIcon.appiconset/AppIcon-512.png b/R2D2/Assets.xcassets/AppIcon.appiconset/AppIcon-512.png new file mode 100644 index 0000000..a142c83 Binary files /dev/null and b/R2D2/Assets.xcassets/AppIcon.appiconset/AppIcon-512.png differ diff --git a/R2D2/Assets.xcassets/AppIcon.appiconset/AppIcon-512@2x.png b/R2D2/Assets.xcassets/AppIcon.appiconset/AppIcon-512@2x.png new file mode 100644 index 0000000..e99022a Binary files /dev/null and b/R2D2/Assets.xcassets/AppIcon.appiconset/AppIcon-512@2x.png differ diff --git a/R2D2/Assets.xcassets/AppIcon.appiconset/Contents.json b/R2D2/Assets.xcassets/AppIcon.appiconset/Contents.json new file mode 100644 index 0000000..6b28545 --- /dev/null +++ b/R2D2/Assets.xcassets/AppIcon.appiconset/Contents.json @@ -0,0 +1,68 @@ +{ + "images": [ + { + "filename": "AppIcon-16.png", + "size": "16x16", + "scale": "1x", + "idiom": "mac" + }, + { + "filename": "AppIcon-16@2x.png", + "size": "16x16", + "scale": "2x", + "idiom": "mac" + }, + { + "filename": "AppIcon-32.png", + "size": "32x32", + "scale": "1x", + "idiom": "mac" + }, + { + "filename": "AppIcon-32@2x.png", + "size": "32x32", + "scale": "2x", + "idiom": "mac" + }, + { + "filename": "AppIcon-128.png", + "size": "128x128", + "scale": "1x", + "idiom": "mac" + }, + { + "filename": "AppIcon-128@2x.png", + "size": "128x128", + "scale": "2x", + "idiom": "mac" + }, + { + "filename": "AppIcon-256.png", + "size": "256x256", + "scale": "1x", + "idiom": "mac" + }, + { + "filename": "AppIcon-256@2x.png", + "size": "256x256", + "scale": "2x", + "idiom": "mac" + }, + { + "filename": "AppIcon-512.png", + "size": "512x512", + "scale": "1x", + "idiom": "mac" + }, + { + "filename": "AppIcon-512@2x.png", + "size": "512x512", + "scale": "2x", + "idiom": "mac" + } + ], + "info": { + "version": 1, + "author": "xcode" + } +} \ No newline at end of file diff --git a/R2D2/Assets.xcassets/Contents.json b/R2D2/Assets.xcassets/Contents.json new file mode 100644 index 0000000..4caf392 --- /dev/null +++ b/R2D2/Assets.xcassets/Contents.json @@ -0,0 +1,6 @@ +{ + "info" : { + "version" : 1, + "author" : "xcode" + } +} \ No newline at end of file diff --git a/R2D2/Entitlements.plist b/R2D2/Entitlements.plist new file mode 100644 index 0000000..9ae5993 --- /dev/null +++ b/R2D2/Entitlements.plist @@ -0,0 +1,6 @@ + + + + + + diff --git a/R2D2/Info.plist b/R2D2/Info.plist new file mode 100644 index 0000000..2586d16 --- /dev/null +++ b/R2D2/Info.plist @@ -0,0 +1,33 @@ + + + + + CFBundleName + R2D2 + CFBundleIdentifier + uk.co.noddybox.R2D2 + CFBundleShortVersionString + 1.0 + CFBundleVersion + 1 + LSMinimumSystemVersion + 10.15 + CFBundleDevelopmentRegion + en + CFBundleInfoDictionaryVersion + 6.0 + CFBundlePackageType + APPL + CFBundleSignature + ???? + NSHumanReadableCopyright + + NSPrincipalClass + NSApplication + NSMainStoryboardFile + Main + XSAppIconAssets + Assets.xcassets/AppIcon.appiconset + + + diff --git a/R2D2/Main.cs b/R2D2/Main.cs new file mode 100644 index 0000000..e2d7112 --- /dev/null +++ b/R2D2/Main.cs @@ -0,0 +1,29 @@ +// R2D2 - Simple driver for Sphero R2D2 +// Copyright 2020 Ian Cowburn +// +// This program is free software: you can redistribute it and/or modify +// it under the terms of the GNU General Public License as published by +// the Free Software Foundation, either version 3 of the License, or +// (at your option) any later version. +// +// This program is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. +// +// You should have received a copy of the GNU General Public License +// along with this program. If not, see . +// +using AppKit; + +namespace R2D2 +{ + static class MainClass + { + static void Main(string[] args) + { + NSApplication.Init(); + NSApplication.Main(args); + } + } +} diff --git a/R2D2/Main.storyboard b/R2D2/Main.storyboard new file mode 100644 index 0000000..5052149 --- /dev/null +++ b/R2D2/Main.storyboard @@ -0,0 +1,717 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + Default + + + + + + + Left to Right + + + + + + + Right to Left + + + + + + + + + + + Default + + + + + + + Left to Right + + + + + + + Right to Left + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/R2D2/R2D2.csproj b/R2D2/R2D2.csproj new file mode 100644 index 0000000..abe2009 --- /dev/null +++ b/R2D2/R2D2.csproj @@ -0,0 +1,84 @@ + + + + Debug + AnyCPU + {F51EB166-4DFB-40EA-9262-BAFF463EEE0A} + {A3F8F2AB-B479-4A4A-A458-A89E7DC349F1};{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC} + Exe + R2D2 + R2D2 + v2.0 + Xamarin.Mac + Resources + + + true + full + false + bin\Debug + DEBUG; + prompt + 4 + false + Mac Developer + false + false + false + true + true + + + pdbonly + true + bin\Release + prompt + 4 + false + true + false + true + true + true + Entitlements.plist + SdkOnly + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + ViewController.cs + + + + + + + \ No newline at end of file diff --git a/R2D2/ViewController.cs b/R2D2/ViewController.cs new file mode 100644 index 0000000..de5674f --- /dev/null +++ b/R2D2/ViewController.cs @@ -0,0 +1,50 @@ +// R2D2 - Simple driver for Sphero R2D2 +// Copyright 2020 Ian Cowburn +// +// This program is free software: you can redistribute it and/or modify +// it under the terms of the GNU General Public License as published by +// the Free Software Foundation, either version 3 of the License, or +// (at your option) any later version. +// +// This program is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. +// +// You should have received a copy of the GNU General Public License +// along with this program. If not, see . +// +using System; + +using AppKit; +using Foundation; + +namespace R2D2 +{ + public partial class ViewController : NSViewController + { + public ViewController(IntPtr handle) : base(handle) + { + } + + public override void ViewDidLoad() + { + base.ViewDidLoad(); + + // Do any additional setup after loading the view. + } + + public override NSObject RepresentedObject + { + get + { + return base.RepresentedObject; + } + set + { + base.RepresentedObject = value; + // Update the view, if already loaded. + } + } + } +} diff --git a/R2D2/ViewController.designer.cs b/R2D2/ViewController.designer.cs new file mode 100644 index 0000000..40a740f --- /dev/null +++ b/R2D2/ViewController.designer.cs @@ -0,0 +1,18 @@ +// WARNING +// +// This file has been generated automatically by Xamarin Studio to store outlets and +// actions made in the UI designer. If it is removed, they will be lost. +// Manual changes to this file may not be handled correctly. +// +using Foundation; + +namespace R2D2 +{ + [Register("ViewController")] + partial class ViewController + { + void ReleaseDesignerOutlets() + { + } + } +} -- cgit v1.2.3