Chromium Code Reviews| Index: content/browser/device_orientation/device_data.h |
| diff --git a/content/browser/device_orientation/device_data.h b/content/browser/device_orientation/device_data.h |
| new file mode 100644 |
| index 0000000000000000000000000000000000000000..f814d656de264a0f060fedcb94c3f1ad3bd6cae3 |
| --- /dev/null |
| +++ b/content/browser/device_orientation/device_data.h |
| @@ -0,0 +1,37 @@ |
| +// Copyright (c) 2012 The Chromium Authors. All rights reserved. |
| +// Use of this source code is governed by a BSD-style license that can be |
| +// found in the LICENSE file. |
| + |
| +#ifndef CONTENT_BROWSER_DEVICE_ORIENTATION_DEVICE_DATA_H_ |
| +#define CONTENT_BROWSER_DEVICE_ORIENTATION_DEVICE_DATA_H_ |
| + |
| +#include "base/memory/ref_counted.h" |
| + |
| +namespace IPC { |
| +class Message; |
| +} |
| + |
| +namespace device_orientation { |
| + |
| +class DeviceData : public base::RefCountedThreadSafe<DeviceData> { |
| + public: |
| + enum Type { |
| + kTypeOrientation |
| + }; |
| + |
| + virtual IPC::Message* CreateIPCMessage(int render_view_id) const = 0; |
| + virtual bool ShouldFireEvent(const DeviceData* other) const = 0; |
| + |
| + protected: |
| + DeviceData() {} |
|
hans
2012/07/30 16:12:52
i'm not sure this constructor is necessary?
aousterh
2012/08/03 11:08:14
I believe it is necessary because any constructor
|
| + virtual ~DeviceData() {} |
| + |
| + private: |
| + friend class base::RefCountedThreadSafe<DeviceData>; |
| + |
| + DISALLOW_COPY_AND_ASSIGN(DeviceData); |
| +}; |
| + |
| +} // namespace device_orientation |
| + |
| +#endif // CONTENT_BROWSER_DEVICE_ORIENTATION_DEVICE_DATA_H_ |