Use the DtlsSrtpTransport in BaseChannel.

The DtlsSrtpTransport takes the reponsiblity of setting up DTLS-SRTP from
the BaseChannel.

The BaseChannel doesn't handle the signals from the P2P layer transport anymore.
The RtpTransport handles the signals from the PacketTransportInternal and the
DtlsSrtpTransport handles the DTLS-specific signals and determines when to extract
the keys and setting the parameters.

In channel_unittests.cc, call from DTLS to SDES is expected to fail since the
fallback from DTLS to SDES is not supported.

Bug: webrtc:7013
Change-Id: I0a54e017986f5a8ae9710e79643a4651bef3c38f
Reviewed-on: https://webrtc-review.googlesource.com/24702
Commit-Queue: Zhi Huang <zhihuang@webrtc.org>
Reviewed-by: Peter Thatcher <pthatcher@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#20941}
diff --git a/pc/dtlssrtptransport.h b/pc/dtlssrtptransport.h
index 43f072a..e033425 100644
--- a/pc/dtlssrtptransport.h
+++ b/pc/dtlssrtptransport.h
@@ -38,10 +38,10 @@
   void SetRtcpMuxEnabled(bool enable) override;
 
   // Set the header extension ids that should be encrypted.
-  void SetSendEncryptedHeaderExtensionIds(
+  void UpdateSendEncryptedHeaderExtensionIds(
       const std::vector<int>& send_extension_ids);
 
-  void SetRecvEncryptedHeaderExtensionIds(
+  void UpdateRecvEncryptedHeaderExtensionIds(
       const std::vector<int>& recv_extension_ids);
 
   bool IsActive() { return srtp_transport_->IsActive(); }
@@ -75,7 +75,8 @@
 
   void OnDtlsState(cricket::DtlsTransportInternal* dtls_transport,
                    cricket::DtlsTransportState state);
-  void OnWritableState(rtc::PacketTransportInternal* transport);
+  void OnWritableState(bool writable);
+  void OnSentPacket(const rtc::SentPacket& sent_packet);
   void OnPacketReceived(bool rtcp,
                         rtc::CopyOnWriteBuffer* packet,
                         const rtc::PacketTime& packet_time);