Cannot select directory in "Select Add-on Directory or XPI File" dialog

RESOLVED DUPLICATE of bug 1256246

Status

DevTools
about:debugging
RESOLVED DUPLICATE of bug 1256246
2 years ago
a month ago

People

(Reporter: michielbdejong, Unassigned)

Tracking

Firefox Tracking Flags

(Not tracked)

Details

Attachments

(1 attachment)

(Reporter)

Description

2 years ago
Created attachment 8720843 [details]
open-button-greyed-out.png

Selecting a directory and then clicking 'Open' will open that folder in the filepicker dialog, instead of selecting that directory as the one to open.

Workaround: select a random file inside the directory.

Maybe changing https://mxr.mozilla.org/mozilla-central/source/devtools/client/locales/en-US/aboutdebugging.properties#8 to say "Select manifest.json or XPI File" would make it easier for the user (but not sure how that would affect the way it works on Windows or Linux).
Is it possible to use the file-picker to select either a directory or a file?
(Reporter)

Comment 2

2 years ago
IANAMD (I am not a Mac developer), but it looks like you can specify both the 'canChooseFiles' and 'canChooseDirectories' in https://developer.apple.com/library/mac/documentation/Cocoa/Reference/ApplicationKit/Classes/NSOpenPanel_Class/index.html - so if it's possible in Cocoa, I guess that means the OS supports it.

Comment 3

2 years ago
Its probably the nsIFilePicker that's the problem as rhelmer describes here: https://bugzilla.mozilla.org/show_bug.cgi?id=1231129#c0

Comment 4

2 years ago
Alex, could you please have a look at this?
Flags: needinfo?(poirot.alex)
I'm off next week. So I won't be able to look into this until Monday 14th.
You are welcome to contribute to addons.
Tweaking the localization string, as noted in bug 1231129 comment 4 would help a lot.
Flags: needinfo?(poirot.alex)
> Maybe changing ... to say "Select manifest.json or XPI File" would make it easier for the user

I'm going to try this in bug 1256246
Michiel, Can we consider this bug as a duplicate of bug 1256246 and close it?
Kumar changed the string to:
  Select Manifest File or Package (.xpi)
(Reporter)

Comment 8

2 years ago
Yes, great!
Status: NEW → RESOLVED
Last Resolved: 2 years ago
Resolution: --- → DUPLICATE
Duplicate of bug: 1256246
Duplicate of this bug: 1266666

Updated

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