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

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

Issue 1174203002: Clip inkwell splash around the floating action button (Closed) Base URL: git@github.com:domokit/mojo.git@master
Patch Set: rebase and apply code review feedback Created 5 years, 6 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
« no previous file with comments | « sky/engine/core/painting/Canvas.idl ('k') | sky/engine/core/painting/Path.idl » ('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 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_PATH_H_ 5 #ifndef SKY_ENGINE_CORE_PAINTING_PATH_H_
6 #define SKY_ENGINE_CORE_PAINTING_PATH_H_ 6 #define SKY_ENGINE_CORE_PAINTING_PATH_H_
7 7
8 #include "math.h" 8 #include "math.h"
9 9
10 #include "sky/engine/core/painting/Rect.h" 10 #include "sky/engine/core/painting/Rect.h"
(...skipping 25 matching lines...) Expand all
36 void lineTo(float x, float y) 36 void lineTo(float x, float y)
37 { 37 {
38 m_path.lineTo(x, y); 38 m_path.lineTo(x, y);
39 } 39 }
40 40
41 void arcTo(const Rect& rect, float startAngle, float sweepAngle, bool forceM oveTo) 41 void arcTo(const Rect& rect, float startAngle, float sweepAngle, bool forceM oveTo)
42 { 42 {
43 m_path.arcTo(rect.sk_rect, startAngle*180.0/M_PI, sweepAngle*180.0/M_PI, forceMoveTo); 43 m_path.arcTo(rect.sk_rect, startAngle*180.0/M_PI, sweepAngle*180.0/M_PI, forceMoveTo);
44 } 44 }
45 45
46 void addOval(const Rect& oval)
47 {
48 m_path.addOval(oval.sk_rect);
49 }
50
46 void close() 51 void close()
47 { 52 {
48 m_path.close(); 53 m_path.close();
49 } 54 }
50 55
51 const SkPath& path() const { return m_path; } 56 const SkPath& path() const { return m_path; }
52 57
53 private: 58 private:
54 CanvasPath(); 59 CanvasPath();
55 60
56 SkPath m_path; 61 SkPath m_path;
57 }; 62 };
58 63
59 } // namespace blink 64 } // namespace blink
60 65
61 #endif // SKY_ENGINE_CORE_PAINTING_PATH_H_ 66 #endif // SKY_ENGINE_CORE_PAINTING_PATH_H_
OLDNEW
« no previous file with comments | « sky/engine/core/painting/Canvas.idl ('k') | sky/engine/core/painting/Path.idl » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698