From caa0af1258e592c09757df51dc4770cf5e5c6556 Mon Sep 17 00:00:00 2001 From: Kyle Spearrin Date: Fri, 28 Jun 2019 10:45:42 -0400 Subject: [PATCH] remove old action view controllers --- src/iOS.Autofill/ActionViewController.cs | 71 ------------------- .../ActionViewController.designer.cs | 24 ------- src/iOS.Autofill/iOS.Autofill.csproj | 4 -- src/iOS.Extension/ActionViewController.cs | 71 ------------------- .../ActionViewController.designer.cs | 24 ------- src/iOS.Extension/iOS.Extension.csproj | 4 -- 6 files changed, 198 deletions(-) delete mode 100644 src/iOS.Autofill/ActionViewController.cs delete mode 100644 src/iOS.Autofill/ActionViewController.designer.cs delete mode 100644 src/iOS.Extension/ActionViewController.cs delete mode 100644 src/iOS.Extension/ActionViewController.designer.cs diff --git a/src/iOS.Autofill/ActionViewController.cs b/src/iOS.Autofill/ActionViewController.cs deleted file mode 100644 index f3757fd81..000000000 --- a/src/iOS.Autofill/ActionViewController.cs +++ /dev/null @@ -1,71 +0,0 @@ -using System; - -using MobileCoreServices; -using Foundation; -using UIKit; - -namespace iOS.Autofill -{ - public partial class ActionViewController : UIViewController - { - public ActionViewController(IntPtr handle) : base(handle) - { - } - - 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 ViewDidLoad() - { - base.ViewDidLoad(); - - // Get the item[s] we're handling from the extension context. - - // For example, look for an image and place it into an image view. - // Replace this with something appropriate for the type[s] your extension supports. - bool imageFound = false; - - foreach(var item in ExtensionContext.InputItems) - { - foreach(var itemProvider in item.Attachments) - { - if(itemProvider.HasItemConformingTo(UTType.Image)) - { - // This is an image. We'll load it, then place it in our image view. - itemProvider.LoadItem(UTType.Image, null, delegate (NSObject image, NSError error) - { - if(image != null) - { - NSOperationQueue.MainQueue.AddOperation(delegate - { - imageView.Image = (UIImage)image; - }); - } - }); - - imageFound = true; - break; - } - } - - if(imageFound) - { - // We only handle one image, so stop looking for more. - break; - } - } - } - - partial void DoneClicked(NSObject sender) - { - // Return any edited content to the host app. - // This template doesn't do anything, so we just echo the passed-in items. - ExtensionContext.CompleteRequest(ExtensionContext.InputItems, null); - } - } -} diff --git a/src/iOS.Autofill/ActionViewController.designer.cs b/src/iOS.Autofill/ActionViewController.designer.cs deleted file mode 100644 index 8fb3ffe07..000000000 --- a/src/iOS.Autofill/ActionViewController.designer.cs +++ /dev/null @@ -1,24 +0,0 @@ -// -// This file has been generated automatically to store outlets and -// actions made in the Xcode designer. If it is removed, they will be lost. -// Manual changes to this file may not be handled correctly. -// -using UIKit; -using Foundation; - -namespace iOS.Autofill -{ - [Register("ActionViewController")] - partial class ActionViewController - { - [Outlet] - UIImageView imageView { get; set; } - - [Action("DoneClicked:")] - partial void DoneClicked(NSObject sender); - - void ReleaseDesignerOutlets() - { - } - } -} \ No newline at end of file diff --git a/src/iOS.Autofill/iOS.Autofill.csproj b/src/iOS.Autofill/iOS.Autofill.csproj index 1a9b658b3..13725ecdb 100644 --- a/src/iOS.Autofill/iOS.Autofill.csproj +++ b/src/iOS.Autofill/iOS.Autofill.csproj @@ -99,10 +99,6 @@ - - ActionViewController.cs - - diff --git a/src/iOS.Extension/ActionViewController.cs b/src/iOS.Extension/ActionViewController.cs deleted file mode 100644 index d4c79eeae..000000000 --- a/src/iOS.Extension/ActionViewController.cs +++ /dev/null @@ -1,71 +0,0 @@ -using System; - -using MobileCoreServices; -using Foundation; -using UIKit; - -namespace iOS.Extension -{ - public partial class ActionViewController : UIViewController - { - public ActionViewController(IntPtr handle) : base(handle) - { - } - - 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 ViewDidLoad() - { - base.ViewDidLoad(); - - // Get the item[s] we're handling from the extension context. - - // For example, look for an image and place it into an image view. - // Replace this with something appropriate for the type[s] your extension supports. - bool imageFound = false; - - foreach(var item in ExtensionContext.InputItems) - { - foreach(var itemProvider in item.Attachments) - { - if(itemProvider.HasItemConformingTo(UTType.Image)) - { - // This is an image. We'll load it, then place it in our image view. - itemProvider.LoadItem(UTType.Image, null, delegate (NSObject image, NSError error) - { - if(image != null) - { - NSOperationQueue.MainQueue.AddOperation(delegate - { - imageView.Image = (UIImage)image; - }); - } - }); - - imageFound = true; - break; - } - } - - if(imageFound) - { - // We only handle one image, so stop looking for more. - break; - } - } - } - - partial void DoneClicked(NSObject sender) - { - // Return any edited content to the host app. - // This template doesn't do anything, so we just echo the passed-in items. - ExtensionContext.CompleteRequest(ExtensionContext.InputItems, null); - } - } -} diff --git a/src/iOS.Extension/ActionViewController.designer.cs b/src/iOS.Extension/ActionViewController.designer.cs deleted file mode 100644 index 1fcdee7e8..000000000 --- a/src/iOS.Extension/ActionViewController.designer.cs +++ /dev/null @@ -1,24 +0,0 @@ -// -// This file has been generated automatically to store outlets and -// actions made in the Xcode designer. If it is removed, they will be lost. -// Manual changes to this file may not be handled correctly. -// -using UIKit; -using Foundation; - -namespace iOS.Extension -{ - [Register("ActionViewController")] - partial class ActionViewController - { - [Outlet] - UIImageView imageView { get; set; } - - [Action("DoneClicked:")] - partial void DoneClicked(NSObject sender); - - void ReleaseDesignerOutlets() - { - } - } -} \ No newline at end of file diff --git a/src/iOS.Extension/iOS.Extension.csproj b/src/iOS.Extension/iOS.Extension.csproj index b62353171..e575f386b 100644 --- a/src/iOS.Extension/iOS.Extension.csproj +++ b/src/iOS.Extension/iOS.Extension.csproj @@ -96,10 +96,6 @@ PasswordGeneratorViewController.cs - - ActionViewController.cs - -