aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAllan Wang <me@allanwang.ca>2017-07-19 12:41:34 -0700
committerAllan Wang <me@allanwang.ca>2017-07-19 12:41:34 -0700
commitbb91aea60530f8342990ed5eda486656f3567d2c (patch)
treeb24a30088bddc60f64bf5f07e177b70b831cc8fc
parentf5ee096ccc7e68d5d3d23ba708ca962fb46874be (diff)
downloadkau-bb91aea60530f8342990ed5eda486656f3567d2c.tar.gz
kau-bb91aea60530f8342990ed5eda486656f3567d2c.tar.bz2
kau-bb91aea60530f8342990ed5eda486656f3567d2c.zip
Comment2.1
-rw-r--r--core/src/main/kotlin/ca/allanwang/kau/utils/ContextUtils.kt2
1 files changed, 1 insertions, 1 deletions
diff --git a/core/src/main/kotlin/ca/allanwang/kau/utils/ContextUtils.kt b/core/src/main/kotlin/ca/allanwang/kau/utils/ContextUtils.kt
index 9884778..b73ff1f 100644
--- a/core/src/main/kotlin/ca/allanwang/kau/utils/ContextUtils.kt
+++ b/core/src/main/kotlin/ca/allanwang/kau/utils/ContextUtils.kt
@@ -98,7 +98,7 @@ inline fun Context.drawable(@DrawableRes id: Int, fallback: Drawable?): Drawable
inline fun Context.interpolator(@InterpolatorRes id: Int) = AnimationUtils.loadInterpolator(this, id)
inline fun Context.animation(@AnimRes id: Int) = AnimationUtils.loadAnimation(this, id)
/**
- * Returns plural form of res. By default, the quantity is passed as the argument
+ * Returns plural form of res. The quantity is also passed to the formatter as an int
*/
inline fun Context.plural(@PluralsRes id: Int, quantity: Number)
= resources.getQuantityString(id, quantity.toInt(), quantity.toInt())