summaryrefslogtreecommitdiff
path: root/Xamarin.Forms.Controls.Issues/Xamarin.Forms.Controls.Issues.Shared/Issue22246_BZ.cs
blob: 309850854202b7667f9244eb074ee3168466da50 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

using Xamarin.Forms.CustomAttributes;

namespace Xamarin.Forms.Controls.TestCasesPages
{
	[Preserve (AllMembers=true)]
	[Issue (IssueTracker.Bugzilla, 22246, "Entry in Grid nested in ViewCell isn't expanding", PlatformAffected.WinPhone, NavigationBehavior.PushModalAsync)]
	public class Issue22246Bz : ContentPage
	{
		public Issue22246Bz()
		{
			var table = new TableView {
				Root = new TableRoot {
					new TableSection("Testing Section") {
						new ViewCell {
							View = CreateBugView()
						}
					}
				}
			};

			var layout = new StackLayout {
				Children = {
					CreateBugView(),
					table
				}
			};

			Content = layout;
		}

		View CreateBugView()
		{
			return new StackLayout {
				Orientation = StackOrientation.Horizontal,
				Spacing = 10,
				Children = {
					new Entry {Placeholder = "Entry", HorizontalOptions = LayoutOptions.FillAndExpand},
					new Button {Text = "Button"}
				}
			};
		}
	}
}