Beispiel #1
0
        private void PositionDetermined(PositionDeterminedEventArgs e)
        {
            _hasDeterminedPosition = true;
            LastPosition = e.Location;

            if (OnPositionDetermined != null)
                OnPositionDetermined(this, e);
        }
Beispiel #2
0
        private void PositionDetermined(PositionDeterminedEventArgs e)
        {
            _hasDeterminedPosition = true;
            LastPosition           = e.Location;

            if (OnPositionDetermined != null)
            {
                OnPositionDetermined(this, e);
            }
        }
Beispiel #3
0
        private async void _locationManager_OnPositionDetermined(object sender, PositionDeterminedEventArgs ca)
        {
            if (ca.IsPermissionFailure || ca.IsOtherFailure)
                MessageBox.Show("Unable to determine your location.  Please ensure that location services are enabled.");
            else
            {
                _location = ca.Location;

                Settings settings = Settings.Load();

                if (!String.IsNullOrEmpty(settings.FacebookToken) && !String.IsNullOrEmpty(settings.FacebookId))
                {
                    await Authenticate(settings);
                }
                else
                {
                    LoginButtonBorder.Visibility = Visibility.Visible;
                }
            }
        }