Skip to content
Snippets Groups Projects
Verified Commit 76d6d225 authored by Janne Mareike Koschinski's avatar Janne Mareike Koschinski
Browse files

Update leakcanary

parent 1b1ccb79
No related branches found
No related tags found
No related merge requests found
......@@ -176,11 +176,8 @@ dependencies {
// Quality Assurance
implementation(project(":malheur"))
withVersion("1.6.3") {
withVersion("2.2") {
debugImplementation("com.squareup.leakcanary", "leakcanary-android", version)
releaseImplementation("com.squareup.leakcanary", "leakcanary-android-no-op", version)
testImplementation("com.squareup.leakcanary", "leakcanary-android-no-op", version)
androidTestImplementation("com.squareup.leakcanary", "leakcanary-android-no-op", version)
}
// Dependency Injection
......
/*
* Quasseldroid - Quassel client for Android
*
* Copyright (c) 2019 Janne Mareike Koschinski
* Copyright (c) 2019 The Quassel Project
* Copyright (c) 2020 Janne Mareike Koschinski
* Copyright (c) 2020 The Quassel Project
*
* This program is free software: you can redistribute it and/or modify it
* under the terms of the GNU General Public License version 3 as published
......@@ -20,7 +20,6 @@
package de.kuschku.quasseldroid.app
interface AppDelegate {
fun shouldInit(): Boolean
fun onAttachBaseContext()
fun onPreInit()
fun onInit()
......
/*
* Quasseldroid - Quassel client for Android
*
* Copyright (c) 2019 Janne Mareike Koschinski
* Copyright (c) 2019 The Quassel Project
* Copyright (c) 2020 Janne Mareike Koschinski
* Copyright (c) 2020 The Quassel Project
*
* This program is free software: you can redistribute it and/or modify it
* under the terms of the GNU General Public License version 3 as published
......@@ -29,8 +29,6 @@ import de.kuschku.quasseldroid.util.compatibility.AndroidLoggingHandler
import de.kuschku.quasseldroid.util.compatibility.AndroidStreamChannelFactory
open class QuasseldroidBaseDelegate(private val app: Quasseldroid) : AppDelegate {
override fun shouldInit() = true
override fun onPreInit() = Unit
override fun onInit() {
......
......@@ -22,7 +22,6 @@ package de.kuschku.quasseldroid.app
import android.annotation.SuppressLint
import android.os.Build
import android.os.StrictMode
import com.squareup.leakcanary.LeakCanary
import de.kuschku.malheur.CrashHandler
import de.kuschku.quasseldroid.BuildConfig
import de.kuschku.quasseldroid.Quasseldroid
......@@ -38,10 +37,7 @@ import de.kuschku.quasseldroid.settings.SettingsMigrationManager
import de.kuschku.quasseldroid.util.helper.letIf
class QuasseldroidReleaseDelegate(private val app: Quasseldroid) : QuasseldroidBaseDelegate(app) {
override fun shouldInit() = !LeakCanary.isInAnalyzerProcess(app)
override fun onPreInit() {
LeakCanary.install(app)
CrashHandler.init<BuildConfig>(application = app)
}
......
/*
* Quasseldroid - Quassel client for Android
*
* Copyright (c) 2019 Janne Mareike Koschinski
* Copyright (c) 2019 The Quassel Project
* Copyright (c) 2020 Janne Mareike Koschinski
* Copyright (c) 2020 The Quassel Project
*
* This program is free software: you can redistribute it and/or modify it
* under the terms of the GNU General Public License version 3 as published
......@@ -20,7 +20,6 @@
package de.kuschku.quasseldroid.app
class QuasseldroidTestDelegate : AppDelegate {
override fun shouldInit() = true
override fun onAttachBaseContext() = Unit
override fun onPreInit() = Unit
override fun onInit() = Unit
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment