feat: Implement crash reporting system with CrashLogsScreen and integration in ProfileScreen
This commit is contained in:
@@ -0,0 +1,38 @@
|
||||
package com.rosetta.messenger
|
||||
|
||||
import android.app.Application
|
||||
import android.util.Log
|
||||
import com.rosetta.messenger.utils.CrashReportManager
|
||||
|
||||
/**
|
||||
* Application класс для инициализации глобальных компонентов приложения
|
||||
*/
|
||||
class RosettaApplication : Application() {
|
||||
|
||||
companion object {
|
||||
private const val TAG = "RosettaApplication"
|
||||
}
|
||||
|
||||
override fun onCreate() {
|
||||
super.onCreate()
|
||||
|
||||
Log.d(TAG, "Application starting...")
|
||||
|
||||
// Инициализируем crash reporter
|
||||
initCrashReporting()
|
||||
|
||||
Log.d(TAG, "Application initialized successfully")
|
||||
}
|
||||
|
||||
/**
|
||||
* Инициализация системы сбора crash reports
|
||||
*/
|
||||
private fun initCrashReporting() {
|
||||
try {
|
||||
CrashReportManager.init(this)
|
||||
Log.d(TAG, "Crash reporting initialized")
|
||||
} catch (e: Exception) {
|
||||
Log.e(TAG, "Failed to initialize crash reporting", e)
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user