internal static void OnChanged(MagnetometerChangedEventArgs e) { var handler = ReadingChanged; if (handler == null) { return; } if (useSyncContext) { MainThread.BeginInvokeOnMainThread(() => handler?.Invoke(null, e)); } else { handler?.Invoke(null, e); } }
static void ReportUpdated(object sender, object e) => MainThread.BeginInvokeOnMainThread(OnBatteryInfoChanged);
static void ReportEnergySaverUpdated(object sender, object e) => MainThread.BeginInvokeOnMainThread(OnEnergySaverChanged);
static void BatteryChangedNotification(object sender, NSNotificationEventArgs args) => MainThread.BeginInvokeOnMainThread(OnBatteryChanged);
static void PowerChangedNotification(NSNotification notification) => MainThread.BeginInvokeOnMainThread(OnPowerChanged);
static void ReportUpdated(object sender, object e) => MainThread.BeginInvokeOnMainThread(OnPowerChanged);
static void PowerSourceNotification() => MainThread.BeginInvokeOnMainThread(OnBatteryInfoChanged);