Skip to content

Commit

Permalink
Random cleanup
Browse files Browse the repository at this point in the history
  • Loading branch information
jwood803 committed Sep 5, 2015
1 parent b1aec9c commit 1113fe1
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions ShareExample/iOS/AppDelegate.cs
Original file line number Diff line number Diff line change
Expand Up @@ -2,12 +2,11 @@
using UIKit;
using Xamarin.Forms;
using Xamarin.Forms.Platform.iOS;
using System.Threading.Tasks;

namespace ShareExample.iOS
{
[Register("AppDelegate")]
public partial class AppDelegate : global::Xamarin.Forms.Platform.iOS.FormsApplicationDelegate
public partial class AppDelegate : FormsApplicationDelegate
{
public override bool FinishedLaunching(UIApplication app, NSDictionary options)
{
Expand Down Expand Up @@ -35,9 +34,11 @@ async void Share (ImageSource imageSource)
var activityController = new UIActivityViewController (activityItems, null);

var topController = UIApplication.SharedApplication.KeyWindow.RootViewController;

while (topController.PresentedViewController != null) {
topController = topController.PresentedViewController;
}

topController.PresentViewController (activityController, true, () => {});
}
}
Expand Down

0 comments on commit 1113fe1

Please sign in to comment.