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

Side by Side Diff: third_party/WebKit/Source/modules/canvas2d/HitRegion.h

Issue 1923993002: Revert of Remove unnecessary uses of GarbageCollectedFinalized<>. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 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 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 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 HitRegion_h 5 #ifndef HitRegion_h
6 #define HitRegion_h 6 #define HitRegion_h
7 7
8 #include "core/dom/Element.h" 8 #include "core/dom/Element.h"
9 #include "modules/canvas2d/HitRegionOptions.h" 9 #include "modules/canvas2d/HitRegionOptions.h"
10 #include "platform/graphics/Path.h" 10 #include "platform/graphics/Path.h"
(...skipping 27 matching lines...) Expand all
38 38
39 private: 39 private:
40 HitRegion(const Path&, const HitRegionOptions&); 40 HitRegion(const Path&, const HitRegionOptions&);
41 41
42 String m_id; 42 String m_id;
43 Member<Element> m_control; 43 Member<Element> m_control;
44 Path m_path; 44 Path m_path;
45 WindRule m_fillRule; 45 WindRule m_fillRule;
46 }; 46 };
47 47
48 class HitRegionManager final : public GarbageCollected<HitRegionManager> { 48 class HitRegionManager final : public GarbageCollectedFinalized<HitRegionManager > {
49 WTF_MAKE_NONCOPYABLE(HitRegionManager); 49 WTF_MAKE_NONCOPYABLE(HitRegionManager);
50 public: 50 public:
51 static HitRegionManager* create() { return new HitRegionManager; } 51 static HitRegionManager* create() { return new HitRegionManager; }
52 ~HitRegionManager() { }
52 53
53 void addHitRegion(HitRegion*); 54 void addHitRegion(HitRegion*);
54 55
55 void removeHitRegion(HitRegion*); 56 void removeHitRegion(HitRegion*);
56 void removeHitRegionById(const String& id); 57 void removeHitRegionById(const String& id);
57 void removeHitRegionByControl(const Element*); 58 void removeHitRegionByControl(const Element*);
58 void removeHitRegionsInRect(const FloatRect&, const AffineTransform&); 59 void removeHitRegionsInRect(const FloatRect&, const AffineTransform&);
59 void removeAllHitRegions(); 60 void removeAllHitRegions();
60 61
61 HitRegion* getHitRegionById(const String& id) const; 62 HitRegion* getHitRegionById(const String& id) const;
(...skipping 13 matching lines...) Expand all
75 typedef HeapHashMap<Member<const Element>, Member<HitRegion>> HitRegionContr olMap; 76 typedef HeapHashMap<Member<const Element>, Member<HitRegion>> HitRegionContr olMap;
76 77
77 HitRegionList m_hitRegionList; 78 HitRegionList m_hitRegionList;
78 HitRegionIdMap m_hitRegionIdMap; 79 HitRegionIdMap m_hitRegionIdMap;
79 HitRegionControlMap m_hitRegionControlMap; 80 HitRegionControlMap m_hitRegionControlMap;
80 }; 81 };
81 82
82 } // namespace blink 83 } // namespace blink
83 84
84 #endif 85 #endif
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698