|
|
@ -29,16 +29,15 @@ import android.graphics.RectF;
|
|
|
|
import android.support.annotation.Nullable;
|
|
|
|
import android.support.annotation.Nullable;
|
|
|
|
import android.util.AttributeSet;
|
|
|
|
import android.util.AttributeSet;
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
import org.isoron.uhabits.R;
|
|
|
|
import org.isoron.uhabits.helpers.ColorHelper;
|
|
|
|
import org.isoron.uhabits.helpers.ColorHelper;
|
|
|
|
import org.isoron.uhabits.helpers.DateHelper;
|
|
|
|
import org.isoron.uhabits.helpers.DateHelper;
|
|
|
|
import org.isoron.uhabits.R;
|
|
|
|
|
|
|
|
import org.isoron.uhabits.models.Habit;
|
|
|
|
import org.isoron.uhabits.models.Habit;
|
|
|
|
import org.isoron.uhabits.models.Score;
|
|
|
|
import org.isoron.uhabits.models.Score;
|
|
|
|
|
|
|
|
|
|
|
|
import java.text.SimpleDateFormat;
|
|
|
|
import java.text.SimpleDateFormat;
|
|
|
|
import java.util.Calendar;
|
|
|
|
import java.util.Calendar;
|
|
|
|
import java.util.GregorianCalendar;
|
|
|
|
import java.util.GregorianCalendar;
|
|
|
|
import java.util.Locale;
|
|
|
|
|
|
|
|
import java.util.Random;
|
|
|
|
import java.util.Random;
|
|
|
|
|
|
|
|
|
|
|
|
public class HabitScoreView extends ScrollableDataView implements HabitDataView
|
|
|
|
public class HabitScoreView extends ScrollableDataView implements HabitDataView
|
|
|
@ -100,9 +99,9 @@ public class HabitScoreView extends ScrollableDataView implements HabitDataView
|
|
|
|
createPaints();
|
|
|
|
createPaints();
|
|
|
|
createColors();
|
|
|
|
createColors();
|
|
|
|
|
|
|
|
|
|
|
|
dfYear = new SimpleDateFormat("yyyy", Locale.getDefault());
|
|
|
|
dfYear = DateHelper.getDateFormat("yyyy");
|
|
|
|
dfMonth = new SimpleDateFormat("MMM", Locale.getDefault());
|
|
|
|
dfMonth = DateHelper.getDateFormat("MMM");
|
|
|
|
dfDay = new SimpleDateFormat("d", Locale.getDefault());
|
|
|
|
dfDay = DateHelper.getDateFormat("d");
|
|
|
|
|
|
|
|
|
|
|
|
rect = new RectF();
|
|
|
|
rect = new RectF();
|
|
|
|
prevRect = new RectF();
|
|
|
|
prevRect = new RectF();
|
|
|
|