diff options
Diffstat (limited to 'Xamarin.Forms.Controls/ControlGalleryPages/NestedNativeControlGalleryPage.cs')
-rw-r--r-- | Xamarin.Forms.Controls/ControlGalleryPages/NestedNativeControlGalleryPage.cs | 27 |
1 files changed, 27 insertions, 0 deletions
diff --git a/Xamarin.Forms.Controls/ControlGalleryPages/NestedNativeControlGalleryPage.cs b/Xamarin.Forms.Controls/ControlGalleryPages/NestedNativeControlGalleryPage.cs new file mode 100644 index 00000000..9f596601 --- /dev/null +++ b/Xamarin.Forms.Controls/ControlGalleryPages/NestedNativeControlGalleryPage.cs @@ -0,0 +1,27 @@ +namespace Xamarin.Forms.Controls +{ + public partial class NestedNativeControlGalleryPage : ContentPage + { + public StackLayout Layout { get; set; } + + public bool NativeControlsAdded { get; set; } + + public NestedNativeControlGalleryPage () + { + Layout = new StackLayout { Padding = 20, VerticalOptions = LayoutOptions.FillAndExpand }; + + Content = new ScrollView { Content = Layout }; + + var label = new Label { Text = "There should be some native controls right below this", FontSize = 12 }; + + var testLabel = new Label { Text = "Forms Label", FontSize = 14 }; + var button = new Button { Text = "Resize Forms Label", HeightRequest = 80 }; + double originalSize = testLabel.FontSize; + button.Clicked += (sender, args) => { testLabel.FontSize = testLabel.FontSize == originalSize ? 24 : 14; }; + + Layout.Children.Add(testLabel); + Layout.Children.Add(button); + Layout.Children.Add(label); + } + } +}
\ No newline at end of file |