diff options
Diffstat (limited to 'Xamarin.Forms.ControlGallery.iOS')
-rw-r--r-- | Xamarin.Forms.ControlGallery.iOS/AppDelegate.cs | 18 | ||||
-rw-r--r-- | Xamarin.Forms.ControlGallery.iOS/CustomRenderers.cs | 1 |
2 files changed, 19 insertions, 0 deletions
diff --git a/Xamarin.Forms.ControlGallery.iOS/AppDelegate.cs b/Xamarin.Forms.ControlGallery.iOS/AppDelegate.cs index 71c5e0c6..4ea9b30f 100644 --- a/Xamarin.Forms.ControlGallery.iOS/AppDelegate.cs +++ b/Xamarin.Forms.ControlGallery.iOS/AppDelegate.cs @@ -9,6 +9,7 @@ using UIKit; using Xamarin.Forms; using Xamarin.Forms.ControlGallery.iOS; using Xamarin.Forms.Controls; +using Xamarin.Forms.Controls.Issues; using Xamarin.Forms.Platform.iOS; [assembly: Dependency(typeof(TestCloudService))] @@ -132,6 +133,7 @@ namespace Xamarin.Forms.ControlGallery.iOS [Register("AppDelegate")] public partial class AppDelegate : FormsApplicationDelegate { + App _app; public override bool FinishedLaunching(UIApplication uiApplication, NSDictionary launchOptions) { @@ -150,6 +152,7 @@ namespace Xamarin.Forms.ControlGallery.iOS }; var app = new App(); + _app = app; // When the native control gallery loads up, it'll let us know so we can add the nested native controls MessagingCenter.Subscribe<NestedNativeControlGalleryPage>(this, NestedNativeControlGalleryPage.ReadyForNativeControlsMessage, AddNativeControls); @@ -352,6 +355,21 @@ namespace Xamarin.Forms.ControlGallery.iOS } #endregion + + [Export("navigateToTest:")] + public string NavigateToTest(string test) + { + // According to https://developer.xamarin.com/guides/testcloud/uitest/working-with/backdoors/ + // this method has to return a string + return _app.NavigateToTestPage(test).ToString(); + } + + [Export("reset:")] + public string Reset(string str) + { + _app.Reset(); + return String.Empty; + } } [Register("KVOUISlider")] diff --git a/Xamarin.Forms.ControlGallery.iOS/CustomRenderers.cs b/Xamarin.Forms.ControlGallery.iOS/CustomRenderers.cs index 87ede16f..5654fa39 100644 --- a/Xamarin.Forms.ControlGallery.iOS/CustomRenderers.cs +++ b/Xamarin.Forms.ControlGallery.iOS/CustomRenderers.cs @@ -7,6 +7,7 @@ using UIKit; using Xamarin.Forms; using Xamarin.Forms.ControlGallery.iOS; using Xamarin.Forms.Controls; +using Xamarin.Forms.Controls.Issues; using Xamarin.Forms.Platform.iOS; using RectangleF = CoreGraphics.CGRect; |