Back gesture in photo viewer causes cascading exit (closes photo and album)

オープン
#1,200 コメント 0 件 リアクション 0 件 担当者 0 名 GitHub で見る

メンテナーはふだん 1 日以内に返信

まだ誰も着手していません。

評価

難易度
4/5
見積もり時間
3〜5日
初心者へのやさしさ
45/100
issue の種類
バグ
明瞭さ
おおむね明確
活発さ
活発
技術スタック
android, kotlin
領域
mobile

調査の方向性

Start in ViewPagerFragment, where swipe-down dismissal handles ACTION_CANCEL the same as ACTION_UP, then check how MediaActivity resumes and consumes back key input. The issue names no test, so reproduce on an Android device or emulator with gesture navigation. Done means a back gesture dismisses only the photo, whether the swipe is quick or slow, and the album stays open.

索引モデルが issue の本文から書いたものです。

説明

bug needs triage
Checklist
  • I can reproduce the bug with the latest version given here.
  • I made sure that there are no existing issues - open or closed - to which I could contribute my information.
  • I made sure that there are no existing discussions - open or closed - to which I could contribute my information.
  • I have read the FAQs inside the app (Menu -> About -> FAQs) and my problem isn't listed.
  • I have taken the time to fill in all the required details. I understand that the bug report will be dismissed otherwise.
  • This issue contains only one bug.
  • I have read and understood the contribution guidelines.
Affected app version

1.14.1

Affected Android/Custom ROM version

Android 13 / crDroid 9.9 (LineageOS 20 based)

Affected device model

Realme 8 (RMX3085)

How did you install the app?

GitHub releases

Steps to reproduce the bug
  1. Open any album and tap a photo to open it full screen.
  2. Perform a back gesture from the edge of the screen using Android system gesture navigation.
  3. Notice that if the swipe is held briefly or performed slowly, the gesture dismisses the photo, immediately falls through to the underlying album view, and exits to the home launcher.
Expected behavior

The back gesture should only dismiss the current photo and return to the album view, regardless of whether the gesture is flicked quickly or held.

Actual behavior

Both the photo viewer and album view exit in quick succession, dumping the user out of the app to the home launcher.

Screenshots/Screen recordings

No response

Additional information

Root cause analysis:

  1. In ViewPagerFragment, ACTION_CANCEL was treated identically to ACTION_UP in swipe-down dismissal logic. When an edge back gesture begins, the system gesture monitor steals the touch channel (sending ACTION_CANCEL), which prematurely triggered activity?.finish() while the user was still swiping.
  2. When the underlying MediaActivity resumed while the gesture was still finishing or repeating back events, it immediately consumed the trailing back input.

I already have an end-to-end fix implemented and tested on my physical device (separating ACTION_CANCEL, debouncing activity transition back inputs, and filtering repeat back key events).

Please label this issue as 'help wanted' so I can contribute the fix via a pull request.

主要言語
Kotlin
スター
3.8k
フォーク
270
平均マージ
1日 6時間
マージ済み PR(30日)
7

環境構築

はじめの一歩

  1. issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
  2. 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
  3. リポジトリをフォークし、ブランチを切って変更します。
  4. issue 番号を参照したプルリクエストを送ります。

FossifyOrg/Gallery のほかの issue

FossifyOrg/Gallery の issue をすべて見る

似ている issue

Kotlin の issue をもっと見る

新しい issue をメールで受け取る

初心者向けの GitHub issue を短くまとめたダイジェスト。