OLD | NEW |
---|---|
1 // Copyright 2016 The Chromium Authors. All rights reserved. | 1 // Copyright 2016 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 RTCAnswerOptionsPlatform_h | 5 #ifndef RTCAnswerOptionsPlatform_h |
6 #define RTCAnswerOptionsPlatform_h | 6 #define RTCAnswerOptionsPlatform_h |
7 | 7 |
8 #include "platform/heap/Handle.h" | 8 #include "platform/heap/Handle.h" |
9 | 9 |
10 namespace blink { | 10 namespace blink { |
11 | 11 |
12 class RTCAnswerOptionsPlatform final : public GarbageCollected<RTCAnswerOptionsP latform> { | 12 class RTCAnswerOptionsPlatform final : public GarbageCollected<RTCAnswerOptionsP latform> { |
13 public: | 13 public: |
14 static RTCAnswerOptionsPlatform* create(bool voiceActivityDetection) | 14 static RTCAnswerOptionsPlatform* create(int32_t offerToReceiveVideo, int32_t offerToReceiveAudio, bool voiceActivityDetection) |
15 { | 15 { |
16 return new RTCAnswerOptionsPlatform(voiceActivityDetection); | 16 return new RTCAnswerOptionsPlatform(offerToReceiveVideo, offerToReceiveA udio, voiceActivityDetection); |
17 } | 17 } |
18 | 18 |
19 int32_t offerToReceiveVideo() const { return m_offerToReceiveVideo; } | |
20 int32_t offerToReceiveAudio() const { return m_offerToReceiveAudio; } | |
19 bool voiceActivityDetection() const { return m_voiceActivityDetection; } | 21 bool voiceActivityDetection() const { return m_voiceActivityDetection; } |
20 | 22 |
21 DEFINE_INLINE_TRACE() {} | 23 DEFINE_INLINE_TRACE() {} |
22 | 24 |
23 private: | 25 private: |
24 explicit RTCAnswerOptionsPlatform(bool voiceActivityDetection) | 26 RTCAnswerOptionsPlatform(int32_t offerToReceiveVideo, int32_t offerToReceive Audio, bool voiceActivityDetection) |
25 : m_voiceActivityDetection(voiceActivityDetection) | 27 : m_offerToReceiveVideo(offerToReceiveVideo) |
28 , m_offerToReceiveAudio(offerToReceiveAudio) | |
29 , m_voiceActivityDetection(voiceActivityDetection) | |
26 { | 30 { |
27 } | 31 } |
28 | 32 |
33 int32_t m_offerToReceiveVideo; | |
foolip
2016/06/20 08:13:47
https://google.github.io/styleguide/cppguide.html#
| |
34 int32_t m_offerToReceiveAudio; | |
29 bool m_voiceActivityDetection; | 35 bool m_voiceActivityDetection; |
30 }; | 36 }; |
31 | 37 |
32 } // namespace blink | 38 } // namespace blink |
33 | 39 |
34 #endif // RTCAnswerOptionsPlatform_h | 40 #endif // RTCAnswerOptionsPlatform_h |
OLD | NEW |