Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(2451)

Unified Diff: base/threading/simple_thread.h

Issue 1641513004: Update //base to chromium 9659b08ea5a34f889dc4166217f438095ddc10d2 (Closed) Base URL: git@github.com:domokit/mojo.git@master
Patch Set: Created 4 years, 11 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « base/threading/post_task_and_reply_impl.h ('k') | base/threading/thread.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: base/threading/simple_thread.h
diff --git a/base/threading/simple_thread.h b/base/threading/simple_thread.h
index 36548d36fd5af04711218f85eda7240b47f3f1d4..2f0eb4d778faaa825727bdecdd49ce21be6f99ce 100644
--- a/base/threading/simple_thread.h
+++ b/base/threading/simple_thread.h
@@ -59,8 +59,10 @@ class BASE_EXPORT SimpleThread : public PlatformThread::Delegate {
public:
class BASE_EXPORT Options {
public:
- Options() : stack_size_(0), priority_(ThreadPriority::NORMAL) { }
- ~Options() { }
+ Options() : stack_size_(0), priority_(ThreadPriority::NORMAL) {}
+ explicit Options(ThreadPriority priority)
+ : stack_size_(0), priority_(priority) {}
+ ~Options() {}
// We use the standard compiler-supplied copy constructor.
@@ -109,12 +111,6 @@ class BASE_EXPORT SimpleThread : public PlatformThread::Delegate {
// Overridden from PlatformThread::Delegate:
void ThreadMain() override;
- // Only set priorities with a careful understanding of the consequences.
- // This is meant for very limited use cases.
- void SetThreadPriority(ThreadPriority priority) {
- PlatformThread::SetThreadPriority(thread_, priority);
- }
-
private:
const std::string name_prefix_;
std::string name_;
« no previous file with comments | « base/threading/post_task_and_reply_impl.h ('k') | base/threading/thread.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698