about:debugging temporary add-on loading does not allow picking folders

RESOLVED WORKSFORME

Status

DevTools
about:debugging
RESOLVED WORKSFORME
3 years ago
7 days ago

People

(Reporter: rhelmer, Assigned: rhelmer)

Tracking

Firefox Tracking Flags

(Not tracked)

Details

MozReview Requests

Submitter Diff Changes Open Issues Last Updated
Loading...
Error loading review requests:

Attachments

(1 attachment)

(Assignee)

Description

3 years ago
The nsIFilePicker does not have a mode that can handle both files and folders at the same time.

I think the only reasonable way to do this without platform changes (this is a limitation in the underlying platform implementations) is to have a separate button for loading file or a folder.
(Assignee)

Updated

3 years ago
Status: NEW → ASSIGNED
(Assignee)

Comment 1

3 years ago
Created attachment 8696685 [details]
MozReview Request: Bug 1231129 - about:debugging should be able to pick temporary add-ons from folders as well as files r?ochameau

Bug 1231129 - about:debugging should be able to pick temporary add-ons from folders as well as files r?ochameau
Attachment #8696685 - Flags: review?(poirot.alex)
(Assignee)

Comment 2

3 years ago
Oh! I see by looking at the tests that you allow picking any file within an unpacked add-on, I think that is better than adding a new button.
Status: ASSIGNED → RESOLVED
Last Resolved: 3 years ago
Resolution: --- → WORKSFORME
(Assignee)

Updated

3 years ago
Attachment #8696685 - Flags: review?(poirot.alex)
I was pretty confused about how to select directories myself. I think a separate button would go a long way in making the UI less confusing.
We may also just rephrase the file picker title,
as even if we select a folder, at the end we end up looking for a file, the install.rdf (do we also accept addons with just manifest.json??).

So what about rephrashing the picker title to something like:

  Select Add-on manifest (install.rdf) or package (xpi file)

And also may be tweak the code check accordingdly, or let it as-is, loose and accept more possibilities than just what the title says as it may just work.
oh yeah, a better prompt would address my UX concerns.
(Assignee)

Comment 6

3 years ago
(In reply to Alexandre Poirot [:ochameau] from comment #4)
> We may also just rephrase the file picker title,
> as even if we select a folder, at the end we end up looking for a file, the
> install.rdf (do we also accept addons with just manifest.json??).
> 
> So what about rephrashing the picker title to something like:
> 
>   Select Add-on manifest (install.rdf) or package (xpi file)

I too like this idea, just a note that now for WebExtensions we support manifest.json as well as install.rdf, so might "(manifest file)" be better than "(install.rdf)"? Or "(install.rdf, manifest.json)" although that seems a bit long...
I think 'manifest file' would be enough to get the point across. The un-intuitive thing for me was that it wouldn't let me select a folder.

Comment 8

2 years ago
See also: bug 1249315
I'll try changing the prompt in bug 1256246

Updated

2 years ago
Duplicate of this bug: 1269910

Updated

7 days ago
Product: Firefox → DevTools
You need to log in before you can comment on or make changes to this bug.