Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(10)

Side by Side Diff: chrome/renderer/webplugin_delegate_pepper.cc

Issue 547005: This CL is for Neb. It contains his change 501124, with conflicts merged. (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: '' Created 10 years, 11 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « chrome/renderer/render_view.cc ('k') | webkit/tools/pepper_test_plugin/event_handler.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2009 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2009 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 #define PEPPER_APIS_ENABLED 1 5 #define PEPPER_APIS_ENABLED 1
6 6
7 #include "chrome/renderer/webplugin_delegate_pepper.h" 7 #include "chrome/renderer/webplugin_delegate_pepper.h"
8 8
9 #include <string> 9 #include <string>
10 #include <vector> 10 #include <vector>
(...skipping 575 matching lines...) Expand 10 before | Expand all | Expand 10 after
586 WebPluginDelegatePepper::~WebPluginDelegatePepper() { 586 WebPluginDelegatePepper::~WebPluginDelegatePepper() {
587 DestroyInstance(); 587 DestroyInstance();
588 } 588 }
589 589
590 void WebPluginDelegatePepper::PluginDestroyed() { 590 void WebPluginDelegatePepper::PluginDestroyed() {
591 delete this; 591 delete this;
592 } 592 }
593 593
594 void WebPluginDelegatePepper::Paint(WebKit::WebCanvas* canvas, 594 void WebPluginDelegatePepper::Paint(WebKit::WebCanvas* canvas,
595 const gfx::Rect& rect) { 595 const gfx::Rect& rect) {
596 #if defined(OS_WIN) 596 #if defined(OS_WIN) || defined(OS_LINUX)
597 if (nested_delegate_) { 597 if (nested_delegate_) {
598 // TODO(apatrick): The GPU plugin will render to an offscreen render target. 598 // TODO(apatrick): The GPU plugin will render to an offscreen render target.
599 // Need to copy it to the screen here. 599 // Need to copy it to the screen here.
600 } else { 600 } else {
601 // Blit from background_context to context. 601 // Blit from background_context to context.
602 if (!committed_bitmap_.isNull()) { 602 if (!committed_bitmap_.isNull()) {
603 gfx::Point origin(window_rect_.origin().x(), window_rect_.origin().y()); 603 gfx::Point origin(window_rect_.origin().x(), window_rect_.origin().y());
604 canvas->drawBitmap(committed_bitmap_, 604 canvas->drawBitmap(committed_bitmap_,
605 SkIntToScalar(window_rect_.origin().x()), 605 SkIntToScalar(window_rect_.origin().x()),
606 SkIntToScalar(window_rect_.origin().y())); 606 SkIntToScalar(window_rect_.origin().y()));
(...skipping 124 matching lines...) Expand 10 before | Expand all | Expand 10 after
731 BuildCharEvent(&event, &npevent); 731 BuildCharEvent(&event, &npevent);
732 break; 732 break;
733 case NPEventType_Minimize: 733 case NPEventType_Minimize:
734 case NPEventType_Focus: 734 case NPEventType_Focus:
735 case NPEventType_Device: 735 case NPEventType_Device:
736 // NOTIMPLEMENTED(); 736 // NOTIMPLEMENTED();
737 break; 737 break;
738 } 738 }
739 return instance()->NPP_HandleEvent(&npevent) != 0; 739 return instance()->NPP_HandleEvent(&npevent) != 0;
740 } 740 }
OLDNEW
« no previous file with comments | « chrome/renderer/render_view.cc ('k') | webkit/tools/pepper_test_plugin/event_handler.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698