summaryrefslogtreecommitdiff
path: root/Xamarin.Forms.Controls.Issues/Xamarin.Forms.Controls.Issues.Shared/Issue2288.xaml.cs
blob: fa9d45c913d0850d1d2d106b8c5505997b66ebf7 (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
using System;
using System.Collections.Generic;

using Xamarin.Forms;
using System.ComponentModel;
using Xamarin.Forms.CustomAttributes;

namespace Xamarin.Forms.Controls
{
#if APP
	[Preserve (AllMembers = true)]
	[Issue (IssueTracker.Github, 2288, "ToolbarItem.Text change", PlatformAffected.iOS | PlatformAffected.Android)]
	public partial class Issue2288 : ContentPage
	{
		int _count = 0;
		public Issue2288 ()
		{
			InitializeComponent ();
			MainText = "initial";
			MainTextCommand = new Command(o =>
				{
					MainText = "changed " + _count++;
				});

			BindingContext = this;
		}

		string _mainText;
		public string MainText {
			get { return _mainText; }
			set {
				_mainText = value;
				OnPropertyChanged ();
			}
		}

		public Command MainTextCommand { get; set; }
	}
#endif
}