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

Side by Side Diff: Source/modules/geofencing/CircularRegion.h

Issue 478243002: bindings: Adds virtual ScriptWrappable::wrap method. (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Synced. Created 6 years, 3 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 | Annotate | Revision Log
« no previous file with comments | « Source/modules/gamepad/WebKitGamepadList.h ('k') | Source/modules/geofencing/Geofencing.h » ('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 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 CircularRegion_h 5 #ifndef CircularRegion_h
6 #define CircularRegion_h 6 #define CircularRegion_h
7 7
8 #include "modules/geofencing/GeofencingRegion.h" 8 #include "modules/geofencing/GeofencingRegion.h"
9 9
10 namespace blink { 10 namespace blink {
11 11
12 class Dictionary; 12 class Dictionary;
13 13
14 struct CircularRegionInit { 14 struct CircularRegionInit {
15 CircularRegionInit() : latitude(0), longitude(0), radius(0) { } 15 CircularRegionInit() : latitude(0), longitude(0), radius(0) { }
16 explicit CircularRegionInit(const Dictionary& init); 16 explicit CircularRegionInit(const Dictionary& init);
17 17
18 String id; 18 String id;
19 double latitude; 19 double latitude;
20 double longitude; 20 double longitude;
21 double radius; 21 double radius;
22 }; 22 };
23 23
24 class CircularRegion FINAL : public GeofencingRegion { 24 class CircularRegion FINAL : public GeofencingRegion {
25 DEFINE_WRAPPERTYPEINFO();
25 WTF_MAKE_NONCOPYABLE(CircularRegion); 26 WTF_MAKE_NONCOPYABLE(CircularRegion);
26 public: 27 public:
27 static CircularRegion* create(const Dictionary& init); 28 static CircularRegion* create(const Dictionary& init);
28 virtual ~CircularRegion() { } 29 virtual ~CircularRegion() { }
29 30
30 double latitude() const { return m_latitude; } 31 double latitude() const { return m_latitude; }
31 double longitude() const { return m_longitude; } 32 double longitude() const { return m_longitude; }
32 double radius() const { return m_radius; } 33 double radius() const { return m_radius; }
33 34
34 virtual void trace(Visitor* visitor) OVERRIDE { GeofencingRegion::trace(visi tor); } 35 virtual void trace(Visitor* visitor) OVERRIDE { GeofencingRegion::trace(visi tor); }
35 36
36 private: 37 private:
37 explicit CircularRegion(const CircularRegionInit&); 38 explicit CircularRegion(const CircularRegionInit&);
38 39
39 double m_latitude; 40 double m_latitude;
40 double m_longitude; 41 double m_longitude;
41 double m_radius; 42 double m_radius;
42 }; 43 };
43 44
44 } // namespace blink 45 } // namespace blink
45 46
46 #endif 47 #endif // CircularRegion_h
OLDNEW
« no previous file with comments | « Source/modules/gamepad/WebKitGamepadList.h ('k') | Source/modules/geofencing/Geofencing.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698