OLD | NEW |
(Empty) | |
| 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 |
| 3 // found in the LICENSE file. |
| 4 |
| 5 #ifndef UI_GFX_CANVAS_SKIA_PAINT_LINUX_H_ |
| 6 #define UI_GFX_CANVAS_SKIA_PAINT_LINUX_H_ |
| 7 #pragma once |
| 8 |
| 9 #include "base/scoped_ptr.h" |
| 10 #include "ui/gfx/canvas.h" |
| 11 |
| 12 #include <gdk/gdk.h> |
| 13 |
| 14 namespace gfx { |
| 15 |
| 16 class CanvasSkia; |
| 17 |
| 18 class CanvasSkiaPaint : public CanvasPaint { |
| 19 public: |
| 20 CanvasSkiaPaint(GdkEventExpose* event, bool opaque); |
| 21 virtual ~CanvasSkiaPaint(); |
| 22 |
| 23 // Overridden from CanvasPaint: |
| 24 virtual bool IsValid() const; |
| 25 virtual gfx::Rect GetInvalidRect() const; |
| 26 virtual Canvas* AsCanvas(); |
| 27 |
| 28 private: |
| 29 bool InitCanvas(); |
| 30 |
| 31 GdkWindow* window_; |
| 32 GdkRegion* region_; |
| 33 scoped_ptr<CanvasSkia> canvas_; |
| 34 }; |
| 35 |
| 36 } // namespace gfx |
| 37 |
| 38 #endif // UI_GFX_CANVAS_SKIA_PAINT_LINUX_H_ |
OLD | NEW |