From 5ea60c535df1d24ef835e9d1896a9927028e7f93 Mon Sep 17 00:00:00 2001 From: tibbi Date: Tue, 21 Apr 2020 17:45:36 +0200 Subject: [PATCH] fixing a deadloop at navigationBarHeight getter --- build.gradle | 2 +- .../kotlin/com/simplemobiletools/commons/extensions/Context.kt | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/build.gradle b/build.gradle index 1698f01c7..36d6ef58d 100644 --- a/build.gradle +++ b/build.gradle @@ -7,7 +7,7 @@ buildscript { propMinSdkVersion = 21 propTargetSdkVersion = propCompileSdkVersion propVersionCode = 1 - propVersionName = '5.26.17' + propVersionName = '5.26.18' kotlin_version = '1.3.72' } diff --git a/commons/src/main/kotlin/com/simplemobiletools/commons/extensions/Context.kt b/commons/src/main/kotlin/com/simplemobiletools/commons/extensions/Context.kt index b5a704b15..cc7e0ffcc 100644 --- a/commons/src/main/kotlin/com/simplemobiletools/commons/extensions/Context.kt +++ b/commons/src/main/kotlin/com/simplemobiletools/commons/extensions/Context.kt @@ -719,7 +719,7 @@ val Context.windowManager: WindowManager get() = getSystemService(Context.WINDOW val Context.portrait get() = resources.configuration.orientation == Configuration.ORIENTATION_PORTRAIT val Context.navigationBarRight: Boolean get() = usableScreenSize.x < realScreenSize.x val Context.navigationBarBottom: Boolean get() = usableScreenSize.y < realScreenSize.y -val Context.navigationBarHeight: Int get() = if (navigationBarBottom && navigationBarHeight != usableScreenSize.y) navigationBarSize.y else 0 +val Context.navigationBarHeight: Int get() = if (navigationBarBottom && navigationBarSize.y != usableScreenSize.y) navigationBarSize.y else 0 val Context.navigationBarWidth: Int get() = if (navigationBarRight) navigationBarSize.x else 0 val Context.navigationBarSize: Point