OLD | NEW |
(Empty) | |
| 1 // Copyright 2014 The Chromium Authors. All rights reserved. |
| 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 MEDIA_VIDEO_CAPTURE_VIDEO_CAPTURE_EVENT_HANDLER_H_ |
| 6 #define MEDIA_VIDEO_CAPTURE_VIDEO_CAPTURE_EVENT_HANDLER_H_ |
| 7 |
| 8 #include "base/basictypes.h" |
| 9 #include "base/compiler_specific.h" |
| 10 #include "media/video/capture/video_capture.h" |
| 11 #include "testing/gmock/include/gmock/gmock.h" |
| 12 |
| 13 namespace media { |
| 14 |
| 15 class MockVideoCaptureEventHandler : public VideoCapture::EventHandler { |
| 16 public: |
| 17 MockVideoCaptureEventHandler(); |
| 18 virtual ~MockVideoCaptureEventHandler(); |
| 19 |
| 20 // EventHandler implementation. |
| 21 MOCK_METHOD1(OnStarted, void(VideoCapture* capture)); |
| 22 MOCK_METHOD1(OnStopped, void(VideoCapture* capture)); |
| 23 MOCK_METHOD1(OnPaused, void(VideoCapture* capture)); |
| 24 MOCK_METHOD2(OnError, void(VideoCapture* capture, int error_code)); |
| 25 MOCK_METHOD1(OnRemoved, void(VideoCapture* capture)); |
| 26 MOCK_METHOD2(OnFrameReady, |
| 27 void(VideoCapture* capture, |
| 28 const scoped_refptr<VideoFrame>& frame)); |
| 29 MOCK_METHOD2(OnDeviceInfoReceived, |
| 30 void(VideoCapture* capture, |
| 31 const VideoCaptureFormat& device_info)); |
| 32 MOCK_METHOD1(OnDeviceSupportedFormatsEnumerated, |
| 33 void(const media::VideoCaptureFormats& supported_formats)); |
| 34 MOCK_METHOD1(OnDeviceFormatsInUseReceived, |
| 35 void(const media::VideoCaptureFormats& formats_in_use)); |
| 36 }; |
| 37 |
| 38 } // namespace media |
| 39 |
| 40 #endif // MEDIA_VIDEO_CAPTURE_VIDEO_CAPTURE_EVENT_HANDLER_H_ |
OLD | NEW |