예제 #1
0
        private void OnNavigating(object sender, ShellNavigatingEventArgs e)
        {
            AddChipTab.IsEnabled = Preferences.Get("Role", "") == "ROLE_ADMIN";
            if (Shell.Current == null)
            {
                return;
            }

            if ((e.Source == ShellNavigationSource.ShellSectionChanged || e.Source == ShellNavigationSource.Unknown) &&
                e.Target.Location.ToString() != Routes.Attendance)
            {
                NFCController.StartListening(OnMessageReceived, true);
            }

            MapRouteToPage(e.Target.Location)?.OnNavigated();
        }
예제 #2
0
        public static async void StartNFCRedirecting()
        {
            await Task.Delay(100);

            NFCController.StartListening(OnMessageReceived, true);
        }
예제 #3
0
 protected override void OnSleep()
 {
     NFCController.Pause();
 }
예제 #4
0
 protected override void OnResume()
 {
     base.OnResume();
     NFCController.Resume();
 }
예제 #5
0
 protected override void OnStart()
 {
     NFCController.StopAll();
 }