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

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

Issue 8122013: Allow CanvasSkia to bind to an existing SkCanvas. (Closed) Base URL: http://git.chromium.org/git/chromium.git@trunk
Patch Set: 1 more fix Created 9 years, 2 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
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 400 matching lines...) Expand 10 before | Expand all | Expand 10 after
411 mouse_pressed_handler_ = NULL; 411 mouse_pressed_handler_ = NULL;
412 if (mouse_move_handler_ == child) 412 if (mouse_move_handler_ == child)
413 mouse_move_handler_ = NULL; 413 mouse_move_handler_ = NULL;
414 if (touch_pressed_handler_ == child) 414 if (touch_pressed_handler_ == child)
415 touch_pressed_handler_ = NULL; 415 touch_pressed_handler_ = NULL;
416 } 416 }
417 } 417 }
418 418
419 void RootView::OnPaint(gfx::Canvas* canvas) { 419 void RootView::OnPaint(gfx::Canvas* canvas) {
420 #if !defined(TOUCH_UI) 420 #if !defined(TOUCH_UI)
421 canvas->AsCanvasSkia()->drawColor(SK_ColorBLACK, SkXfermode::kClear_Mode); 421 canvas->GetSkCanvas()->drawColor(SK_ColorBLACK, SkXfermode::kClear_Mode);
422 #endif 422 #endif
423 } 423 }
424 424
425 void RootView::CalculateOffsetToAncestorWithLayer(gfx::Point* offset, 425 void RootView::CalculateOffsetToAncestorWithLayer(gfx::Point* offset,
426 ui::Layer** layer_parent) { 426 ui::Layer** layer_parent) {
427 View::CalculateOffsetToAncestorWithLayer(offset, layer_parent); 427 View::CalculateOffsetToAncestorWithLayer(offset, layer_parent);
428 if (!layer()) 428 if (!layer())
429 widget_->CalculateOffsetToAncestorWithLayer(offset, layer_parent); 429 widget_->CalculateOffsetToAncestorWithLayer(offset, layer_parent);
430 } 430 }
431 431
(...skipping 10 matching lines...) Expand all
442 } 442 }
443 443
444 void RootView::SetMouseLocationAndFlags(const MouseEvent& event) { 444 void RootView::SetMouseLocationAndFlags(const MouseEvent& event) {
445 last_mouse_event_flags_ = event.flags(); 445 last_mouse_event_flags_ = event.flags();
446 last_mouse_event_x_ = event.x(); 446 last_mouse_event_x_ = event.x();
447 last_mouse_event_y_ = event.y(); 447 last_mouse_event_y_ = event.y();
448 } 448 }
449 449
450 } // namespace internal 450 } // namespace internal
451 } // namespace views 451 } // namespace views
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698