Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions app/src/main/java/one/mixin/android/MixinApplication.kt
Original file line number Diff line number Diff line change
Expand Up @@ -459,6 +459,7 @@ open class MixinApplication :
val appAuth = defaultSharedPreferences.getInt(Constants.Account.PREF_APP_AUTH, -1)
if (appAuth != -1) {
if (appAuth == 0) {
appAuthShown = true
AppAuthActivity.show(activity)
return true
} else {
Expand All @@ -472,6 +473,7 @@ open class MixinApplication :
Constants.INTERVAL_30_MINS
}
if (now - enterBackground > offset) {
appAuthShown = true
AppAuthActivity.show(activity)
return true
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -1220,8 +1220,8 @@ class ConversationFragment() :
private var lastReadMessage: String? = null

override fun onPause() {
// don't stop audio player if triggered by screen off
if (powerManager.isInteractive) {
// don't stop audio player if triggered by screen off or app lock overlay
Copy link

Copilot AI Jan 27, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The comment refers to "app lock overlay" but AppAuthActivity is a separate activity, not an overlay. Consider updating the comment to say "app lock screen" or "app authentication" for accuracy.

Suggested change
// don't stop audio player if triggered by screen off or app lock overlay
// don't stop audio player if triggered by screen off or app lock screen

Copilot uses AI. Check for mistakes.
if (powerManager.isInteractive && !MixinApplication.get().isAppAuthShown()) {
AudioPlayer.pause()
}
sensorManager.unregisterListener(this)
Expand Down
Loading