Font fallback in WebKitTestRunner depends on user settings
[WebKit-https.git] / Tools / WebKitTestRunner / InjectedBundle / mac / InjectedBundleMac.mm
index e947a80d01d74e5a8425155567622a34f48edf99..1bbff4156b20b7c6722a22f5545784c4046c4388 100644 (file)
  * THE POSSIBILITY OF SUCH DAMAGE.
  */
 
-#include "InjectedBundle.h"
+#import "InjectedBundle.h"
+
+#import <Foundation/Foundation.h>
 
 namespace WTR {
 
-void InjectedBundle::initializePlatformDefaults()
+void InjectedBundle::platformInitialize(WKTypeRef)
 {
     NSDictionary *dict = [NSDictionary dictionaryWithObjectsAndKeys:
         [NSNumber numberWithInteger:4],   @"AppleAntiAliasingThreshold",
@@ -35,9 +37,10 @@ void InjectedBundle::initializePlatformDefaults()
         [NSNumber numberWithBool:NO],     @"AppleScrollAnimationEnabled",
         [NSNumber numberWithBool:NO],     @"NSOverlayScrollersEnabled",
         @"Always",                        @"AppleShowScrollBars",
+        [NSArray arrayWithObject:@"en"],  @"AppleLanguages",
         nil];
 
-    [[NSUserDefaults standardUserDefaults] registerDefaults:dict];
+    [[NSUserDefaults standardUserDefaults] setVolatileDomain:dict forName:NSArgumentDomain];    
 }
 
 } // namespace WTR