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

Side by Side Diff: media/audio/sounds/test_data.h

Issue 655713003: Standardize usage of virtual/override/final in media/ (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 6 years, 2 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
« no previous file with comments | « media/audio/sounds/sounds_manager.cc ('k') | media/audio/test_audio_input_controller_factory.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2013 The Chromium Authors. All rights reserved. 1 // Copyright 2013 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 MEDIA_AUDIO_SOUNDS_TEST_UTILS_H_ 5 #ifndef MEDIA_AUDIO_SOUNDS_TEST_UTILS_H_
6 #define MEDIA_AUDIO_SOUNDS_TEST_UTILS_H_ 6 #define MEDIA_AUDIO_SOUNDS_TEST_UTILS_H_
7 7
8 #include "base/basictypes.h" 8 #include "base/basictypes.h"
9 #include "base/callback.h" 9 #include "base/callback.h"
10 #include "base/compiler_specific.h" 10 #include "base/compiler_specific.h"
11 #include "media/audio/sounds/audio_stream_handler.h" 11 #include "media/audio/sounds/audio_stream_handler.h"
12 12
13 namespace base { 13 namespace base {
14 class MessageLoop; 14 class MessageLoop;
15 } 15 }
16 16
17 namespace media { 17 namespace media {
18 18
19 const int kTestAudioKey = 1000; 19 const int kTestAudioKey = 1000;
20 20
21 const char kTestAudioData[] = "RIFF\x26\x00\x00\x00WAVEfmt \x10\x00\x00\x00" 21 const char kTestAudioData[] = "RIFF\x26\x00\x00\x00WAVEfmt \x10\x00\x00\x00"
22 "\x01\x00\x02\x00\x80\xbb\x00\x00\x00\x77\x01\x00\x02\x00\x10\x00" 22 "\x01\x00\x02\x00\x80\xbb\x00\x00\x00\x77\x01\x00\x02\x00\x10\x00"
23 "data\x04\x00\x00\x00\x01\x00\x01\x00"; 23 "data\x04\x00\x00\x00\x01\x00\x01\x00";
24 24
25 class TestObserver : public AudioStreamHandler::TestObserver { 25 class TestObserver : public AudioStreamHandler::TestObserver {
26 public: 26 public:
27 TestObserver(const base::Closure& quit); 27 TestObserver(const base::Closure& quit);
28 virtual ~TestObserver(); 28 ~TestObserver() override;
29 29
30 // AudioStreamHandler::TestObserver implementation: 30 // AudioStreamHandler::TestObserver implementation:
31 virtual void OnPlay() override; 31 void OnPlay() override;
32 virtual void OnStop(size_t cursor) override; 32 void OnStop(size_t cursor) override;
33 33
34 int num_play_requests() const { return num_play_requests_; } 34 int num_play_requests() const { return num_play_requests_; }
35 int num_stop_requests() const { return num_stop_requests_; } 35 int num_stop_requests() const { return num_stop_requests_; }
36 int cursor() const { return cursor_; } 36 int cursor() const { return cursor_; }
37 37
38 private: 38 private:
39 base::MessageLoop* loop_; 39 base::MessageLoop* loop_;
40 base::Closure quit_; 40 base::Closure quit_;
41 41
42 int num_play_requests_; 42 int num_play_requests_;
43 int num_stop_requests_; 43 int num_stop_requests_;
44 int cursor_; 44 int cursor_;
45 45
46 DISALLOW_COPY_AND_ASSIGN(TestObserver); 46 DISALLOW_COPY_AND_ASSIGN(TestObserver);
47 }; 47 };
48 48
49 } // namespace media 49 } // namespace media
50 50
51 #endif // MEDIA_AUDIO_SOUNDS_TEST_UTILS_H_ 51 #endif // MEDIA_AUDIO_SOUNDS_TEST_UTILS_H_
OLDNEW
« no previous file with comments | « media/audio/sounds/sounds_manager.cc ('k') | media/audio/test_audio_input_controller_factory.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698