Skip to content

Conversation

@Alok-Silswal
Copy link

@Alok-Silswal Alok-Silswal commented Jan 14, 2026

Purpose / Description

Tapping outside the progress dialog during a forced one-way / full sync can dismiss the dialog and trigger cancellation, interrupting the sync.

Fixes

Approach

Prevent outside-touch from dismissing the progress dialog by explicitly disabling outside-touch cancellation with setCanceledOnTouchOutside(false).

This keeps existing cancel behavior (back button or explicit cancel button where provided) unchanged, while avoiding accidental cancellation from background taps.

How Has This Been Tested?

Bug reproduction (physical device)

  • Forced full sync was triggered via schema change and conflict resolution (“Select collection to keep”).
  • Tapping outside the progress dialog consistently cancelled the sync.

Test environment (reproduction)

  • Device: Redmi K50i
  • Android: 14 (UP1A.231005.007)

Local validation:

  • Emulator: Pixel 6
  • Android: 13 (API 33)
  • System image: Google APIs

In this configuration, outside-touch did not cancel the sync. However, the change is defensive and explicitly prevents outside-touch dismissal of the progress dialog, directly addressing the behavior reported on Android 16 devices.

Checklist

  • You have a descriptive commit message with a short title (first line, max 50 chars).
  • You have commented your code, particularly in hard-to-understand areas
  • You have performed a self-review of your own code
  • UI changes: include screenshots of all affected screens (in particular showing any new or changed strings)
  • UI Changes: You have tested your change using the Google Accessibility Scanner

@david-allison
Copy link
Member

If I'm reading this correctly, you weren't able to replicate the issue before coding a fix? If so, we should close this PR until it can be looked at by someone who can reproduce it

@david-allison david-allison added the Needs Author Reply Waiting for a reply from the original author label Jan 15, 2026
@Alok-Silswal
Copy link
Author

I was able to reproduce the bug in Ankidroid on my device whose specs are as follows:

  • Device: Redmi K50i
  • Android: 14 (UP1A.231005.007)
  • MIUI: 2.0.3.0.ULOINXM

Screen recording and screenshot attached.

Sync issue on outside click bug

Sync.issue.on.outside.click.bug.mp4

Copy link
Member

@david-allison david-allison left a comment

Choose a reason for hiding this comment

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

There looks to be unrelated changes in the 'files changed'.

Could you revert these so we can review only the functional parts of the change.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Needs Author Reply Waiting for a reply from the original author Needs Review New contributor

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Tapping outside of the progress box during a forced, one-way sync cancels the transfer

2 participants