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 421 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
432 | 432 |
433 if (g_iat_patch_reg_enum_key_ex_w.Pointer()->is_patched()) | 433 if (g_iat_patch_reg_enum_key_ex_w.Pointer()->is_patched()) |
434 g_iat_patch_reg_enum_key_ex_w.Pointer()->Unpatch(); | 434 g_iat_patch_reg_enum_key_ex_w.Pointer()->Unpatch(); |
435 | 435 |
436 if (mouse_hook_) { | 436 if (mouse_hook_) { |
437 UnhookWindowsHookEx(mouse_hook_); | 437 UnhookWindowsHookEx(mouse_hook_); |
438 mouse_hook_ = NULL; | 438 mouse_hook_ = NULL; |
439 } | 439 } |
440 } | 440 } |
441 | 441 |
442 void WebPluginDelegateImpl::Paint(WebKit::WebCanvas* canvas, | 442 void WebPluginDelegateImpl::Paint(SkCanvas* canvas, const gfx::Rect& rect) { |
443 const gfx::Rect& rect) { | |
444 if (windowless_ && skia::SupportsPlatformPaint(canvas)) { | 443 if (windowless_ && skia::SupportsPlatformPaint(canvas)) { |
445 skia::ScopedPlatformPaint scoped_platform_paint(canvas); | 444 skia::ScopedPlatformPaint scoped_platform_paint(canvas); |
446 HDC hdc = scoped_platform_paint.GetPlatformSurface(); | 445 HDC hdc = scoped_platform_paint.GetPlatformSurface(); |
447 WindowlessPaint(hdc, rect); | 446 WindowlessPaint(hdc, rect); |
448 } | 447 } |
449 } | 448 } |
450 | 449 |
451 bool WebPluginDelegateImpl::WindowedCreatePlugin() { | 450 bool WebPluginDelegateImpl::WindowedCreatePlugin() { |
452 DCHECK(!windowed_handle_); | 451 DCHECK(!windowed_handle_); |
453 | 452 |
(...skipping 1029 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1483 case WM_RBUTTONUP: | 1482 case WM_RBUTTONUP: |
1484 ::ReleaseCapture(); | 1483 ::ReleaseCapture(); |
1485 break; | 1484 break; |
1486 | 1485 |
1487 default: | 1486 default: |
1488 break; | 1487 break; |
1489 } | 1488 } |
1490 } | 1489 } |
1491 | 1490 |
1492 } // namespace content | 1491 } // namespace content |
OLD | NEW |