Use Notifications Master app ID

This commit is contained in:
ajp_anton
2026-08-16 01:57:44 +00:00
parent 572660a967
commit af3673c2e8
51 changed files with 142 additions and 142 deletions
+2 -2
View File
@@ -34,11 +34,11 @@ if (releaseBuildRequested && !hasReleaseSigning) {
} }
android { android {
namespace = "se.ajpanton.notificationlog" namespace = "se.ajpanton.notificationsmaster"
compileSdk = 36 compileSdk = 36
defaultConfig { defaultConfig {
applicationId = "se.ajpanton.notificationlog" applicationId = "se.ajpanton.notificationsmaster"
minSdk = 34 minSdk = 34
targetSdk = 36 targetSdk = 36
versionCode = project.findProperty("notificationLogVersionCode")?.toString()?.toIntOrNull() ?: 1 versionCode = project.findProperty("notificationLogVersionCode")?.toString()?.toIntOrNull() ?: 1
@@ -1,4 +1,4 @@
package se.ajpanton.notificationlog package se.ajpanton.notificationsmaster
import android.os.Bundle import android.os.Bundle
import android.content.res.ColorStateList import android.content.res.ColorStateList
@@ -20,17 +20,17 @@ import androidx.recyclerview.widget.RecyclerView
import androidx.lifecycle.lifecycleScope import androidx.lifecycle.lifecycleScope
import com.google.android.material.dialog.MaterialAlertDialogBuilder import com.google.android.material.dialog.MaterialAlertDialogBuilder
import com.google.android.material.switchmaterial.SwitchMaterial import com.google.android.material.switchmaterial.SwitchMaterial
import se.ajpanton.notificationlog.capture.SeenApps import se.ajpanton.notificationsmaster.capture.SeenApps
import se.ajpanton.notificationlog.databinding.FragmentEventSettingsBinding import se.ajpanton.notificationsmaster.databinding.FragmentEventSettingsBinding
import se.ajpanton.notificationlog.settings.AppListItem import se.ajpanton.notificationsmaster.settings.AppListItem
import se.ajpanton.notificationlog.settings.AppListOrdering import se.ajpanton.notificationsmaster.settings.AppListOrdering
import se.ajpanton.notificationlog.settings.AppRuleMode import se.ajpanton.notificationsmaster.settings.AppRuleMode
import se.ajpanton.notificationlog.settings.ListedApp import se.ajpanton.notificationsmaster.settings.ListedApp
import se.ajpanton.notificationlog.settings.AppFilterSettings import se.ajpanton.notificationsmaster.settings.AppFilterSettings
import se.ajpanton.notificationlog.settings.AppFilterSettingsStore import se.ajpanton.notificationsmaster.settings.AppFilterSettingsStore
import se.ajpanton.notificationlog.settings.LoggingRuleStore import se.ajpanton.notificationsmaster.settings.LoggingRuleStore
import se.ajpanton.notificationlog.settings.LoggingType import se.ajpanton.notificationsmaster.settings.LoggingType
import se.ajpanton.notificationlog.settings.PerAppEventSettingsStore import se.ajpanton.notificationsmaster.settings.PerAppEventSettingsStore
import kotlinx.coroutines.Dispatchers import kotlinx.coroutines.Dispatchers
import kotlinx.coroutines.launch import kotlinx.coroutines.launch
import kotlinx.coroutines.withContext import kotlinx.coroutines.withContext
@@ -1,13 +1,13 @@
package se.ajpanton.notificationlog package se.ajpanton.notificationsmaster
import android.os.Bundle import android.os.Bundle
import android.view.View import android.view.View
import androidx.fragment.app.Fragment import androidx.fragment.app.Fragment
import com.google.android.material.switchmaterial.SwitchMaterial import com.google.android.material.switchmaterial.SwitchMaterial
import se.ajpanton.notificationlog.databinding.FragmentFilterLoggingBinding import se.ajpanton.notificationsmaster.databinding.FragmentFilterLoggingBinding
import se.ajpanton.notificationlog.settings.CaptureSettingsStore import se.ajpanton.notificationsmaster.settings.CaptureSettingsStore
import se.ajpanton.notificationlog.settings.LoggingRuleStore import se.ajpanton.notificationsmaster.settings.LoggingRuleStore
import se.ajpanton.notificationlog.settings.LoggingType import se.ajpanton.notificationsmaster.settings.LoggingType
class FilterLoggingFragment : Fragment(R.layout.fragment_filter_logging) { class FilterLoggingFragment : Fragment(R.layout.fragment_filter_logging) {
private var binding: FragmentFilterLoggingBinding? = null private var binding: FragmentFilterLoggingBinding? = null
@@ -1,4 +1,4 @@
package se.ajpanton.notificationlog package se.ajpanton.notificationsmaster
import android.app.Dialog import android.app.Dialog
import android.graphics.Bitmap import android.graphics.Bitmap
@@ -19,7 +19,7 @@ import androidx.core.view.WindowInsetsCompat
import androidx.core.view.WindowInsetsControllerCompat import androidx.core.view.WindowInsetsControllerCompat
import androidx.fragment.app.DialogFragment import androidx.fragment.app.DialogFragment
import androidx.lifecycle.lifecycleScope import androidx.lifecycle.lifecycleScope
import se.ajpanton.notificationlog.data.EncryptedImageStore import se.ajpanton.notificationsmaster.data.EncryptedImageStore
import kotlinx.coroutines.Dispatchers import kotlinx.coroutines.Dispatchers
import kotlinx.coroutines.launch import kotlinx.coroutines.launch
import kotlinx.coroutines.withContext import kotlinx.coroutines.withContext
@@ -1,4 +1,4 @@
package se.ajpanton.notificationlog package se.ajpanton.notificationsmaster
import android.content.ClipData import android.content.ClipData
import android.os.Bundle import android.os.Bundle
@@ -9,14 +9,14 @@ import android.widget.Spinner
import android.widget.TextView import android.widget.TextView
import androidx.fragment.app.Fragment import androidx.fragment.app.Fragment
import com.google.android.material.switchmaterial.SwitchMaterial import com.google.android.material.switchmaterial.SwitchMaterial
import se.ajpanton.notificationlog.databinding.FragmentLogDisplayBinding import se.ajpanton.notificationsmaster.databinding.FragmentLogDisplayBinding
import se.ajpanton.notificationlog.settings.DisplayEvent import se.ajpanton.notificationsmaster.settings.DisplayEvent
import se.ajpanton.notificationlog.settings.LogField import se.ajpanton.notificationsmaster.settings.LogField
import se.ajpanton.notificationlog.settings.LogViewSettings import se.ajpanton.notificationsmaster.settings.LogViewSettings
import se.ajpanton.notificationlog.settings.LogViewSettingsStore import se.ajpanton.notificationsmaster.settings.LogViewSettingsStore
import se.ajpanton.notificationlog.settings.TimestampClockFormat import se.ajpanton.notificationsmaster.settings.TimestampClockFormat
import se.ajpanton.notificationlog.settings.TimestampDateFormat import se.ajpanton.notificationsmaster.settings.TimestampDateFormat
import se.ajpanton.notificationlog.settings.TimestampZone import se.ajpanton.notificationsmaster.settings.TimestampZone
class LogDisplayFragment : Fragment(R.layout.fragment_log_display) { class LogDisplayFragment : Fragment(R.layout.fragment_log_display) {
private var binding: FragmentLogDisplayBinding? = null private var binding: FragmentLogDisplayBinding? = null
@@ -1,4 +1,4 @@
package se.ajpanton.notificationlog package se.ajpanton.notificationsmaster
import android.os.Bundle import android.os.Bundle
import android.hardware.biometrics.BiometricPrompt import android.hardware.biometrics.BiometricPrompt
@@ -22,9 +22,9 @@ import androidx.core.view.forEach
import androidx.drawerlayout.widget.DrawerLayout import androidx.drawerlayout.widget.DrawerLayout
import androidx.fragment.app.commit import androidx.fragment.app.commit
import com.google.android.material.navigation.NavigationView import com.google.android.material.navigation.NavigationView
import se.ajpanton.notificationlog.databinding.ActivityMainBinding import se.ajpanton.notificationsmaster.databinding.ActivityMainBinding
import se.ajpanton.notificationlog.settings.AppLockStore import se.ajpanton.notificationsmaster.settings.AppLockStore
import se.ajpanton.notificationlog.settings.LogAppFilterStore import se.ajpanton.notificationsmaster.settings.LogAppFilterStore
class MainActivity : AppCompatActivity(), NavigationView.OnNavigationItemSelectedListener { class MainActivity : AppCompatActivity(), NavigationView.OnNavigationItemSelectedListener {
private lateinit var binding: ActivityMainBinding private lateinit var binding: ActivityMainBinding
@@ -1,13 +1,13 @@
package se.ajpanton.notificationlog package se.ajpanton.notificationsmaster
import android.app.Application import android.app.Application
import android.content.pm.PackageManager import android.content.pm.PackageManager
import se.ajpanton.notificationlog.data.EncryptedNotificationLogStore import se.ajpanton.notificationsmaster.data.EncryptedNotificationLogStore
import se.ajpanton.notificationlog.settings.AppFilterSettingsStore import se.ajpanton.notificationsmaster.settings.AppFilterSettingsStore
import se.ajpanton.notificationlog.settings.LoggingRuleStore import se.ajpanton.notificationsmaster.settings.LoggingRuleStore
import se.ajpanton.notificationlog.settings.LoggingType import se.ajpanton.notificationsmaster.settings.LoggingType
import se.ajpanton.notificationlog.settings.NotificationListenerComponentController import se.ajpanton.notificationsmaster.settings.NotificationListenerComponentController
import se.ajpanton.notificationlog.settings.PerAppEventSettingsStore import se.ajpanton.notificationsmaster.settings.PerAppEventSettingsStore
class NotificationLogApplication : Application() { class NotificationLogApplication : Application() {
override fun onCreate() { override fun onCreate() {
@@ -1,10 +1,10 @@
package se.ajpanton.notificationlog package se.ajpanton.notificationsmaster
import android.os.Bundle import android.os.Bundle
import android.view.View import android.view.View
import androidx.annotation.StringRes import androidx.annotation.StringRes
import androidx.fragment.app.Fragment import androidx.fragment.app.Fragment
import se.ajpanton.notificationlog.databinding.FragmentPageBinding import se.ajpanton.notificationsmaster.databinding.FragmentPageBinding
class PageFragment : Fragment(R.layout.fragment_page) { class PageFragment : Fragment(R.layout.fragment_page) {
private var binding: FragmentPageBinding? = null private var binding: FragmentPageBinding? = null
@@ -1,4 +1,4 @@
package se.ajpanton.notificationlog package se.ajpanton.notificationsmaster
import android.content.Context import android.content.Context
import android.graphics.Canvas import android.graphics.Canvas
@@ -1,4 +1,4 @@
package se.ajpanton.notificationlog package se.ajpanton.notificationsmaster
import android.os.Bundle import android.os.Bundle
import android.net.Uri import android.net.Uri
@@ -9,17 +9,17 @@ import android.view.View
import androidx.fragment.app.Fragment import androidx.fragment.app.Fragment
import androidx.lifecycle.lifecycleScope import androidx.lifecycle.lifecycleScope
import com.google.android.material.dialog.MaterialAlertDialogBuilder import com.google.android.material.dialog.MaterialAlertDialogBuilder
import se.ajpanton.notificationlog.databinding.FragmentSettingsBinding import se.ajpanton.notificationsmaster.databinding.FragmentSettingsBinding
import se.ajpanton.notificationlog.settings.LogField import se.ajpanton.notificationsmaster.settings.LogField
import se.ajpanton.notificationlog.settings.LogViewSettingsStore import se.ajpanton.notificationsmaster.settings.LogViewSettingsStore
import se.ajpanton.notificationlog.settings.AppLockStore import se.ajpanton.notificationsmaster.settings.AppLockStore
import se.ajpanton.notificationlog.data.EncryptedNotificationLogStore import se.ajpanton.notificationsmaster.data.EncryptedNotificationLogStore
import se.ajpanton.notificationlog.data.EncryptedImageStore import se.ajpanton.notificationsmaster.data.EncryptedImageStore
import se.ajpanton.notificationlog.capture.NotificationCaptureService import se.ajpanton.notificationsmaster.capture.NotificationCaptureService
import se.ajpanton.notificationlog.export.LogExporter import se.ajpanton.notificationsmaster.export.LogExporter
import se.ajpanton.notificationlog.settings.StorageLimits import se.ajpanton.notificationsmaster.settings.StorageLimits
import se.ajpanton.notificationlog.settings.StorageLimitsStore import se.ajpanton.notificationsmaster.settings.StorageLimitsStore
import se.ajpanton.notificationlog.settings.LogAppFilterStore import se.ajpanton.notificationsmaster.settings.LogAppFilterStore
import java.util.zip.ZipOutputStream import java.util.zip.ZipOutputStream
import kotlinx.coroutines.Dispatchers import kotlinx.coroutines.Dispatchers
import kotlinx.coroutines.launch import kotlinx.coroutines.launch
@@ -148,7 +148,7 @@ class SettingsFragment : Fragment(R.layout.fragment_settings) {
private fun writeCsv( private fun writeCsv(
writer: java.io.BufferedWriter, writer: java.io.BufferedWriter,
logStore: EncryptedNotificationLogStore, logStore: EncryptedNotificationLogStore,
settings: se.ajpanton.notificationlog.settings.LogViewSettings, settings: se.ajpanton.notificationsmaster.settings.LogViewSettings,
context: android.content.Context, context: android.content.Context,
) = writer.use { ) = writer.use {
it.write(LogExporter.csvHeader(settings)) it.write(LogExporter.csvHeader(settings))
@@ -161,7 +161,7 @@ class SettingsFragment : Fragment(R.layout.fragment_settings) {
private fun writeFormatted( private fun writeFormatted(
writer: java.io.BufferedWriter, writer: java.io.BufferedWriter,
logStore: EncryptedNotificationLogStore, logStore: EncryptedNotificationLogStore,
settings: se.ajpanton.notificationlog.settings.LogViewSettings, settings: se.ajpanton.notificationsmaster.settings.LogViewSettings,
context: android.content.Context, context: android.content.Context,
) = writer.use { ) = writer.use {
val headers = LogExporter.headers(settings) val headers = LogExporter.headers(settings)
@@ -181,7 +181,7 @@ class SettingsFragment : Fragment(R.layout.fragment_settings) {
private fun writeHtmlZip( private fun writeHtmlZip(
zip: ZipOutputStream, zip: ZipOutputStream,
logStore: EncryptedNotificationLogStore, logStore: EncryptedNotificationLogStore,
settings: se.ajpanton.notificationlog.settings.LogViewSettings, settings: se.ajpanton.notificationsmaster.settings.LogViewSettings,
context: android.content.Context, context: android.content.Context,
) = zip.use { zipOutput -> ) = zip.use { zipOutput ->
val imageStore = EncryptedImageStore(context) val imageStore = EncryptedImageStore(context)
@@ -1,4 +1,4 @@
package se.ajpanton.notificationlog package se.ajpanton.notificationsmaster
import android.animation.Animator import android.animation.Animator
import android.animation.AnimatorListenerAdapter import android.animation.AnimatorListenerAdapter
@@ -18,19 +18,19 @@ import android.widget.ImageView
import android.widget.LinearLayout import android.widget.LinearLayout
import android.widget.TextView import android.widget.TextView
import com.google.android.material.dialog.MaterialAlertDialogBuilder import com.google.android.material.dialog.MaterialAlertDialogBuilder
import se.ajpanton.notificationlog.data.EncryptedImageStore import se.ajpanton.notificationsmaster.data.EncryptedImageStore
import se.ajpanton.notificationlog.data.EncryptedNotificationLogStore import se.ajpanton.notificationsmaster.data.EncryptedNotificationLogStore
import se.ajpanton.notificationlog.data.NewestLogCursor import se.ajpanton.notificationsmaster.data.NewestLogCursor
import se.ajpanton.notificationlog.databinding.FragmentViewLogsBinding import se.ajpanton.notificationsmaster.databinding.FragmentViewLogsBinding
import se.ajpanton.notificationlog.model.NotificationAction import se.ajpanton.notificationsmaster.model.NotificationAction
import se.ajpanton.notificationlog.model.NotificationLogEntry import se.ajpanton.notificationsmaster.model.NotificationLogEntry
import se.ajpanton.notificationlog.settings.LogField import se.ajpanton.notificationsmaster.settings.LogField
import se.ajpanton.notificationlog.settings.LogViewSettings import se.ajpanton.notificationsmaster.settings.LogViewSettings
import se.ajpanton.notificationlog.settings.LogViewSettingsStore import se.ajpanton.notificationsmaster.settings.LogViewSettingsStore
import se.ajpanton.notificationlog.settings.LogAppFilterStore import se.ajpanton.notificationsmaster.settings.LogAppFilterStore
import se.ajpanton.notificationlog.settings.TimestampFormatter import se.ajpanton.notificationsmaster.settings.TimestampFormatter
import se.ajpanton.notificationlog.settings.DisplayEvent import se.ajpanton.notificationsmaster.settings.DisplayEvent
import se.ajpanton.notificationlog.capture.NotificationCaptureService import se.ajpanton.notificationsmaster.capture.NotificationCaptureService
import androidx.fragment.app.Fragment import androidx.fragment.app.Fragment
import androidx.core.content.ContextCompat import androidx.core.content.ContextCompat
import androidx.core.view.doOnPreDraw import androidx.core.view.doOnPreDraw
@@ -1,4 +1,4 @@
package se.ajpanton.notificationlog package se.ajpanton.notificationsmaster
import android.content.Context import android.content.Context
import android.graphics.Bitmap import android.graphics.Bitmap
@@ -1,6 +1,6 @@
package se.ajpanton.notificationlog.capture package se.ajpanton.notificationsmaster.capture
import se.ajpanton.notificationlog.model.NotificationAction import se.ajpanton.notificationsmaster.model.NotificationAction
/** Applies the global, Android-provided group-summary classification without inspecting text. */ /** Applies the global, Android-provided group-summary classification without inspecting text. */
object GroupSummaryPolicy { object GroupSummaryPolicy {
@@ -1,20 +1,20 @@
package se.ajpanton.notificationlog.capture package se.ajpanton.notificationsmaster.capture
import android.app.Notification import android.app.Notification
import android.content.pm.PackageManager import android.content.pm.PackageManager
import android.service.notification.NotificationListenerService import android.service.notification.NotificationListenerService
import android.service.notification.StatusBarNotification import android.service.notification.StatusBarNotification
import android.util.Log import android.util.Log
import se.ajpanton.notificationlog.data.EncryptedNotificationLogStore import se.ajpanton.notificationsmaster.data.EncryptedNotificationLogStore
import se.ajpanton.notificationlog.data.EncryptedImageStore import se.ajpanton.notificationsmaster.data.EncryptedImageStore
import se.ajpanton.notificationlog.model.NotificationAction import se.ajpanton.notificationsmaster.model.NotificationAction
import se.ajpanton.notificationlog.model.NotificationLogEntry import se.ajpanton.notificationsmaster.model.NotificationLogEntry
import se.ajpanton.notificationlog.settings.LoggingRuleStore import se.ajpanton.notificationsmaster.settings.LoggingRuleStore
import se.ajpanton.notificationlog.settings.LoggingType import se.ajpanton.notificationsmaster.settings.LoggingType
import se.ajpanton.notificationlog.settings.NotificationRuleEvaluator import se.ajpanton.notificationsmaster.settings.NotificationRuleEvaluator
import se.ajpanton.notificationlog.settings.CaptureSettingsStore import se.ajpanton.notificationsmaster.settings.CaptureSettingsStore
import se.ajpanton.notificationlog.settings.AppFilterSettingsStore import se.ajpanton.notificationsmaster.settings.AppFilterSettingsStore
import se.ajpanton.notificationlog.settings.PerAppEventSettingsStore import se.ajpanton.notificationsmaster.settings.PerAppEventSettingsStore
import java.util.concurrent.ExecutorService import java.util.concurrent.ExecutorService
import java.util.concurrent.Executors import java.util.concurrent.Executors
@@ -1,4 +1,4 @@
package se.ajpanton.notificationlog.capture package se.ajpanton.notificationsmaster.capture
/** Keeps update classification deterministic and independently testable. */ /** Keeps update classification deterministic and independently testable. */
object NotificationChangeClassifier { object NotificationChangeClassifier {
@@ -1,4 +1,4 @@
package se.ajpanton.notificationlog.capture package se.ajpanton.notificationsmaster.capture
import android.app.Notification import android.app.Notification
import android.content.Context import android.content.Context
@@ -1,4 +1,4 @@
package se.ajpanton.notificationlog.capture package se.ajpanton.notificationsmaster.capture
import java.util.concurrent.ConcurrentHashMap import java.util.concurrent.ConcurrentHashMap
@@ -1,4 +1,4 @@
package se.ajpanton.notificationlog.data package se.ajpanton.notificationsmaster.data
import javax.crypto.Cipher import javax.crypto.Cipher
import javax.crypto.SecretKey import javax.crypto.SecretKey
@@ -1,4 +1,4 @@
package se.ajpanton.notificationlog.data package se.ajpanton.notificationsmaster.data
import android.content.Context import android.content.Context
import android.util.AtomicFile import android.util.AtomicFile
@@ -1,9 +1,9 @@
package se.ajpanton.notificationlog.data package se.ajpanton.notificationsmaster.data
import android.content.Context import android.content.Context
import android.util.AtomicFile import android.util.AtomicFile
import se.ajpanton.notificationlog.model.NotificationLogEntry import se.ajpanton.notificationsmaster.model.NotificationLogEntry
import se.ajpanton.notificationlog.settings.StorageLimitsStore import se.ajpanton.notificationsmaster.settings.StorageLimitsStore
import java.io.BufferedInputStream import java.io.BufferedInputStream
import java.io.BufferedOutputStream import java.io.BufferedOutputStream
import java.io.DataInputStream import java.io.DataInputStream
@@ -1,4 +1,4 @@
package se.ajpanton.notificationlog.data package se.ajpanton.notificationsmaster.data
import android.security.keystore.KeyGenParameterSpec import android.security.keystore.KeyGenParameterSpec
import android.security.keystore.KeyProperties import android.security.keystore.KeyProperties
@@ -1,9 +1,9 @@
package se.ajpanton.notificationlog.data package se.ajpanton.notificationsmaster.data
import org.json.JSONArray import org.json.JSONArray
import org.json.JSONObject import org.json.JSONObject
import se.ajpanton.notificationlog.model.NotificationAction import se.ajpanton.notificationsmaster.model.NotificationAction
import se.ajpanton.notificationlog.model.NotificationLogEntry import se.ajpanton.notificationsmaster.model.NotificationLogEntry
/** Versioned, private plaintext representation which is encrypted before it reaches disk. */ /** Versioned, private plaintext representation which is encrypted before it reaches disk. */
object NotificationLogEntryJson { object NotificationLogEntryJson {
@@ -1,10 +1,10 @@
package se.ajpanton.notificationlog.export package se.ajpanton.notificationsmaster.export
import android.content.Context import android.content.Context
import se.ajpanton.notificationlog.model.NotificationLogEntry import se.ajpanton.notificationsmaster.model.NotificationLogEntry
import se.ajpanton.notificationlog.settings.LogField import se.ajpanton.notificationsmaster.settings.LogField
import se.ajpanton.notificationlog.settings.LogViewSettings import se.ajpanton.notificationsmaster.settings.LogViewSettings
import se.ajpanton.notificationlog.settings.TimestampFormatter import se.ajpanton.notificationsmaster.settings.TimestampFormatter
object LogExporter { object LogExporter {
fun csv(entries: List<NotificationLogEntry>, settings: LogViewSettings, context: Context? = null): String = ( fun csv(entries: List<NotificationLogEntry>, settings: LogViewSettings, context: Context? = null): String = (
@@ -1,4 +1,4 @@
package se.ajpanton.notificationlog.model package se.ajpanton.notificationsmaster.model
import java.util.UUID import java.util.UUID
@@ -1,4 +1,4 @@
package se.ajpanton.notificationlog.settings package se.ajpanton.notificationsmaster.settings
import android.content.Context import android.content.Context
import androidx.core.content.edit import androidx.core.content.edit
@@ -1,4 +1,4 @@
package se.ajpanton.notificationlog.settings package se.ajpanton.notificationsmaster.settings
data class ListedApp( data class ListedApp(
val label: String, val label: String,
@@ -1,4 +1,4 @@
package se.ajpanton.notificationlog.settings package se.ajpanton.notificationsmaster.settings
import android.content.Context import android.content.Context
import androidx.core.content.edit import androidx.core.content.edit
@@ -1,4 +1,4 @@
package se.ajpanton.notificationlog.settings package se.ajpanton.notificationsmaster.settings
import android.content.Context import android.content.Context
import androidx.core.content.edit import androidx.core.content.edit
@@ -1,4 +1,4 @@
package se.ajpanton.notificationlog.settings package se.ajpanton.notificationsmaster.settings
import android.content.Context import android.content.Context
import androidx.core.content.edit import androidx.core.content.edit
@@ -1,4 +1,4 @@
package se.ajpanton.notificationlog.settings package se.ajpanton.notificationsmaster.settings
enum class LogField { TIMESTAMP, APP_NAME, PACKAGE_NAME, ACTION, CONTENTS } enum class LogField { TIMESTAMP, APP_NAME, PACKAGE_NAME, ACTION, CONTENTS }
enum class TimestampZone { EVENT_LOCAL, LOCAL_NOW, UTC } enum class TimestampZone { EVENT_LOCAL, LOCAL_NOW, UTC }
@@ -1,4 +1,4 @@
package se.ajpanton.notificationlog.settings package se.ajpanton.notificationsmaster.settings
import android.content.Context import android.content.Context
import androidx.core.content.edit import androidx.core.content.edit
@@ -1,4 +1,4 @@
package se.ajpanton.notificationlog.settings package se.ajpanton.notificationsmaster.settings
import android.content.Context import android.content.Context
import androidx.core.content.edit import androidx.core.content.edit
@@ -1,4 +1,4 @@
package se.ajpanton.notificationlog.settings package se.ajpanton.notificationsmaster.settings
enum class LoggingType { enum class LoggingType {
APPEARING, APPEARING,
@@ -1,11 +1,11 @@
package se.ajpanton.notificationlog.settings package se.ajpanton.notificationsmaster.settings
import android.content.ComponentName import android.content.ComponentName
import android.content.Context import android.content.Context
import android.content.pm.PackageManager import android.content.pm.PackageManager
import android.service.notification.NotificationListenerService import android.service.notification.NotificationListenerService
import android.util.Log import android.util.Log
import se.ajpanton.notificationlog.capture.NotificationCaptureService import se.ajpanton.notificationsmaster.capture.NotificationCaptureService
/** /**
* Notification listeners are re-bound by Android after boot when their component * Notification listeners are re-bound by Android after boot when their component
@@ -1,4 +1,4 @@
package se.ajpanton.notificationlog.settings package se.ajpanton.notificationsmaster.settings
/** The listener is useful only when at least one event type is enabled. */ /** The listener is useful only when at least one event type is enabled. */
object NotificationListenerPolicy { object NotificationListenerPolicy {
@@ -1,4 +1,4 @@
package se.ajpanton.notificationlog.settings package se.ajpanton.notificationsmaster.settings
object NotificationRuleEvaluator { object NotificationRuleEvaluator {
fun allows(filter: AppFilterSettings, packageName: String): Boolean { fun allows(filter: AppFilterSettings, packageName: String): Boolean {
@@ -1,4 +1,4 @@
package se.ajpanton.notificationlog.settings package se.ajpanton.notificationsmaster.settings
import android.content.Context import android.content.Context
import androidx.core.content.edit import androidx.core.content.edit
@@ -1,4 +1,4 @@
package se.ajpanton.notificationlog.settings package se.ajpanton.notificationsmaster.settings
import android.content.Context import android.content.Context
import androidx.core.content.edit import androidx.core.content.edit
@@ -1,4 +1,4 @@
package se.ajpanton.notificationlog.settings package se.ajpanton.notificationsmaster.settings
import android.content.Context import android.content.Context
import android.text.format.DateFormat as AndroidDateFormat import android.text.format.DateFormat as AndroidDateFormat
+2 -2
View File
@@ -3,7 +3,7 @@
android:layout_width="match_parent" android:layout_width="match_parent"
android:layout_height="match_parent"> android:layout_height="match_parent">
<se.ajpanton.notificationlog.SafeInsetDrawerLayout <se.ajpanton.notificationsmaster.SafeInsetDrawerLayout
xmlns:app="http://schemas.android.com/apk/res-auto" xmlns:app="http://schemas.android.com/apk/res-auto"
android:id="@+id/drawer_layout" android:id="@+id/drawer_layout"
android:layout_width="match_parent" android:layout_width="match_parent"
@@ -65,7 +65,7 @@
app:itemTextColor="@color/drawer_item_text_color" app:itemTextColor="@color/drawer_item_text_color"
app:menu="@menu/drawer_menu" /> app:menu="@menu/drawer_menu" />
</se.ajpanton.notificationlog.SafeInsetDrawerLayout> </se.ajpanton.notificationsmaster.SafeInsetDrawerLayout>
<LinearLayout <LinearLayout
android:id="@+id/lock_overlay" android:id="@+id/lock_overlay"
@@ -1,9 +1,9 @@
package se.ajpanton.notificationlog.capture package se.ajpanton.notificationsmaster.capture
import org.junit.Assert.assertFalse import org.junit.Assert.assertFalse
import org.junit.Assert.assertTrue import org.junit.Assert.assertTrue
import org.junit.Test import org.junit.Test
import se.ajpanton.notificationlog.model.NotificationAction import se.ajpanton.notificationsmaster.model.NotificationAction
class GroupSummaryPolicyTest { class GroupSummaryPolicyTest {
private fun snapshot(isGroupSummary: Boolean) = NotificationSnapshot( private fun snapshot(isGroupSummary: Boolean) = NotificationSnapshot(
@@ -1,4 +1,4 @@
package se.ajpanton.notificationlog.capture package se.ajpanton.notificationsmaster.capture
import org.junit.Assert.assertFalse import org.junit.Assert.assertFalse
import org.junit.Assert.assertTrue import org.junit.Assert.assertTrue
@@ -1,4 +1,4 @@
package se.ajpanton.notificationlog.capture package se.ajpanton.notificationsmaster.capture
import org.junit.Assert.assertEquals import org.junit.Assert.assertEquals
import org.junit.Test import org.junit.Test
@@ -1,4 +1,4 @@
package se.ajpanton.notificationlog.data package se.ajpanton.notificationsmaster.data
import org.junit.Assert.assertFalse import org.junit.Assert.assertFalse
import org.junit.Assert.assertTrue import org.junit.Assert.assertTrue
@@ -1,15 +1,15 @@
package se.ajpanton.notificationlog.export package se.ajpanton.notificationsmaster.export
import org.junit.Assert.assertFalse import org.junit.Assert.assertFalse
import org.junit.Assert.assertEquals import org.junit.Assert.assertEquals
import org.junit.Assert.assertTrue import org.junit.Assert.assertTrue
import org.junit.Test import org.junit.Test
import se.ajpanton.notificationlog.model.NotificationAction import se.ajpanton.notificationsmaster.model.NotificationAction
import se.ajpanton.notificationlog.model.NotificationLogEntry import se.ajpanton.notificationsmaster.model.NotificationLogEntry
import se.ajpanton.notificationlog.settings.LogViewSettings import se.ajpanton.notificationsmaster.settings.LogViewSettings
import se.ajpanton.notificationlog.settings.TimestampClockFormat import se.ajpanton.notificationsmaster.settings.TimestampClockFormat
import se.ajpanton.notificationlog.settings.TimestampDateFormat import se.ajpanton.notificationsmaster.settings.TimestampDateFormat
import se.ajpanton.notificationlog.settings.TimestampZone import se.ajpanton.notificationsmaster.settings.TimestampZone
class LogExporterTest { class LogExporterTest {
private val imageEntry = NotificationLogEntry( private val imageEntry = NotificationLogEntry(
@@ -1,4 +1,4 @@
package se.ajpanton.notificationlog.settings package se.ajpanton.notificationsmaster.settings
import org.junit.Assert.assertEquals import org.junit.Assert.assertEquals
import org.junit.Test import org.junit.Test
@@ -1,4 +1,4 @@
package se.ajpanton.notificationlog.settings package se.ajpanton.notificationsmaster.settings
import org.junit.Assert.assertTrue import org.junit.Assert.assertTrue
import org.junit.Test import org.junit.Test
@@ -1,4 +1,4 @@
package se.ajpanton.notificationlog.settings package se.ajpanton.notificationsmaster.settings
import org.junit.Assert.assertFalse import org.junit.Assert.assertFalse
import org.junit.Assert.assertTrue import org.junit.Assert.assertTrue
@@ -1,4 +1,4 @@
package se.ajpanton.notificationlog.settings package se.ajpanton.notificationsmaster.settings
import org.junit.Assert.assertFalse import org.junit.Assert.assertFalse
import org.junit.Assert.assertTrue import org.junit.Assert.assertTrue
+2 -2
View File
@@ -1,6 +1,6 @@
plugins { alias(libs.plugins.android.application); alias(libs.plugins.kotlin.android) } plugins { alias(libs.plugins.android.application); alias(libs.plugins.kotlin.android) }
android { namespace = "se.ajpanton.notificationlog.helper"; compileSdk = 36 android { namespace = "se.ajpanton.notificationsmaster.helper"; compileSdk = 36
defaultConfig { applicationId = "se.ajpanton.notificationlog.helper"; minSdk = 34; targetSdk = 36; versionCode = 1; versionName = "0.1" } defaultConfig { applicationId = "se.ajpanton.notificationsmaster.helper"; minSdk = 34; targetSdk = 36; versionCode = 1; versionName = "0.1" }
compileOptions { sourceCompatibility = JavaVersion.VERSION_17; targetCompatibility = JavaVersion.VERSION_17 } compileOptions { sourceCompatibility = JavaVersion.VERSION_17; targetCompatibility = JavaVersion.VERSION_17 }
kotlin { compilerOptions { jvmTarget.set(org.jetbrains.kotlin.gradle.dsl.JvmTarget.JVM_17) } } kotlin { compilerOptions { jvmTarget.set(org.jetbrains.kotlin.gradle.dsl.JvmTarget.JVM_17) } }
} }
@@ -1,4 +1,4 @@
package se.ajpanton.notificationlog.helper package se.ajpanton.notificationsmaster.helper
import android.app.Notification import android.app.Notification
import android.app.NotificationChannel import android.app.NotificationChannel