TeamAmaze / TeamAmaze/AmazeFileManager

Back button closes Amaze whilst exploring compressed files

Open
#3,127 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Area-Compression Area-UIUX Issue-Bug
Dominant language
Kotlin
Stars
6.4k
Forks
1.7k
Avg merge
3d 9h
Merged PRs (30d)
1

Description

Click on a .zip file -> choose Amaze Debug -> the content opens -> click back button -> Amaze closes

I think this is a bad user flow. We would want to let the user back to the previous location. What do you think?

OK, as of this PR, when back button is pressed, it goes to here:

https://github.com/TeamAmaze/AmazeFileManager/blob/31b33f8cc9f0b505bad902afa55fce55d90e03f5/app/src/main/java/com/amaze/filemanager/ui/activities/MainActivity.java#L848-L868

When the zip is opened in an Intent, openzip will be true here, causing line 854 to run, which will result in a finish().

Any idea to work around this without breaking previous behaviour(?), or should this behaviour be changed? Note however, open compressed file Intents shall not be triggered solely from Amaze, but possibly from other apps as well.

Originally posted by @TranceLove in https://github.com/TeamAmaze/AmazeFileManager/issues/2806#issuecomment-922487606

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start with app/src/main/java/com/amaze/filemanager/ui/activities/MainActivity.java at lines 848-868 and reproduce the .zip-to-Amaze Debug flow. Inspect how the openzip condition handles the back button when the file was opened by an external Intent. Done means back returns to the previous location instead of closing Amaze while preserving existing behavior for other entry paths.

Written by the indexing model from the issue text.

Assessment

Tech stack
android, kotlin
Domain
mobile
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.