| OLD | NEW |
| 1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #include "base/command_line.h" | 5 #include "base/command_line.h" |
| 6 #include "base/logging.h" | 6 #include "base/logging.h" |
| 7 #include "base/mac/bundle_locations.h" | 7 #include "base/mac/bundle_locations.h" |
| 8 #include "base/path_service.h" | 8 #include "base/path_service.h" |
| 9 #include "content/public/common/content_switches.h" | 9 #include "content/public/common/content_switches.h" |
| 10 #include "content/shell/app/webkit_test_platform_support.h" | 10 #include "content/shell/app/blink_test_platform_support.h" |
| 11 | 11 |
| 12 #include <AppKit/AppKit.h> | 12 #include <AppKit/AppKit.h> |
| 13 #include <Foundation/Foundation.h> | 13 #include <Foundation/Foundation.h> |
| 14 | 14 |
| 15 namespace content { | 15 namespace content { |
| 16 | 16 |
| 17 namespace { | 17 namespace { |
| 18 | 18 |
| 19 void SetDefaultsToLayoutTestValues(void) { | 19 void SetDefaultsToLayoutTestValues(void) { |
| 20 // So we can match the WebKit layout tests, we want to force a bunch of | 20 // So we can match the WebKit layout tests, we want to force a bunch of |
| (...skipping 20 matching lines...) Expand all Loading... |
| 41 [defaults setObject:@"Always" | 41 [defaults setObject:@"Always" |
| 42 forKey:@"AppleShowScrollBars"]; | 42 forKey:@"AppleShowScrollBars"]; |
| 43 } | 43 } |
| 44 | 44 |
| 45 } // namespace | 45 } // namespace |
| 46 | 46 |
| 47 bool CheckLayoutSystemDeps() { | 47 bool CheckLayoutSystemDeps() { |
| 48 return true; | 48 return true; |
| 49 } | 49 } |
| 50 | 50 |
| 51 bool WebKitTestPlatformInitialize() { | 51 bool BlinkTestPlatformInitialize() { |
| 52 | 52 |
| 53 SetDefaultsToLayoutTestValues(); | 53 SetDefaultsToLayoutTestValues(); |
| 54 | 54 |
| 55 // Load font files in the resource folder. | 55 // Load font files in the resource folder. |
| 56 static const char* const fontFileNames[] = { | 56 static const char* const fontFileNames[] = { |
| 57 "AHEM____.TTF", "ChromiumAATTest.ttf" | 57 "AHEM____.TTF", "ChromiumAATTest.ttf" |
| 58 }; | 58 }; |
| 59 | 59 |
| 60 // mainBundle is Content Shell Helper.app. Go two levels up to find | 60 // mainBundle is Content Shell Helper.app. Go two levels up to find |
| 61 // Content Shell.app. Due to DumpRenderTree injecting the font files into | 61 // Content Shell.app. Due to DumpRenderTree injecting the font files into |
| (...skipping 25 matching lines...) Expand all Loading... |
| 87 base::FilePath plugins_dir; | 87 base::FilePath plugins_dir; |
| 88 PathService::Get(base::DIR_EXE, &plugins_dir); | 88 PathService::Get(base::DIR_EXE, &plugins_dir); |
| 89 plugins_dir = plugins_dir.AppendASCII("../../../plugins"); | 89 plugins_dir = plugins_dir.AppendASCII("../../../plugins"); |
| 90 CommandLine& command_line = *CommandLine::ForCurrentProcess(); | 90 CommandLine& command_line = *CommandLine::ForCurrentProcess(); |
| 91 command_line.AppendSwitchPath(switches::kExtraPluginDir, plugins_dir); | 91 command_line.AppendSwitchPath(switches::kExtraPluginDir, plugins_dir); |
| 92 | 92 |
| 93 return true; | 93 return true; |
| 94 } | 94 } |
| 95 | 95 |
| 96 } // namespace | 96 } // namespace |
| OLD | NEW |