Example #1
0
 public static DeviceConfigurationView GetDeviceConfigurationView()
 {
     if (_view == null)
     {
         _view = new DeviceConfigurationView();
     }
     return(_view);
 }
Example #2
0
        private async void ResetButton_Clicked(object sender, EventArgs e)
        {
            try
            {
                _control.SetDefaultConfigrations();
            }
            catch (Exception)
            {
                await Navigation.PopModalAsync();

                CrossToastPopUp.Current.ShowToastMessage("Lost Connection");
                _view    = null;
                _control = null;
            }
        }
        private async void ImageButton_Clicked_1(object sender, EventArgs e)
        {
            if (AutoSwitch.IsToggled)
            {
                AutoSwitch.IsToggled = false;
            }
            try
            {
                await Navigation.PushModalAsync(DeviceConfigurationView.GetDeviceConfigurationView());
            }
            catch (Exception)
            {
                await Navigation.PopModalAsync();

                CrossToastPopUp.Current.ShowToastMessage("Lost Connection");
                _connection.Disconect();
                _connection = null;
                _control    = null;
            }
        }