예제 #1
0
 protected cn.com.smartdevices.bracelet.chart.StatisticChartView.StatisticChartData a(int i)
 {
     SportDay sportday = StatisticFragment.x(q).addDay(i);
     Debug.i("Statistic.Main", (new StringBuilder()).append("Load Day : ").append(sportday).toString());
     String s1 = sportday.getKey();
     cn.com.smartdevices.bracelet.model.DaySportData.Summary summary;
     cn.com.smartdevices.bracelet.chart.StatisticChartView.StatisticChartData statisticchartdata;
     if (!StatisticFragment.t(q).containsKey(s1))
     {
         summary = StatisticFragment.y(q).getSummary(sportday);
         StatisticFragment.t(q).put(s1, summary);
     } else
     {
         summary = (cn.com.smartdevices.bracelet.model.DaySportData.Summary)StatisticFragment.t(q).get(s1);
     }
     statisticchartdata = new cn.com.smartdevices.bracelet.chart.StatisticChartView.StatisticChartData();
     if (summary != null)
     {
         statisticchartdata.stepValue = summary.getSteps();
         statisticchartdata.sleepValue = summary.getSleep();
         statisticchartdata.sleepDeepValue = summary.getSleepDeepTime();
     }
     statisticchartdata.date = b(sportday);
     return statisticchartdata;
 }
예제 #2
0
 protected cn.com.smartdevices.bracelet.chart.StatisticChartView.StatisticChartData a(int i1, int j1, int k1, int l1, int i2)
 {
     cn.com.smartdevices.bracelet.chart.StatisticChartView.StatisticChartData statisticchartdata = new cn.com.smartdevices.bracelet.chart.StatisticChartView.StatisticChartData();
     if (l1 > 0)
     {
         statisticchartdata.stepValue = i1 / l1;
     }
     if (i2 > 0)
     {
         statisticchartdata.sleepValue = j1 / i2;
         statisticchartdata.sleepDeepValue = k1 / i2;
     }
     return statisticchartdata;
 }