public void OnItemSelected (object sender, SelectedItemChangedEventArgs e) {
			if (((ListView)sender).SelectedItem == null) {
				return;
			}

			var service = e.SelectedItem as IService;
			var characteristicsPage = new CharacteristicList(adapter, device, service);
			Navigation.PushAsync(characteristicsPage);

			((ListView)sender).SelectedItem = null; // clear selection
		}
示例#2
0
        public void OnItemSelected(object sender, SelectedItemChangedEventArgs e)
        {
            if (((ListView)sender).SelectedItem == null)
            {
                return;
            }

            var service             = e.SelectedItem as IService;
            var characteristicsPage = new CharacteristicList(adapter, device, service);

            Navigation.PushAsync(characteristicsPage);

            ((ListView)sender).SelectedItem = null;             // clear selection
        }
示例#3
0
        public void OnItemSelected(object sender, SelectedItemChangedEventArgs e)
        {
            ListView listView = sender as ListView;

            if (listView?.SelectedItem == null)
            {
                return;
            }

            var service             = e.SelectedItem as IService;
            var characteristicsPage = new CharacteristicList(_adapter, _device, service);

            Navigation.PushAsync(characteristicsPage);

            listView.SelectedItem = null; // clear selection
        }