lints
This commit is contained in:
parent
09433d6a4f
commit
9b064404ac
2 changed files with 8 additions and 14 deletions
|
@ -11,7 +11,6 @@ import android.graphics.Point
|
|||
import android.graphics.Rect
|
||||
import android.os.PowerManager
|
||||
import android.support.wearable.watchface.WatchFaceStyle
|
||||
import android.text.format.DateFormat
|
||||
import android.view.LayoutInflater
|
||||
import android.view.View
|
||||
import android.view.WindowInsets
|
||||
|
@ -239,12 +238,9 @@ class BigChartWatchface : WatchFace() {
|
|||
return (System.currentTimeMillis() - singleBg.timeStamp).toDouble()
|
||||
}
|
||||
|
||||
private fun readingAge(): String {
|
||||
if (singleBg.timeStamp == 0L) return "--'"
|
||||
val minutesAgo = floor(timeSince() / (1000 * 60)).toInt()
|
||||
return if (minutesAgo == 1) "$minutesAgo'"
|
||||
else "$minutesAgo'"
|
||||
}
|
||||
private fun readingAge(): String =
|
||||
if (singleBg.timeStamp == 0L) "--'"
|
||||
else "${floor(timeSince() / (1000 * 60)).toInt()}'"
|
||||
|
||||
override fun onDestroy() {
|
||||
disposable.clear()
|
||||
|
|
|
@ -185,12 +185,10 @@ class NoChartWatchface : WatchFace() {
|
|||
|
||||
fun timeSince(): Double = (System.currentTimeMillis() - singleBg.timeStamp).toDouble()
|
||||
|
||||
private fun readingAge(): String {
|
||||
if (singleBg.timeStamp == 0L) return "--'"
|
||||
val minutesAgo = floor(timeSince() / (1000 * 60)).toInt()
|
||||
return if (minutesAgo == 1) "$minutesAgo'"
|
||||
else "$minutesAgo'"
|
||||
}
|
||||
private fun readingAge(): String =
|
||||
if (singleBg.timeStamp == 0L) "--'"
|
||||
else "${floor(timeSince() / (1000 * 60)).toInt()}'"
|
||||
|
||||
|
||||
override fun onDestroy() {
|
||||
disposable.clear()
|
||||
|
|
Loading…
Reference in a new issue