Summary: | [GTK] Replace encodings multi-dimensional array with calls to registrar method | ||||||||
---|---|---|---|---|---|---|---|---|---|
Product: | WebKit | Reporter: | Carlos Garcia Campos <cgarcia> | ||||||
Component: | WebKitGTK | Assignee: | Nobody <webkit-unassigned> | ||||||
Status: | RESOLVED FIXED | ||||||||
Severity: | Normal | CC: | mrobinson | ||||||
Priority: | P2 | ||||||||
Version: | 528+ (Nightly build) | ||||||||
Hardware: | PC | ||||||||
OS: | Linux | ||||||||
Bug Depends on: | |||||||||
Bug Blocks: | 47805 | ||||||||
Attachments: |
|
Description
Carlos Garcia Campos
2010-10-20 09:38:49 PDT
Created attachment 71300 [details]
Patch
Comment on attachment 71300 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=71300&action=review I love this patch. Just a couple small nits. > WebCore/platform/text/gtk/TextCodecGtk.cpp:92 > +bool TextCodecGtk::registerEncodingAliasIfAvailable(EncodingNameRegistrar registrar, const char* canonicalName, const char* aliasName) It looks like you never check the return value of this method. Can it just return void? > WebCore/platform/text/gtk/TextCodecGtk.h:60 > + static bool registerEncodingNameIfAvailable(EncodingNameRegistrar registrar, const char* canonicalName); > + static bool registerEncodingAliasIfAvailable(EncodingNameRegistrar registrar, const char* canonicalName, const char* aliasName); > + static void registerCodecIfAvailable(TextCodecRegistrar registrar, const char* codecName); > Could these these can just be static functions in TextCodecGtk.cpp? Created attachment 71400 [details]
Updated patch
Comment on attachment 71400 [details] Updated patch View in context: https://bugs.webkit.org/attachment.cgi?id=71400&action=review Great! Thank you. > WebCore/platform/text/gtk/TextCodecGtk.cpp:62 > +static bool isEncodingAvailable(const gchar* encName) encName should be replaced with encodingName, since we are avoiding abbreviations in new code. I'll fix this and land it myself. :) Committed r70211: <http://trac.webkit.org/changeset/70211> |