Update libjingle to 61168196
R=mallinath@webrtc.org Review URL: https://webrtc-codereview.appspot.com/8139004 git-svn-id: http://webrtc.googlecode.com/svn/trunk@5502 4adac7df-926f-26a2-2b94-8c16560cd09d
This commit is contained in:
@ -223,33 +223,6 @@ class Thread : public MessageQueue {
|
||||
void Join();
|
||||
|
||||
private:
|
||||
// Helper class to facilitate executing a functor on a thread.
|
||||
template <class ReturnT, class FunctorT>
|
||||
class FunctorMessageHandler : public MessageHandler {
|
||||
public:
|
||||
explicit FunctorMessageHandler(const FunctorT& functor)
|
||||
: functor_(functor) {}
|
||||
virtual void OnMessage(Message* msg) {
|
||||
result_ = functor_();
|
||||
}
|
||||
const ReturnT& result() const { return result_; }
|
||||
private:
|
||||
FunctorT functor_;
|
||||
ReturnT result_;
|
||||
};
|
||||
|
||||
// Specialization for ReturnT of void.
|
||||
template <class FunctorT>
|
||||
class FunctorMessageHandler<void, FunctorT> : public MessageHandler {
|
||||
public:
|
||||
explicit FunctorMessageHandler(const FunctorT& functor)
|
||||
: functor_(functor) {}
|
||||
virtual void OnMessage(Message* msg) { functor_(); }
|
||||
void result() const {}
|
||||
private:
|
||||
FunctorT functor_;
|
||||
};
|
||||
|
||||
static void *PreRun(void *pv);
|
||||
|
||||
// ThreadManager calls this instead WrapCurrent() because
|
||||
|
||||
Reference in New Issue
Block a user