Closed Bug 1298911 Opened 8 years ago Closed 8 years ago

Request to show the default Downloads folder if Downloads folder is removed or inaccessible

Categories

(Toolkit :: Downloads API, defect)

defect
Not set
normal

Tracking

()

RESOLVED WONTFIX

People

(Reporter: whsu, Unassigned)

Details

This might be a legacy issue.
We implemented the dropmarker in FFx 51 nightly, but the "Open Downloads Folder" option brings the different experience in different platforms if Downloads folder is removed or inaccessible (No permission to access).

# Downloads Folder is removed
@ Ubuntu: Re-create the removed folder
@ Mac OS X: Re-create the removed folder
@ Windows: Show the system default download folder


# Downloads Folder is inaccessible (No permission)
@ Ubuntu: System pops up a warning message - "The location could not be displayed"
@ Mac OS X: It shows the content of Downloads folder but user has no permission to access.
@ Windows: TBC

I was wondering if Firefox can show the system default download folder for user in these situations.
e.g., Windows platform redirect to "X:\Users\#USER_NAME\Downloads" and Unix-like system redirects to "/Users/#USER_NAME/Downloads"
(In reply to William Hsu [:whsu] from comment #0)
> I was wondering if Firefox can show the system default download folder for
> user in these situations.

I assume you have customized the downloads folder from the preferences before trying the above? How exactly did you configure the folder to be inaccessible?

We are already supposed to try to create the preferred folder, and if it isn't possible, show the default folder. On some platforms, the default folder must be recreated because it does not exist by default. Here is the code that handles this:

https://dxr.mozilla.org/mozilla-central/source/toolkit/components/jsdownloads/src/DownloadIntegration.jsm#411

For unusual permissions, sometimes we're just unable to detect the situation, as permission settings can be quite nuanced. I'm not sure if there is anything more we can do here.
Component: Downloads Panel → Download Manager
Product: Firefox → Toolkit
Flags: needinfo?(whsu)
(In reply to :Paolo Amadini from comment #1)
> (In reply to William Hsu [:whsu] from comment #0)
> > I was wondering if Firefox can show the system default download folder for
> > user in these situations.
> 
> I assume you have customized the downloads folder from the preferences
> before trying the above? How exactly did you configure the folder to be
> inaccessible?
Yes, my use case is to set a network folder as my downloads folder, and then change the folder permission (chmod 700) to be inaccessible.
 
> We are already supposed to try to create the preferred folder, and if it
> isn't possible, show the default folder. On some platforms, the default
> folder must be recreated because it does not exist by default. Here is the
> code that handles this:
> 
> https://dxr.mozilla.org/mozilla-central/source/toolkit/components/
> jsdownloads/src/DownloadIntegration.jsm#411
Oh! Got it. Thanks for the information.
 
> For unusual permissions, sometimes we're just unable to detect the
> situation, as permission settings can be quite nuanced. I'm not sure if
> there is anything more we can do here.
It seem to me that it is current design. If we have considered these user scenarios, this bug may not be a high priority bug.

Thank you. :)
Flags: needinfo?(whsu)
Status: NEW → RESOLVED
Closed: 8 years ago
Resolution: --- → WONTFIX
You need to log in before you can comment on or make changes to this bug.