aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRobert Jaros <rjaros@finn.pl>2019-06-20 22:33:54 +0200
committerRobert Jaros <rjaros@finn.pl>2019-06-20 22:33:54 +0200
commitd9f1a90c772719d14540eb2bf7bc3b8384fa7a72 (patch)
tree1ac9a2d337413098d5c6a33a2d2fa528e9cb5651
parent0fe56689dbc57777b29881ff9439fb543f79b9ec (diff)
downloadkvision-d9f1a90c772719d14540eb2bf7bc3b8384fa7a72.tar.gz
kvision-d9f1a90c772719d14540eb2bf7bc3b8384fa7a72.tar.bz2
kvision-d9f1a90c772719d14540eb2bf7bc3b8384fa7a72.zip
Suppress some style warnings.
-rw-r--r--kvision-modules/kvision-cordova/src/main/kotlin/pl/treksoft/kvision/cordova/Geolocation.kt1
-rw-r--r--kvision-modules/kvision-cordova/src/main/kotlin/pl/treksoft/kvision/cordova/Media.kt1
-rw-r--r--kvision-modules/kvision-cordova/src/main/kotlin/pl/treksoft/kvision/cordova/MediaCapture.kt1
3 files changed, 3 insertions, 0 deletions
diff --git a/kvision-modules/kvision-cordova/src/main/kotlin/pl/treksoft/kvision/cordova/Geolocation.kt b/kvision-modules/kvision-cordova/src/main/kotlin/pl/treksoft/kvision/cordova/Geolocation.kt
index 4087a4f2..c4ccd354 100644
--- a/kvision-modules/kvision-cordova/src/main/kotlin/pl/treksoft/kvision/cordova/Geolocation.kt
+++ b/kvision-modules/kvision-cordova/src/main/kotlin/pl/treksoft/kvision/cordova/Geolocation.kt
@@ -251,6 +251,7 @@ object Locationservices {
}
}
+ @Suppress("MagicNumber")
private fun getJsPriority(priority: Priority): dynamic {
return when (priority) {
Priority.PRIORITY_HIGH_ACCURACY -> 100
diff --git a/kvision-modules/kvision-cordova/src/main/kotlin/pl/treksoft/kvision/cordova/Media.kt b/kvision-modules/kvision-cordova/src/main/kotlin/pl/treksoft/kvision/cordova/Media.kt
index 6ea43d76..a126941b 100644
--- a/kvision-modules/kvision-cordova/src/main/kotlin/pl/treksoft/kvision/cordova/Media.kt
+++ b/kvision-modules/kvision-cordova/src/main/kotlin/pl/treksoft/kvision/cordova/Media.kt
@@ -43,6 +43,7 @@ external class MediaError {
/**
* Cordova media class.
*/
+@Suppress("TooManyFunctions")
external class Media(
src: String,
mediaSuccess: (() -> Unit)? = definedExternally,
diff --git a/kvision-modules/kvision-cordova/src/main/kotlin/pl/treksoft/kvision/cordova/MediaCapture.kt b/kvision-modules/kvision-cordova/src/main/kotlin/pl/treksoft/kvision/cordova/MediaCapture.kt
index c7b427dc..fda81da7 100644
--- a/kvision-modules/kvision-cordova/src/main/kotlin/pl/treksoft/kvision/cordova/MediaCapture.kt
+++ b/kvision-modules/kvision-cordova/src/main/kotlin/pl/treksoft/kvision/cordova/MediaCapture.kt
@@ -100,6 +100,7 @@ object MediaCapture {
CAPTURE_NOT_SUPPORTED
}
+ @Suppress("MagicNumber")
private fun codeToEnum(code: Int): CaptureErrorCode {
return when (code) {
0 -> CaptureErrorCode.CAPTURE_INTERNAL_ERR