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

Side by Side Diff: content/browser/renderer_host/media/mock_media_observer.h

Issue 14600025: Replace AudioSilenceDetector with an AudioPowerMonitor. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Use CancelableCallback instead of extra-task for close reply. Created 7 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 | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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 CONTENT_BROWSER_RENDERER_HOST_MEDIA_MOCK_MEDIA_OBSERVER_H_ 5 #ifndef CONTENT_BROWSER_RENDERER_HOST_MEDIA_MOCK_MEDIA_OBSERVER_H_
6 #define CONTENT_BROWSER_RENDERER_HOST_MEDIA_MOCK_MEDIA_OBSERVER_H_ 6 #define CONTENT_BROWSER_RENDERER_HOST_MEDIA_MOCK_MEDIA_OBSERVER_H_
7 7
8 #include <string> 8 #include <string>
9 9
10 #include "base/basictypes.h" 10 #include "base/basictypes.h"
(...skipping 11 matching lines...) Expand all
22 22
23 MOCK_METHOD1(OnAudioCaptureDevicesChanged, 23 MOCK_METHOD1(OnAudioCaptureDevicesChanged,
24 void(const MediaStreamDevices& devices)); 24 void(const MediaStreamDevices& devices));
25 MOCK_METHOD1(OnVideoCaptureDevicesChanged, 25 MOCK_METHOD1(OnVideoCaptureDevicesChanged,
26 void(const MediaStreamDevices& devices)); 26 void(const MediaStreamDevices& devices));
27 MOCK_METHOD5(OnMediaRequestStateChanged, 27 MOCK_METHOD5(OnMediaRequestStateChanged,
28 void(int render_process_id, int render_view_id, 28 void(int render_process_id, int render_view_id,
29 int page_request_id, 29 int page_request_id,
30 const MediaStreamDevice& device, 30 const MediaStreamDevice& device,
31 const MediaRequestState state)); 31 const MediaRequestState state));
32 MOCK_METHOD4(OnAudioStreamPlayingChanged, 32 MOCK_METHOD6(OnAudioStreamPlayingChanged,
33 void(int render_process_id, 33 void(int render_process_id,
34 int render_view_id, 34 int render_view_id,
35 int stream_id, 35 int stream_id,
36 bool playing)); 36 bool is_playing,
37 float power_dbfs,
38 bool clipped));
37 }; 39 };
38 40
39 class MockMediaInternals : public MediaInternals { 41 class MockMediaInternals : public MediaInternals {
40 public: 42 public:
41 MockMediaInternals(); 43 MockMediaInternals();
42 virtual ~MockMediaInternals(); 44 virtual ~MockMediaInternals();
43 45
44 MOCK_METHOD2(OnDeleteAudioStream, 46 MOCK_METHOD2(OnDeleteAudioStream,
45 void(void* host, int stream_id)); 47 void(void* host, int stream_id));
46 MOCK_METHOD3(OnSetAudioStreamPlaying, 48 MOCK_METHOD3(OnSetAudioStreamPlaying,
47 void(void* host, int stream_id, bool playing)); 49 void(void* host, int stream_id, bool playing));
48 MOCK_METHOD3(OnSetAudioStreamStatus, 50 MOCK_METHOD3(OnSetAudioStreamStatus,
49 void(void* host, int stream_id, const std::string& status)); 51 void(void* host, int stream_id, const std::string& status));
50 MOCK_METHOD3(OnSetAudioStreamVolume, 52 MOCK_METHOD3(OnSetAudioStreamVolume,
51 void(void* host, int stream_id, double volume)); 53 void(void* host, int stream_id, double volume));
52 MOCK_METHOD2(OnMediaEvent, 54 MOCK_METHOD2(OnMediaEvent,
53 void(int source, const media::MediaLogEvent& event)); 55 void(int source, const media::MediaLogEvent& event));
54 }; 56 };
55 57
56 } // namespace content 58 } // namespace content
57 59
58 #endif // CONTENT_BROWSER_RENDERER_HOST_MEDIA_MOCK_MEDIA_OBSERVER_H_ 60 #endif // CONTENT_BROWSER_RENDERER_HOST_MEDIA_MOCK_MEDIA_OBSERVER_H_
OLDNEW
« no previous file with comments | « content/browser/renderer_host/media/audio_renderer_host_unittest.cc ('k') | content/public/browser/media_observer.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698