| OLD | NEW |
| 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 #include "content/shell/renderer/layout_test/blink_test_runner.h" | 5 #include "content/shell/renderer/layout_test/blink_test_runner.h" |
| 6 | 6 |
| 7 #include <stddef.h> | 7 #include <stddef.h> |
| 8 #include <algorithm> | 8 #include <algorithm> |
| 9 #include <clocale> | 9 #include <clocale> |
| 10 #include <cmath> | 10 #include <cmath> |
| (...skipping 764 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 775 return false; | 775 return false; |
| 776 #endif | 776 #endif |
| 777 } | 777 } |
| 778 | 778 |
| 779 bool BlinkTestRunner::AddMediaStreamAudioSourceAndTrack( | 779 bool BlinkTestRunner::AddMediaStreamAudioSourceAndTrack( |
| 780 blink::WebMediaStream* stream) { | 780 blink::WebMediaStream* stream) { |
| 781 DCHECK(stream); | 781 DCHECK(stream); |
| 782 #if defined(ENABLE_WEBRTC) | 782 #if defined(ENABLE_WEBRTC) |
| 783 return AddAudioTrackToMediaStream( | 783 return AddAudioTrackToMediaStream( |
| 784 make_scoped_refptr(new MockAudioCapturerSource()), | 784 make_scoped_refptr(new MockAudioCapturerSource()), |
| 785 false /* is_remote */, false /* is_readonly */, stream); | 785 48000 /* sample rate */, media::CHANNEL_LAYOUT_STEREO, |
| 786 480 /* sample frames per buffer */, false /* is_remote */, |
| 787 false /* is_readonly */, stream); |
| 786 #else | 788 #else |
| 787 return false; | 789 return false; |
| 788 #endif | 790 #endif |
| 789 } | 791 } |
| 790 | 792 |
| 791 // RenderViewObserver -------------------------------------------------------- | 793 // RenderViewObserver -------------------------------------------------------- |
| 792 | 794 |
| 793 void BlinkTestRunner::DidClearWindowObject(WebLocalFrame* frame) { | 795 void BlinkTestRunner::DidClearWindowObject(WebLocalFrame* frame) { |
| 794 WebTestingSupport::injectInternalsObject(frame); | 796 WebTestingSupport::injectInternalsObject(frame); |
| 795 LayoutTestRenderProcessObserver::GetInstance()->test_interfaces()->BindTo( | 797 LayoutTestRenderProcessObserver::GetInstance()->test_interfaces()->BindTo( |
| (...skipping 236 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1032 get_bluetooth_events_callbacks_.pop_front(); | 1034 get_bluetooth_events_callbacks_.pop_front(); |
| 1033 callback.Run(events); | 1035 callback.Run(events); |
| 1034 } | 1036 } |
| 1035 | 1037 |
| 1036 void BlinkTestRunner::ReportLeakDetectionResult( | 1038 void BlinkTestRunner::ReportLeakDetectionResult( |
| 1037 const LeakDetectionResult& report) { | 1039 const LeakDetectionResult& report) { |
| 1038 Send(new ShellViewHostMsg_LeakDetectionDone(routing_id(), report)); | 1040 Send(new ShellViewHostMsg_LeakDetectionDone(routing_id(), report)); |
| 1039 } | 1041 } |
| 1040 | 1042 |
| 1041 } // namespace content | 1043 } // namespace content |
| OLD | NEW |