Changeset 74060 in webkit


Ignore:
Timestamp:
Dec 14, 2010 2:04:02 PM (13 years ago)
Author:
andersca@apple.com
Message:

2010-12-14 Anders Carlsson <andersca@apple.com>

Reviewed by John Sullivan.

Switch name and description order when fetching Carbon plug-in info
https://bugs.webkit.org/show_bug.cgi?id=46211

The plug-in description comes before the name in the Carbon string list resource.

  • UIProcess/Plugins/mac/PluginInfoStoreMac.mm: (WebKit::getPluginInfoFromCarbonResources):
Location:
trunk/WebKit2
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/WebKit2/ChangeLog

    r74058 r74060  
     12010-12-14  Anders Carlsson  <andersca@apple.com>
     2
     3        Reviewed by John Sullivan.
     4
     5        Switch name and description order when fetching Carbon plug-in info
     6        https://bugs.webkit.org/show_bug.cgi?id=46211
     7
     8        The plug-in description comes before the name in the Carbon string list resource.
     9
     10        * UIProcess/Plugins/mac/PluginInfoStoreMac.mm:
     11        (WebKit::getPluginInfoFromCarbonResources):
     12
    1132010-12-14  Anders Carlsson  <andersca@apple.com>
    214
  • trunk/WebKit2/UIProcess/Plugins/mac/PluginInfoStoreMac.mm

    r71435 r74060  
    226226    if (stringListSize < static_cast<Size>(sizeof(UInt16)))
    227227        return false;
    228  
     228
    229229    CFStringEncoding stringEncoding = stringEncodingForResource(stringListHandle);
    230230
     
    235235    UInt16 numStrings = *reinterpret_cast<UInt16*>(ptr);
    236236    ptr += sizeof(UInt16);
    237                  
     237
    238238    for (UInt16 i = 0; i < numStrings; ++i) {
    239239        // We're past the end of the string, bail.
     
    268268        return false;
    269269
    270     // Get the name and description string list.
    271     Vector<String> nameAndDescription;
    272     if (!getStringListResource(PluginNameOrDescriptionStringNumber, nameAndDescription))
     270    // Get the description and name string list.
     271    Vector<String> descriptionAndName;
     272    if (!getStringListResource(PluginNameOrDescriptionStringNumber, descriptionAndName))
    273273        return false;
    274274
     
    310310    }
    311311
    312     // Set the name and description if they exist.
    313     if (nameAndDescription.size() > 0)
    314         pluginInfo.name = nameAndDescription[0];
    315     if (nameAndDescription.size() > 1)
    316         pluginInfo.desc = nameAndDescription[1];
     312    // Set the description and name if they exist.
     313    if (descriptionAndName.size() > 0)
     314        pluginInfo.desc = descriptionAndName[0];
     315    if (descriptionAndName.size() > 1)
     316        pluginInfo.name = descriptionAndName[1];
    317317
    318318    return true;
Note: See TracChangeset for help on using the changeset viewer.