Esempio n. 1
0
 private void Apply()
 {
     drone.SendConfig(data);
     foreach (Binding binding in bindings)
     {
         binding.ClearChangedByUser();
     }
 }
Esempio n. 2
0
        /// <summary>
        /// Applys the settings to the connected drone.
        /// </summary>
        private void Apply(bool force)
        {
            // Only send config when settings were changed by user
            if (force || IsAnyBindingChanged())
            {
                drone.SendConfig(data);
                originalData = data;
            }

            ClearChangedByUser();
        }
Esempio n. 3
0
 private void droneSettingsPropertyGrid_PropertyValueChanged(object s, PropertyValueChangedEventArgs e)
 {
     try
     {
         DroneSettings settings = (DroneSettings)droneSettingsPropertyGrid.SelectedObject;
         drone.SendConfig(settings);
     }
     catch (Exception ex)
     {
         Log.Error(ex);
         MessageBox.Show(ex.Message, "Error setting settings", MessageBoxButtons.OK, MessageBoxIcon.Error);
     }
 }
Esempio n. 4
0
 private void UploadSettings()
 {
     drone.SendConfig(settings);
 }