Exemple #1
0
        public void SetUserMeasurementUnits(DistanceUnitType measurementUnit)
        {
            MeasurementUnit = measurementUnit;
            bool isMetric = MeasurementHelper.IsMetric(MeasurementUnit);
            var  elevationDistanceUnitType = MeasurementHelper.GetElevationUnitType(isMetric);
            var  distanceUnitType          = MeasurementHelper.GetDistanceUnitType(isMetric);

            TotalDistanceUserMeasurementUnit = new UserMeasurementUnitMetric((float)Distance, DistanceUnitType.Metres, distanceUnitType);
            ElevationGainUserMeasurementUnit = new UserMeasurementUnitMetric((float)ElevationGain, DistanceUnitType.Metres, elevationDistanceUnitType);
        }
Exemple #2
0
 public UserMeasurementUnitStatisticsDetail(UserMeasurementUnitMetric metric)
 {
     Metric = metric;
     Metric.PropertyChanged += OnMetricPropertyChanged;
     base.DisplayValue       = metric.FormattedValueWithUnit;
 }