Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix issue #3245 #3251

Open
wants to merge 6 commits into
base: release/3.7
Choose a base branch
from

Conversation

happys2333
Copy link

Description

Fixes #3245

Issue tracker

Automatic tests

  • Added test cases

Manual tests

  • Done
  • Device: OPPO A33m
  • OS:Android 5.1.1 - 22

Build tasks success

Successfully running following tasks on local:

  • ./gradlew assembledebug
  • ./gradlew spotlessCheck

Array out of index bug fix

While I fixing this bug I found another bug in removing the hidden files. If you remove more than one file at one time, you will find the hiddenFiles array's index will get wrong. I found that the index was not updated at the time of deletion. So I added in the source code that every delete must be reindexed. If you do not add this, you will end up with an array out of bounds or removing the wrong file when you remove hidden files multiple times.

});
googleThread.start();
try{
googleThread.join();
Copy link
Member

Choose a reason for hiding this comment

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

No joining threads in main thread

Copy link
Author

Choose a reason for hiding this comment

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

Any suggestions? I can't find a way to change it.

Copy link
Author

Choose a reason for hiding this comment

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

The new code has update.

@VishalNehra
Copy link
Member

please fix #3262 with this as well

@@ -81,7 +81,7 @@ class MainActivityActionMode(private val mainActivityReference: WeakReference<Ma
hideOption(R.id.share, menu)
hideOption(R.id.openwith, menu)
if (mainActivity.mReturnIntent) showOption(R.id.openmulti, menu)
// hideOption(R.id.setringtone,menu);
// hideOption(R.id.setringtone,menu);
Copy link
Member

Choose a reason for hiding this comment

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

Don't leave commented code.

@@ -466,7 +466,7 @@ public String getParentName() {

/**
* Whether this object refers to a directory or file, handles all types of files
*
* Warning: Can't be used directly in UI/main thread
Copy link
Member

Choose a reason for hiding this comment

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

This should be a @WorkerThread annotation.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

isDirectory from amaze cloud called on ui thread
3 participants