diff options
Diffstat (limited to 'Source/WebCore/dom/DeviceMotionController.h')
-rw-r--r-- | Source/WebCore/dom/DeviceMotionController.h | 19 |
1 files changed, 6 insertions, 13 deletions
diff --git a/Source/WebCore/dom/DeviceMotionController.h b/Source/WebCore/dom/DeviceMotionController.h index deb0620d1..8cd2e2946 100644 --- a/Source/WebCore/dom/DeviceMotionController.h +++ b/Source/WebCore/dom/DeviceMotionController.h @@ -24,8 +24,7 @@ * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ -#ifndef DeviceMotionController_h -#define DeviceMotionController_h +#pragma once #include "DeviceController.h" #include <wtf/Noncopyable.h> @@ -35,12 +34,11 @@ namespace WebCore { class DeviceMotionClient; class DeviceMotionData; -class DeviceMotionController : public DeviceController { +class DeviceMotionController final : public DeviceController { WTF_MAKE_NONCOPYABLE(DeviceMotionController); public: - ~DeviceMotionController() { }; - - static PassOwnPtr<DeviceMotionController> create(DeviceMotionClient*); + explicit DeviceMotionController(DeviceMotionClient*); + virtual ~DeviceMotionController() { } #if PLATFORM(IOS) // FIXME: We should look to reconcile the iOS and OpenSource differences with this class @@ -52,17 +50,12 @@ public: void didChangeDeviceMotion(DeviceMotionData*); DeviceMotionClient* deviceMotionClient(); - virtual bool hasLastData() override; - virtual PassRefPtr<Event> getLastEvent() override; + bool hasLastData() override; + RefPtr<Event> getLastEvent() override; static const char* supplementName(); static DeviceMotionController* from(Page*); static bool isActiveAt(Page*); - -private: - explicit DeviceMotionController(DeviceMotionClient*); }; } // namespace WebCore - -#endif // DeviceMotionController_h |