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

Side by Side Diff: views/widget/root_view.cc

Issue 6879013: skia::PlatformCanvas is being deprecated. Going forward we will use gfx::Canvas wherever we need ... (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: '' Created 9 years, 8 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 | « views/view_unittest.cc ('k') | views/widget/widget_win.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) 2011 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 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 "views/widget/root_view.h" 5 #include "views/widget/root_view.h"
6 6
7 #include <algorithm> 7 #include <algorithm>
8 8
9 #include "base/logging.h" 9 #include "base/logging.h"
10 #include "base/message_loop.h" 10 #include "base/message_loop.h"
(...skipping 418 matching lines...) Expand 10 before | Expand all | Expand 10 after
429 mouse_move_handler_ = NULL; 429 mouse_move_handler_ = NULL;
430 #if defined(TOUCH_UI) 430 #if defined(TOUCH_UI)
431 if (touch_pressed_handler_) 431 if (touch_pressed_handler_)
432 touch_pressed_handler_ = NULL; 432 touch_pressed_handler_ = NULL;
433 #endif 433 #endif
434 } 434 }
435 } 435 }
436 436
437 437
438 void RootView::OnPaint(gfx::Canvas* canvas) { 438 void RootView::OnPaint(gfx::Canvas* canvas) {
439 canvas->AsCanvasSkia()->drawColor(SK_ColorBLACK, SkXfermode::kClear_Mode); 439 canvas->AsCanvasSkia()->skia_canvas()->drawColor(
440 SK_ColorBLACK, SkXfermode::kClear_Mode);
440 } 441 }
441 442
442 //////////////////////////////////////////////////////////////////////////////// 443 ////////////////////////////////////////////////////////////////////////////////
443 // RootView, private: 444 // RootView, private:
444 445
445 // Coordinate conversion ------------------------------------------------------- 446 // Coordinate conversion -------------------------------------------------------
446 447
447 bool RootView::ConvertPointToMouseHandler(const gfx::Point& l, gfx::Point* p) { 448 bool RootView::ConvertPointToMouseHandler(const gfx::Point& l, gfx::Point* p) {
448 // If the mouse_handler was set explicitly, keep sending events even if it was 449 // If the mouse_handler was set explicitly, keep sending events even if it was
449 // re-parented in a different window. (a non explicit mouse handler is 450 // re-parented in a different window. (a non explicit mouse handler is
(...skipping 23 matching lines...) Expand all
473 widget_->SetCursor(cursor); 474 widget_->SetCursor(cursor);
474 } 475 }
475 476
476 void RootView::SetMouseLocationAndFlags(const MouseEvent& event) { 477 void RootView::SetMouseLocationAndFlags(const MouseEvent& event) {
477 last_mouse_event_flags_ = event.flags(); 478 last_mouse_event_flags_ = event.flags();
478 last_mouse_event_x_ = event.x(); 479 last_mouse_event_x_ = event.x();
479 last_mouse_event_y_ = event.y(); 480 last_mouse_event_y_ = event.y();
480 } 481 }
481 482
482 } // namespace views 483 } // namespace views
OLDNEW
« no previous file with comments | « views/view_unittest.cc ('k') | views/widget/widget_win.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698