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

Side by Side Diff: Source/modules/screen_orientation/OrientationInformation.h

Issue 367113005: Remove destructors from ScriptWrappable objects in modules/ (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Add Finalizable transition type Created 6 years, 5 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 OrientationInformation_h 5 #ifndef OrientationInformation_h
6 #define OrientationInformation_h 6 #define OrientationInformation_h
7 7
8 #include "bindings/core/v8/ScriptWrappable.h" 8 #include "bindings/core/v8/ScriptWrappable.h"
9 #include "public/platform/WebScreenOrientationType.h" 9 #include "public/platform/WebScreenOrientationType.h"
10 #include "wtf/text/WTFString.h" 10 #include "wtf/text/WTFString.h"
11 11
12 namespace WebCore { 12 namespace WebCore {
13 13
14 // OrientationInformation is the C++ counter-part of the OrientationInformation 14 // OrientationInformation is the C++ counter-part of the OrientationInformation
15 // web interface. It is GarbageCollectedFinalized because ScriptWrappable 15 // web interface.
16 // requires it.
17 class OrientationInformation FINAL 16 class OrientationInformation FINAL
18 : public GarbageCollectedFinalized<OrientationInformation> 17 : public GarbageCollectedFinalizedWillBeGarbageCollected<OrientationInformat ion>
19 , public ScriptWrappable { 18 , public ScriptWrappable {
20 public: 19 public:
21 OrientationInformation(); 20 OrientationInformation();
22 bool initialized() const; 21 bool initialized() const;
23 22
24 String type() const; 23 String type() const;
25 unsigned short angle() const; 24 unsigned short angle() const;
26 25
27 void setType(blink::WebScreenOrientationType); 26 void setType(blink::WebScreenOrientationType);
28 void setAngle(unsigned short); 27 void setAngle(unsigned short);
29 28
30 void trace(Visitor*) { } 29 void trace(Visitor*) { }
31 30
32 private: 31 private:
33 blink::WebScreenOrientationType m_type; 32 blink::WebScreenOrientationType m_type;
34 unsigned short m_angle; 33 unsigned short m_angle;
35 }; 34 };
36 35
37 } // namespace WebCore 36 } // namespace WebCore
38 37
39 #endif // OrientationInformation_h 38 #endif // OrientationInformation_h
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698