Ignoring annoying bug with Samsung devices on 4.2.2 (#57)
* Updated gradle version. * Fixed #55. Ignoring annoying non fatal bug on Samsung devices.
This commit is contained in:
parent
acf6995c2d
commit
ba120b1e0b
@ -1,4 +1,4 @@
|
|||||||
**1.5.1.9**
|
**1.5.1.9/10/11**
|
||||||
|
|
||||||
- Hiding the unread badge when marking all items as read.
|
- Hiding the unread badge when marking all items as read.
|
||||||
|
|
||||||
|
@ -31,6 +31,8 @@ class MyApp : MultiDexApplication() {
|
|||||||
|
|
||||||
initTheme()
|
initTheme()
|
||||||
|
|
||||||
|
tryToHandleBug()
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
private fun initAmplify() {
|
private fun initAmplify() {
|
||||||
@ -82,4 +84,16 @@ class MyApp : MultiDexApplication() {
|
|||||||
.setSharedPreferences(PreferenceManager.getDefaultSharedPreferences(this))
|
.setSharedPreferences(PreferenceManager.getDefaultSharedPreferences(this))
|
||||||
.initialize()
|
.initialize()
|
||||||
}
|
}
|
||||||
|
|
||||||
|
private fun tryToHandleBug() {
|
||||||
|
val oldHandler = Thread.getDefaultUncaughtExceptionHandler()
|
||||||
|
|
||||||
|
Thread.setDefaultUncaughtExceptionHandler { thread, e ->
|
||||||
|
if (e is java.lang.NoClassDefFoundError && e.stackTrace.asList().any { it.toString().contains("android.view.ViewDebug") })
|
||||||
|
Unit
|
||||||
|
else
|
||||||
|
oldHandler.uncaughtException(thread, e)
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
}
|
}
|
@ -7,7 +7,7 @@ buildscript {
|
|||||||
jcenter()
|
jcenter()
|
||||||
}
|
}
|
||||||
dependencies {
|
dependencies {
|
||||||
classpath 'com.android.tools.build:gradle:3.0.0-alpha5'
|
classpath 'com.android.tools.build:gradle:3.0.0-alpha8'
|
||||||
classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version"
|
classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version"
|
||||||
|
|
||||||
// NOTE: Do not place your application dependencies here; they belong
|
// NOTE: Do not place your application dependencies here; they belong
|
||||||
|
Loading…
Reference in New Issue
Block a user