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

Side by Side Diff: sky/engine/core/painting/PaintingContext.h

Issue 1144483002: Flesh out the Painting API a bit. (Closed) Base URL: https://github.com/domokit/mojo.git@master
Patch Set: constify Created 5 years, 7 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
OLDNEW
1 // Copyright 2015 The Chromium Authors. All rights reserved. 1 // Copyright 2015 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 #ifndef SKY_ENGINE_CORE_PAINTING_PAINTINGCONTEXT_H_ 5 #ifndef SKY_ENGINE_CORE_PAINTING_PAINTINGCONTEXT_H_
6 #define SKY_ENGINE_CORE_PAINTING_PAINTINGCONTEXT_H_ 6 #define SKY_ENGINE_CORE_PAINTING_PAINTINGCONTEXT_H_
7 7
8 #include "sky/engine/core/painting/Canvas.h" 8 #include "sky/engine/core/painting/Canvas.h"
9 #include "sky/engine/wtf/Vector.h"
9 10
10 namespace blink { 11 namespace blink {
11 class Element; 12 class Element;
12 13
13 class PaintingContext : public Canvas { 14 class PaintingContext : public Canvas {
14 DEFINE_WRAPPERTYPEINFO(); 15 DEFINE_WRAPPERTYPEINFO();
15 public: 16 public:
16 ~PaintingContext() override; 17 ~PaintingContext() override;
17 static PassRefPtr<PaintingContext> create(PassRefPtr<Element> element, const FloatSize& size); 18 static PassRefPtr<PaintingContext> create(PassRefPtr<Element> element, const FloatSize& size);
18 19
19 void commit(); 20 void commit();
20 21
21 private: 22 private:
22 PaintingContext(PassRefPtr<Element> element, const FloatSize& size); 23 PaintingContext(PassRefPtr<Element> element, const FloatSize& size);
23 24
24 RefPtr<Element> m_element; 25 RefPtr<Element> m_element;
25 }; 26 };
26 27
27 } // namespace blink 28 } // namespace blink
28 29
29 #endif // SKY_ENGINE_CORE_PAINTING_PAINTINGCONTEXT_H_ 30 #endif // SKY_ENGINE_CORE_PAINTING_PAINTINGCONTEXT_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698