OLD | NEW |
1 // Copyright (c) 2006-2008 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2006-2008 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 <ApplicationServices/ApplicationServices.h> | 5 #include <ApplicationServices/ApplicationServices.h> |
6 #import <Cocoa/Cocoa.h> | 6 #import <Cocoa/Cocoa.h> |
7 #import <objc/objc-runtime.h> | 7 #import <objc/objc-runtime.h> |
8 #include <sys/stat.h> | 8 #include <sys/stat.h> |
9 | 9 |
10 #include "webkit/tools/test_shell/test_shell.h" | 10 #include "webkit/tools/test_shell/test_shell.h" |
(...skipping 15 matching lines...) Expand all Loading... |
26 #include "base/utf_string_conversions.h" | 26 #include "base/utf_string_conversions.h" |
27 #include "gfx/size.h" | 27 #include "gfx/size.h" |
28 #include "grit/webkit_resources.h" | 28 #include "grit/webkit_resources.h" |
29 #include "net/base/mime_util.h" | 29 #include "net/base/mime_util.h" |
30 #include "skia/ext/bitmap_platform_device.h" | 30 #include "skia/ext/bitmap_platform_device.h" |
31 #include "testing/gtest/include/gtest/gtest.h" | 31 #include "testing/gtest/include/gtest/gtest.h" |
32 #include "third_party/WebKit/WebKit/chromium/public/WebFrame.h" | 32 #include "third_party/WebKit/WebKit/chromium/public/WebFrame.h" |
33 #include "third_party/WebKit/WebKit/chromium/public/WebView.h" | 33 #include "third_party/WebKit/WebKit/chromium/public/WebView.h" |
34 #include "webkit/glue/webkit_glue.h" | 34 #include "webkit/glue/webkit_glue.h" |
35 #include "webkit/glue/webpreferences.h" | 35 #include "webkit/glue/webpreferences.h" |
36 #include "webkit/plugins/npapi/plugin_list.h" | 36 #include "webkit/glue/plugins/plugin_list.h" |
37 #include "webkit/tools/test_shell/mac/test_shell_webview.h" | 37 #include "webkit/tools/test_shell/mac/test_shell_webview.h" |
38 #include "webkit/tools/test_shell/resource.h" | 38 #include "webkit/tools/test_shell/resource.h" |
39 #include "webkit/tools/test_shell/simple_resource_loader_bridge.h" | 39 #include "webkit/tools/test_shell/simple_resource_loader_bridge.h" |
40 #include "webkit/tools/test_shell/test_navigation_controller.h" | 40 #include "webkit/tools/test_shell/test_navigation_controller.h" |
41 #include "webkit/tools/test_shell/test_webview_delegate.h" | 41 #include "webkit/tools/test_shell/test_webview_delegate.h" |
42 | 42 |
43 #include "third_party/skia/include/core/SkBitmap.h" | 43 #include "third_party/skia/include/core/SkBitmap.h" |
44 | 44 |
45 #import "mac/DumpRenderTreePasteboard.h" | 45 #import "mac/DumpRenderTreePasteboard.h" |
46 | 46 |
(...skipping 198 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
245 | 245 |
246 // Add <app bundle's parent dir>/plugins to the plugin path so we can load | 246 // Add <app bundle's parent dir>/plugins to the plugin path so we can load |
247 // test plugins. | 247 // test plugins. |
248 FilePath plugins_dir; | 248 FilePath plugins_dir; |
249 PathService::Get(base::DIR_EXE, &plugins_dir); | 249 PathService::Get(base::DIR_EXE, &plugins_dir); |
250 if (mac_util::AmIBundled()) { | 250 if (mac_util::AmIBundled()) { |
251 plugins_dir = plugins_dir.AppendASCII("../../../plugins"); | 251 plugins_dir = plugins_dir.AppendASCII("../../../plugins"); |
252 } else { | 252 } else { |
253 plugins_dir = plugins_dir.AppendASCII("plugins"); | 253 plugins_dir = plugins_dir.AppendASCII("plugins"); |
254 } | 254 } |
255 webkit::npapi::PluginList::Singleton()->AddExtraPluginDir(plugins_dir); | 255 NPAPI::PluginList::Singleton()->AddExtraPluginDir(plugins_dir); |
256 } | 256 } |
257 | 257 |
258 NSButton* MakeTestButton(NSRect* rect, NSString* title, NSView* parent) { | 258 NSButton* MakeTestButton(NSRect* rect, NSString* title, NSView* parent) { |
259 NSButton* button = [[[NSButton alloc] initWithFrame:*rect] autorelease]; | 259 NSButton* button = [[[NSButton alloc] initWithFrame:*rect] autorelease]; |
260 [button setTitle:title]; | 260 [button setTitle:title]; |
261 [button setBezelStyle:NSSmallSquareBezelStyle]; | 261 [button setBezelStyle:NSSmallSquareBezelStyle]; |
262 [button setAutoresizingMask:(NSViewMaxXMargin | NSViewMinYMargin)]; | 262 [button setAutoresizingMask:(NSViewMaxXMargin | NSViewMinYMargin)]; |
263 [parent addSubview:button]; | 263 [parent addSubview:button]; |
264 rect->origin.x += BUTTON_WIDTH; | 264 rect->origin.x += BUTTON_WIDTH; |
265 return button; | 265 return button; |
(...skipping 469 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
735 return false; | 735 return false; |
736 } | 736 } |
737 | 737 |
738 void DidLoadPlugin(const std::string& filename) { | 738 void DidLoadPlugin(const std::string& filename) { |
739 } | 739 } |
740 | 740 |
741 void DidUnloadPlugin(const std::string& filename) { | 741 void DidUnloadPlugin(const std::string& filename) { |
742 } | 742 } |
743 | 743 |
744 } // namespace webkit_glue | 744 } // namespace webkit_glue |
OLD | NEW |