示例#1
0
        public static double  ValueTypeIn(TypeOfConventer tOConvert, MapPreparedData GeoData, Plugin.Geolocator.Abstractions.Position newValue)
        {
            switch (tOConvert)
            {
            case TypeOfConventer.Timer:
                return(0);

            case TypeOfConventer.Distance:
                return(RoadDistance(GeoData.RoadDistance));

            case TypeOfConventer.Speed:
                return(Speed(newValue.Speed));

            case TypeOfConventer.MediumSpeed:
                return(Speed(GeoData.MediumSpeed));

            case TypeOfConventer.Tempo:
                return(Tempo(newValue.Speed));

            case TypeOfConventer.MediumTempo:
                return(Tempo(GeoData.MediumSpeed));

            case TypeOfConventer.Altitude:
                return(Altidude(newValue.Altitude));

            default:
                return(-1);
            }
        }
示例#2
0
        private void OnTapGestureChose(CounterFieldPage sender, TypeOfConventer arg)
        {
            int i = 0;

            foreach (Label label in WorkField)
            {
                if (label.Id == sender.CallObjId)
                {
                    WorkValue[i] = arg;
                }

                i++;
            }

            if (NewWorkoutPoint != null)
            {
                RefreshTimerWorkFieldAndObj(WorkoutData.Time);
                RefreshWorkFieldAndObj(NewWorkoutPoint);
            }
            else
            {
                ResetCounter();
            }
        }