| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright 2012 The WebRTC project authors. All Rights Reserved. | 2 * Copyright 2012 The WebRTC project authors. All Rights Reserved. |
| 3 * | 3 * |
| 4 * Use of this source code is governed by a BSD-style license | 4 * Use of this source code is governed by a BSD-style license |
| 5 * that can be found in the LICENSE file in the root of the source | 5 * that can be found in the LICENSE file in the root of the source |
| 6 * tree. An additional intellectual property rights grant can be found | 6 * tree. An additional intellectual property rights grant can be found |
| 7 * in the file PATENTS. All contributing project authors may | 7 * in the file PATENTS. All contributing project authors may |
| 8 * be found in the AUTHORS file in the root of the source tree. | 8 * be found in the AUTHORS file in the root of the source tree. |
| 9 */ | 9 */ |
| 10 | 10 |
| (...skipping 77 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 88 } | 88 } |
| 89 last_insert_dtmf_call_ = rtc::Time(); | 89 last_insert_dtmf_call_ = rtc::Time(); |
| 90 | 90 |
| 91 LOG(LS_VERBOSE) << "FakeDtmfProvider::InsertDtmf code=" << code | 91 LOG(LS_VERBOSE) << "FakeDtmfProvider::InsertDtmf code=" << code |
| 92 << " duration=" << duration | 92 << " duration=" << duration |
| 93 << " gap=" << gap << "."; | 93 << " gap=" << gap << "."; |
| 94 dtmf_info_queue_.push_back(DtmfInfo(code, duration, gap)); | 94 dtmf_info_queue_.push_back(DtmfInfo(code, duration, gap)); |
| 95 return true; | 95 return true; |
| 96 } | 96 } |
| 97 | 97 |
| 98 virtual sigslot::signal0<>* GetOnDestroyedSignal() { | 98 sigslot::signal0<>* GetOnDestroyedSignal() override { |
| 99 return &SignalDestroyed; | 99 return &SignalDestroyed; |
| 100 } | 100 } |
| 101 | 101 |
| 102 // getter and setter | 102 // getter and setter |
| 103 const std::vector<DtmfInfo>& dtmf_info_queue() const { | 103 const std::vector<DtmfInfo>& dtmf_info_queue() const { |
| 104 return dtmf_info_queue_; | 104 return dtmf_info_queue_; |
| 105 } | 105 } |
| 106 | 106 |
| 107 // helper functions | 107 // helper functions |
| 108 void AddCanInsertDtmfTrack(const std::string& label) { | 108 void AddCanInsertDtmfTrack(const std::string& label) { |
| (...skipping 224 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 333 std::string tones = "3,4"; | 333 std::string tones = "3,4"; |
| 334 int duration = 100; | 334 int duration = 100; |
| 335 int inter_tone_gap = 50; | 335 int inter_tone_gap = 50; |
| 336 | 336 |
| 337 EXPECT_FALSE(dtmf_->InsertDtmf(tones, 6001, inter_tone_gap)); | 337 EXPECT_FALSE(dtmf_->InsertDtmf(tones, 6001, inter_tone_gap)); |
| 338 EXPECT_FALSE(dtmf_->InsertDtmf(tones, 69, inter_tone_gap)); | 338 EXPECT_FALSE(dtmf_->InsertDtmf(tones, 69, inter_tone_gap)); |
| 339 EXPECT_FALSE(dtmf_->InsertDtmf(tones, duration, 49)); | 339 EXPECT_FALSE(dtmf_->InsertDtmf(tones, duration, 49)); |
| 340 | 340 |
| 341 EXPECT_TRUE(dtmf_->InsertDtmf(tones, duration, inter_tone_gap)); | 341 EXPECT_TRUE(dtmf_->InsertDtmf(tones, duration, inter_tone_gap)); |
| 342 } | 342 } |
| OLD | NEW |