Changeset 73884 in webkit


Ignore:
Timestamp:
Dec 12, 2010 8:41:20 PM (13 years ago)
Author:
bweinstein@apple.com
Message:

WebKit2: Implement WebInspector::localizedStringsURL on Windows
https://bugs.webkit.org/show_bug.cgi?id=50896

Reviewed by Tim Hatcher.

Find the localized strings file using CFBundleCopyResourceURL.

  • WebProcess/WebPage/win/WebInspectorWin.cpp:

(WebKit::WebInspector::localizedStringsURL):

Location:
trunk/WebKit2
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/WebKit2/ChangeLog

    r73882 r73884  
     12010-12-12  Brian Weinstein  <bweinstein@apple.com>
     2
     3        Reviewed by Tim Hatcher.
     4
     5        WebKit2: Implement WebInspector::localizedStringsURL on Windows
     6        https://bugs.webkit.org/show_bug.cgi?id=50896
     7       
     8        Find the localized strings file using CFBundleCopyResourceURL.
     9
     10        * WebProcess/WebPage/win/WebInspectorWin.cpp:
     11        (WebKit::WebInspector::localizedStringsURL):
     12
    1132010-12-12  Sam Weinig  <sam@webkit.org>
    214
  • trunk/WebKit2/WebProcess/WebPage/win/WebInspectorWin.cpp

    r72666 r73884  
    2828#if ENABLE(INSPECTOR)
    2929
     30#include <wtf/RetainPtr.h>
    3031#include <wtf/text/WTFString.h>
    31 
    32 #define DISABLE_NOT_IMPLEMENTED_WARNINGS 1
    33 #include "NotImplemented.h"
    3432
    3533namespace WebKit {
     
    3735String WebInspector::localizedStringsURL() const
    3836{
    39     notImplemented();
    40     return String();
     37    RetainPtr<CFURLRef> localizedStringsURLRef(AdoptCF, CFBundleCopyResourceURL(CFBundleGetBundleWithIdentifier(CFSTR("com.apple.WebKit")), CFSTR("localizedStrings"), CFSTR("js"), 0));
     38    if (!localizedStringsURLRef)
     39        return String();
     40
     41    return String(CFURLGetString(localizedStringsURLRef.get()));
    4142}
    4243
Note: See TracChangeset for help on using the changeset viewer.