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..29039aad6b6dfde2b56c4a3e7ced427bf7fc6077 |
--- /dev/null |
+++ b/content/browser/device_orientation/device_data.h |
@@ -0,0 +1,30 @@ |
+// 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 "ipc/ipc_message.h" |
hans
2012/07/18 17:21:02
i guess this is for IPC::Message?
You could just f
aousterh
2012/07/20 11:18:52
Done.
|
+ |
+namespace device_orientation { |
+ |
+class DeviceData { |
hans
2012/07/18 17:21:02
Should this class be RefCounted? (RefCountedThread
aousterh
2012/07/20 11:18:52
Done.
|
+ public: |
+ enum Type { |
+ kTypeOrientation |
+ }; |
+ virtual ~DeviceData() {} |
+ |
+ virtual DeviceData* Clone() const = 0; |
hans
2012/07/18 17:21:02
if we make it ref counted, we might not need to Cl
aousterh
2012/07/20 11:18:52
Done.
|
+ virtual bool IsEmpty() const = 0; |
+ virtual bool SignificantlyDifferentFrom(const DeviceData& other) const = 0; |
+ virtual IPC::Message* CreateIPCMessage(int render_view_id) const = 0; |
+ |
+ static bool IsElementSignificantlyDifferent(bool can_provide_element1, |
hans
2012/07/18 17:21:02
hmm, we might actually want to implement the notio
aousterh
2012/07/20 11:18:52
ok, i moved IsElementSignificantlyDifferent to the
|
+ bool can_provide_element2, double element1, double element2); |
+}; |
+ |
+} // namespace device_orientation |
+ |
+#endif // CONTENT_BROWSER_DEVICE_ORIENTATION_DEVICE_DATA_H_ |