Summary: | Cleanup: MIMETypeRegistry functions | ||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|
Product: | WebKit | Reporter: | Said Abou-Hallawa <sabouhallawa> | ||||||||||
Component: | Images | Assignee: | Said Abou-Hallawa <sabouhallawa> | ||||||||||
Status: | RESOLVED FIXED | ||||||||||||
Severity: | Normal | CC: | cdumez, commit-queue, dbates, ews-watchlist, japhet, simon.fraser, thorton, webkit-bug-importer | ||||||||||
Priority: | P2 | Keywords: | InRadar | ||||||||||
Version: | WebKit Nightly Build | ||||||||||||
Hardware: | Unspecified | ||||||||||||
OS: | Unspecified | ||||||||||||
Bug Depends on: | |||||||||||||
Bug Blocks: | 190454 | ||||||||||||
Attachments: |
|
Description
Said Abou-Hallawa
2018-10-23 12:24:05 PDT
Created attachment 352990 [details]
Patch
Created attachment 353000 [details]
Patch
Created attachment 353011 [details]
Patch
Comment on attachment 353011 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=353011&action=review > Source/WebCore/platform/MIMETypeRegistry.h:112 > + WEBCORE_EXPORT const static HashSet<String, ASCIICaseInsensitiveHash>& supportedImageMIMETypes(); > + WEBCORE_EXPORT static HashSet<String, ASCIICaseInsensitiveHash>& supportedNonImageMIMETypes(); > + WEBCORE_EXPORT const static HashSet<String, ASCIICaseInsensitiveHash>& supportedMediaMIMETypes(); > + WEBCORE_EXPORT const static HashSet<String, ASCIICaseInsensitiveHash>& pdfMIMETypes(); > + WEBCORE_EXPORT const static HashSet<String, ASCIICaseInsensitiveHash>& unsupportedTextMIMETypes(); I think static const HashSet<> reads better. Is there a reason supportedNonImageMIMETypes() doesn't return a const HashSet<>? Created attachment 353037 [details]
Patch
Comment on attachment 353011 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=353011&action=review >> Source/WebCore/platform/MIMETypeRegistry.h:112 >> + WEBCORE_EXPORT const static HashSet<String, ASCIICaseInsensitiveHash>& unsupportedTextMIMETypes(); > > I think static const HashSet<> reads better. > > Is there a reason supportedNonImageMIMETypes() doesn't return a const HashSet<>? Yes. [WebView _unregisterViewClassAndRepresentationClassForMIMEType] [WebView _registerViewClass] [WebView registerViewClass] need to change it by adding and removing mime types. Comment on attachment 353037 [details] Patch Clearing flags on attachment: 353037 Committed r237393: <https://trac.webkit.org/changeset/237393> All reviewed patches have been landed. Closing bug. |