OLD | NEW |
1 | 1 |
2 /* | 2 /* |
3 * Copyright 2006 The Android Open Source Project | 3 * Copyright 2006 The Android Open Source Project |
4 * | 4 * |
5 * Use of this source code is governed by a BSD-style license that can be | 5 * Use of this source code is governed by a BSD-style license that can be |
6 * found in the LICENSE file. | 6 * found in the LICENSE file. |
7 */ | 7 */ |
8 | 8 |
9 | 9 |
10 #ifndef SkDrawRectangle_DEFINED | 10 #ifndef SkDrawRectangle_DEFINED |
11 #define SkDrawRectangle_DEFINED | 11 #define SkDrawRectangle_DEFINED |
12 | 12 |
13 #include "SkBoundable.h" | 13 #include "SkBoundable.h" |
14 #include "SkMemberInfo.h" | 14 #include "SkMemberInfo.h" |
15 #include "SkRect.h" | 15 #include "SkRect.h" |
16 | 16 |
17 class SkRectToRect; | 17 class SkRectToRect; |
18 | 18 |
19 class SkDrawRect : public SkBoundable { | 19 class SkDrawRect : public SkBoundable { |
20 DECLARE_DRAW_MEMBER_INFO(Rect); | 20 DECLARE_DRAW_MEMBER_INFO(Rect); |
21 SkDrawRect(); | 21 SkDrawRect(); |
22 virtual void dirty() SK_OVERRIDE; | 22 void dirty() SK_OVERRIDE; |
23 virtual bool draw(SkAnimateMaker& ) SK_OVERRIDE; | 23 bool draw(SkAnimateMaker& ) SK_OVERRIDE; |
24 #ifdef SK_DUMP_ENABLED | 24 #ifdef SK_DUMP_ENABLED |
25 virtual void dump(SkAnimateMaker* ) SK_OVERRIDE; | 25 void dump(SkAnimateMaker* ) SK_OVERRIDE; |
26 #endif | 26 #endif |
27 virtual SkDisplayable* getParent() const SK_OVERRIDE; | 27 SkDisplayable* getParent() const SK_OVERRIDE; |
28 virtual bool getProperty(int index, SkScriptValue* value) const SK_OVERRIDE; | 28 bool getProperty(int index, SkScriptValue* value) const SK_OVERRIDE; |
29 virtual bool setParent(SkDisplayable* parent) SK_OVERRIDE; | 29 bool setParent(SkDisplayable* parent) SK_OVERRIDE; |
30 virtual bool setProperty(int index, SkScriptValue& ) SK_OVERRIDE; | 30 bool setProperty(int index, SkScriptValue& ) SK_OVERRIDE; |
31 protected: | 31 protected: |
32 SkRect fRect; | 32 SkRect fRect; |
33 SkDisplayable* fParent; | 33 SkDisplayable* fParent; |
34 private: | 34 private: |
35 friend class SkDrawClip; | 35 friend class SkDrawClip; |
36 friend class SkRectToRect; | 36 friend class SkRectToRect; |
37 friend class SkSaveLayer; | 37 friend class SkSaveLayer; |
38 typedef SkBoundable INHERITED; | 38 typedef SkBoundable INHERITED; |
39 }; | 39 }; |
40 | 40 |
41 class SkRoundRect : public SkDrawRect { | 41 class SkRoundRect : public SkDrawRect { |
42 DECLARE_MEMBER_INFO(RoundRect); | 42 DECLARE_MEMBER_INFO(RoundRect); |
43 SkRoundRect(); | 43 SkRoundRect(); |
44 virtual bool draw(SkAnimateMaker& ) SK_OVERRIDE; | 44 bool draw(SkAnimateMaker& ) SK_OVERRIDE; |
45 #ifdef SK_DUMP_ENABLED | 45 #ifdef SK_DUMP_ENABLED |
46 virtual void dump(SkAnimateMaker* ) SK_OVERRIDE; | 46 void dump(SkAnimateMaker* ) SK_OVERRIDE; |
47 #endif | 47 #endif |
48 protected: | 48 protected: |
49 SkScalar rx; | 49 SkScalar rx; |
50 SkScalar ry; | 50 SkScalar ry; |
51 private: | 51 private: |
52 typedef SkDrawRect INHERITED; | 52 typedef SkDrawRect INHERITED; |
53 }; | 53 }; |
54 | 54 |
55 #endif // SkDrawRectangle_DEFINED | 55 #endif // SkDrawRectangle_DEFINED |
OLD | NEW |