Closed Bug 1231129 Opened 9 years ago Closed 9 years ago

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

Categories

(DevTools :: about:debugging, defect)

defect
Not set
normal

Tracking

(Not tracked)

RESOLVED WORKSFORME

People

(Reporter: rhelmer, Assigned: rhelmer)

References

Details

Attachments

(1 file)

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.
Status: NEW → ASSIGNED
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)
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
Closed: 9 years ago
Resolution: --- → WORKSFORME
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.
(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.
See also: bug 1249315
I'll try changing the prompt in bug 1256246
Product: Firefox → DevTools
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: