OLD | NEW |
---|---|
(Empty) | |
1 // Copyright (c) 2013 The Chromium Authors. All rights reserved. | |
Peter Beverloo
2013/06/13 11:27:45
This file already is in content/browser/, I'd say
Michael van Ouwerkerk
2013/06/18 14:39:23
Done.
| |
2 // Use of this source code is governed by a BSD-style license that can be | |
3 // found in the LICENSE file. | |
4 | |
5 #ifndef CONTENT_BROWSER_VIBRATION_VIBRATION_BROWSER_MESSAGE_FILTER_H_ | |
6 #define CONTENT_BROWSER_VIBRATION_VIBRATION_BROWSER_MESSAGE_FILTER_H_ | |
7 | |
8 #include "base/memory/scoped_ptr.h" | |
9 #include "content/browser/vibration/vibration_service.h" | |
10 #include "content/public/browser/browser_message_filter.h" | |
11 | |
12 namespace content { | |
13 | |
14 class RenderProcessHost; | |
Peter Beverloo
2013/06/13 11:27:45
nit: Unused forward declaration.
Michael van Ouwerkerk
2013/06/18 14:39:23
Done.
| |
15 | |
16 class VibrationBrowserMessageFilter : public BrowserMessageFilter { | |
17 public: | |
18 VibrationBrowserMessageFilter(scoped_ptr<VibrationService> vibration_service); | |
Peter Beverloo
2013/06/13 11:27:45
nit: Pass the scoped_ptr<> as a reference, if you
Michael van Ouwerkerk
2013/06/18 14:39:23
Done.
| |
19 | |
20 // BrowserMessageFilter implementation. | |
21 virtual bool OnMessageReceived(const IPC::Message& message, | |
22 bool* message_was_ok) OVERRIDE; | |
23 | |
24 private: | |
25 ~VibrationBrowserMessageFilter(); | |
26 | |
27 void OnVibrate(unsigned time); | |
Peter Beverloo
2013/06/13 11:27:45
nit: maybe naming the time argument "milliseconds"
Michael van Ouwerkerk
2013/06/18 14:39:23
Done.
| |
28 void OnCancelVibration(); | |
29 | |
30 scoped_ptr<VibrationService> vibration_service_; | |
31 }; | |
32 | |
33 } // namespace content | |
34 | |
35 #endif // CONTENT_BROWSER_VIBRATION_VIBRATION_BROWSER_MESSAGE_FILTER_H_ | |
OLD | NEW |