OLD | NEW |
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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 "content/child/npapi/webplugin_delegate_impl.h" | 5 #include "content/child/npapi/webplugin_delegate_impl.h" |
6 | 6 |
7 #include <map> | 7 #include <map> |
8 #include <set> | 8 #include <set> |
9 #include <string> | 9 #include <string> |
10 #include <vector> | 10 #include <vector> |
(...skipping 234 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
245 mouse_hook_(NULL), | 245 mouse_hook_(NULL), |
246 first_set_window_call_(true), | 246 first_set_window_call_(true), |
247 plugin_has_focus_(false), | 247 plugin_has_focus_(false), |
248 has_webkit_focus_(false), | 248 has_webkit_focus_(false), |
249 containing_view_has_focus_(true), | 249 containing_view_has_focus_(true), |
250 creation_succeeded_(false) { | 250 creation_succeeded_(false) { |
251 memset(&window_, 0, sizeof(window_)); | 251 memset(&window_, 0, sizeof(window_)); |
252 | 252 |
253 const WebPluginInfo& plugin_info = instance_->plugin_lib()->plugin_info(); | 253 const WebPluginInfo& plugin_info = instance_->plugin_lib()->plugin_info(); |
254 std::wstring filename = | 254 std::wstring filename = |
255 StringToLowerASCII(plugin_info.path.BaseName().value()); | 255 base::StringToLowerASCII(plugin_info.path.BaseName().value()); |
256 | 256 |
257 if (instance_->mime_type() == kFlashPluginSwfMimeType || | 257 if (instance_->mime_type() == kFlashPluginSwfMimeType || |
258 filename == kFlashPlugin) { | 258 filename == kFlashPlugin) { |
259 // Flash only requests windowless plugins if we return a Mozilla user | 259 // Flash only requests windowless plugins if we return a Mozilla user |
260 // agent. | 260 // agent. |
261 instance_->set_use_mozilla_user_agent(); | 261 instance_->set_use_mozilla_user_agent(); |
262 quirks_ |= PLUGIN_QUIRK_THROTTLE_WM_USER_PLUS_ONE; | 262 quirks_ |= PLUGIN_QUIRK_THROTTLE_WM_USER_PLUS_ONE; |
263 quirks_ |= PLUGIN_QUIRK_PATCH_SETCURSOR; | 263 quirks_ |= PLUGIN_QUIRK_PATCH_SETCURSOR; |
264 quirks_ |= PLUGIN_QUIRK_ALWAYS_NOTIFY_SUCCESS; | 264 quirks_ |= PLUGIN_QUIRK_ALWAYS_NOTIFY_SUCCESS; |
265 quirks_ |= PLUGIN_QUIRK_HANDLE_MOUSE_CAPTURE; | 265 quirks_ |= PLUGIN_QUIRK_HANDLE_MOUSE_CAPTURE; |
(...skipping 1255 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1521 case WM_RBUTTONUP: | 1521 case WM_RBUTTONUP: |
1522 ::ReleaseCapture(); | 1522 ::ReleaseCapture(); |
1523 break; | 1523 break; |
1524 | 1524 |
1525 default: | 1525 default: |
1526 break; | 1526 break; |
1527 } | 1527 } |
1528 } | 1528 } |
1529 | 1529 |
1530 } // namespace content | 1530 } // namespace content |
OLD | NEW |