Millisecond-Chronometer
Millisecond-Chronometer copied to clipboard
A revised version of Android Chronometer that shows up milliseconds
Some small changes suggested by Android Studio. Now you can change how many digits of milliseconds will be shown by editing one constant
The following handler should really be static: private Handler mHandler = new Handler() { public void handleMessage(Message m) { if (mRunning) { updateText(SystemClock.elapsedRealtime()); dispatchChronometerTick(); sendMessageDelayed(Message.obtain(this , TICK_WHAT), 100); } }...
How to proceed?
Being able to access an array representation of this widget is super useful if, for example, a stopwatch with milliseconds needs to be visible in an app.