Closed
Bug 785955
Opened 12 years ago
Closed 12 years ago
Device Storage - Filter out mimetypes based on device storage type
Categories
(Core :: DOM: Device Interfaces, defect)
Core
DOM: Device Interfaces
Tracking
()
People
(Reporter: dougt, Assigned: dougt)
References
Details
Attachments
(1 file)
6.04 KB,
patch
|
sicking
:
review+
|
Details | Diff | Splinter Review |
Currently, when you enumerate a directory, we return files that shouldn't be returned. For example, if you ask for a 'pictures' device storage object and in that directory there are files that are not pictures, currently we return those. What I'd like to do is to filter those files out of the enumeration. This will be very helpful when we start enumerating the SDCard for Gaia/B2G
Assignee | ||
Comment 1•12 years ago
|
||
I'd like to keep the DEBUG_ISTYPE code in for a while. This will help aide in gaia debugging.
Attachment #655657 -
Flags: review?(jonas)
Updated•12 years ago
|
blocking-basecamp: --- → ?
Comment on attachment 655657 [details] [diff] [review] patch v.1 Review of attachment 655657 [details] [diff] [review]: ----------------------------------------------------------------- Let me know what you think about using the properties file instead. I think the current approach would be ok, but we'd need to check that the registry on B2G contains good defaults. ::: dom/devicestorage/nsDeviceStorage.cpp @@ +150,5 @@ > return true; > } > > +bool > +DeviceStorageFile::IsType(nsAString& aType) You'd likely get better results by using the values from the chrome://global/content/filepicker.properties file. I.e. the imageFilter, audioFilter and videoFilter properties there. That's what we're using in the filepicker and has the nice advantage that it doesn't depend on the OS registry and so will produce more consistent results.
Assignee | ||
Comment 4•12 years ago
|
||
Yes, we definitely will have to do that. I can do that as a followup, if you don't mind. I filled 786922
Attachment #655657 -
Flags: review?(jonas) → review+
Assignee | ||
Comment 5•12 years ago
|
||
https://hg.mozilla.org/integration/mozilla-inbound/rev/9c497a6e9e0f
Comment 6•12 years ago
|
||
https://hg.mozilla.org/mozilla-central/rev/9c497a6e9e0f
Status: NEW → RESOLVED
Closed: 12 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla18
You need to log in
before you can comment on or make changes to this bug.
Description
•