| Index: webrtc/base/platform_thread.h
|
| diff --git a/webrtc/base/platform_thread.h b/webrtc/base/platform_thread.h
|
| index 53465e4b17a2f06334cefc17d91add8bd23c9019..8c2161baa891c4018c8ca3b18995349a25e9752f 100644
|
| --- a/webrtc/base/platform_thread.h
|
| +++ b/webrtc/base/platform_thread.h
|
| @@ -59,18 +59,30 @@ class PlatformThread {
|
| PlatformThread(ThreadRunFunction func, void* obj, const char* thread_name);
|
| virtual ~PlatformThread();
|
|
|
| + const std::string& name() const { return name_; }
|
| +
|
| // Spawns a thread and tries to set thread priority according to the priority
|
| // from when CreateThread was called.
|
| void Start();
|
|
|
| bool IsRunning() const;
|
|
|
| + // Returns an identifier for the worker thread that can be used to do
|
| + // thread checks.
|
| + PlatformThreadRef GetThreadRef() const;
|
| +
|
| // Stops (joins) the spawned thread.
|
| void Stop();
|
|
|
| // Set the priority of the thread. Must be called when thread is running.
|
| bool SetPriority(ThreadPriority priority);
|
|
|
| + protected:
|
| +#if defined(WEBRTC_WIN)
|
| + // Exposed to derived classes to allow for special cases specific to Windows.
|
| + bool QueueAPC(PAPCFUNC apc_function, ULONG_PTR data);
|
| +#endif
|
| +
|
| private:
|
| void Run();
|
|
|
| @@ -85,6 +97,7 @@ class PlatformThread {
|
|
|
| bool stop_;
|
| HANDLE thread_;
|
| + DWORD thread_id_;
|
| #else
|
| static void* StartThread(void* param);
|
|
|
|
|