| Index: webrtc/p2p/base/p2ptransportchannel.h
|
| diff --git a/webrtc/p2p/base/p2ptransportchannel.h b/webrtc/p2p/base/p2ptransportchannel.h
|
| index 335ee7d166205040c24b3cb0a74dc12bec59ca97..83090206ca046b99f3cc64704ee8509a6eca0d35 100644
|
| --- a/webrtc/p2p/base/p2ptransportchannel.h
|
| +++ b/webrtc/p2p/base/p2ptransportchannel.h
|
| @@ -51,10 +51,10 @@ class RemoteCandidate : public Candidate {
|
| class P2PTransportChannel : public TransportChannelImpl,
|
| public rtc::MessageHandler {
|
| public:
|
| - P2PTransportChannel(const std::string& content_name,
|
| + P2PTransportChannel(const std::string& transport_name,
|
| int component,
|
| P2PTransport* transport,
|
| - PortAllocator *allocator);
|
| + PortAllocator* allocator);
|
| virtual ~P2PTransportChannel();
|
|
|
| // From TransportChannelImpl:
|
| @@ -69,8 +69,8 @@ class P2PTransportChannel : public TransportChannelImpl,
|
| const std::string& ice_pwd);
|
| virtual void SetRemoteIceMode(IceMode mode);
|
| virtual void Connect();
|
| - virtual void OnSignalingReady();
|
| - virtual void OnCandidate(const Candidate& candidate);
|
| + virtual IceGatheringState gathering_state() const { return gathering_state_; }
|
| + virtual void AddRemoteCandidate(const Candidate& candidate);
|
| // Sets the receiving timeout in milliseconds.
|
| // This also sets the check_receiving_delay proportionally.
|
| virtual void SetReceivingTimeout(int receiving_timeout_ms);
|
| @@ -166,7 +166,7 @@ class P2PTransportChannel : public TransportChannelImpl,
|
| return allocator_sessions_.back();
|
| }
|
|
|
| - void Allocate();
|
| + void StartGatheringCandidates();
|
| void UpdateConnectionStates();
|
| void RequestSort();
|
| void SortConnections();
|
| @@ -223,10 +223,9 @@ class P2PTransportChannel : public TransportChannelImpl,
|
| Connection* best_nominated_connection() const;
|
|
|
| P2PTransport* transport_;
|
| - PortAllocator *allocator_;
|
| - rtc::Thread *worker_thread_;
|
| + PortAllocator* allocator_;
|
| + rtc::Thread* worker_thread_;
|
| bool incoming_only_;
|
| - bool waiting_for_signaling_;
|
| int error_;
|
| std::vector<PortAllocatorSession*> allocator_sessions_;
|
| std::vector<PortInterface *> ports_;
|
| @@ -238,6 +237,7 @@ class P2PTransportChannel : public TransportChannelImpl,
|
| std::vector<RemoteCandidate> remote_candidates_;
|
| bool sort_dirty_; // indicates whether another sort is needed right now
|
| bool was_writable_;
|
| + bool had_connection_ = false; // if connections_ has ever been nonempty
|
| typedef std::map<rtc::Socket::Option, int> OptionMap;
|
| OptionMap options_;
|
| std::string ice_ufrag_;
|
| @@ -248,6 +248,7 @@ class P2PTransportChannel : public TransportChannelImpl,
|
| IceRole ice_role_;
|
| uint64 tiebreaker_;
|
| uint32 remote_candidate_generation_;
|
| + IceGatheringState gathering_state_;
|
|
|
| int check_receiving_delay_;
|
| int receiving_timeout_;
|
|
|