Created
September 13, 2017 20:42
-
-
Save TimCastelijns/37c2bdd874bed0194b1910bb8ed451fb to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
saBusiness.setOnSeekArcChangeListener(new SeekArc.OnSeekArcChangeListener() { | |
@Override | |
public void onProgressChanged(SeekArc seekArc, int i, boolean b) { | |
int text = R.string.week_overview_clear; | |
int color = R.color.week_overview_clear; | |
if (i > 75) { | |
text = R.string.week_overview_swamped; | |
color = R.color.week_overview_swamped; | |
} else if (i > 50) { | |
text = R.string.week_overview_busy; | |
color = R.color.week_overview_busy; | |
} else if (i > 25) { | |
text = R.string.week_overview_medium; | |
color = R.color.week_overview_medium; | |
} | |
tvBusiness.setText(resources.getString(text)); | |
saBusiness.setProgressColor(resources.getColor(color)); | |
} | |
@Override | |
public void onStartTrackingTouch(SeekArc seekArc) { | |
} | |
@Override | |
public void onStopTrackingTouch(SeekArc seekArc) { | |
} | |
}); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment