Chromium Code Reviews| OLD | NEW |
|---|---|
| (Empty) | |
| 1 // Copyright 2014 The Chromium Authors. All rights reserved. | |
| 2 // Use of this source code is governed by a BSD-style license that can be | |
| 3 // found in the LICENSE file. | |
| 4 | |
| 5 #ifndef WebWorkerSettings_h | |
| 6 #define WebWorkerSettings_h | |
| 7 | |
| 8 #include "public/platform/WebCommon.h" | |
| 9 #include "public/platform/WebPrivateOwnPtr.h" | |
| 10 | |
| 11 namespace WebCore { | |
| 12 class WorkerSettings; | |
| 13 } | |
| 14 | |
| 15 #if BLINK_IMPLEMENTATION | |
| 16 namespace WTF { template <typename T> class PassOwnPtr; } | |
| 17 #endif | |
| 18 | |
| 19 namespace blink { | |
| 20 | |
| 21 // WebWorkerSettings is owned by the WebSharedWorker, and allows code to | |
| 22 // modify the settings for the WebSharedWorker. | |
|
kinuko
2014/03/10 05:55:52
This comment looks wrong now?
| |
| 23 class WebWorkerSettings { | |
| 24 public: | |
| 25 ~WebWorkerSettings() { reset(); } | |
| 26 | |
| 27 WebWorkerSettings(const WebWorkerSettings& n) { assign(n); } | |
| 28 | |
| 29 WebWorkerSettings& operator=(const WebWorkerSettings& n) | |
| 30 { | |
| 31 assign(n); | |
| 32 return *this; | |
| 33 } | |
| 34 | |
| 35 BLINK_EXPORT static WebWorkerSettings create(); | |
| 36 BLINK_EXPORT void reset(); | |
| 37 BLINK_EXPORT void assign(const WebWorkerSettings&); | |
| 38 | |
| 39 BLINK_EXPORT void setMemoryInfoEnabled(bool); | |
|
abarth-chromium
2014/03/10 21:32:36
Does this setting need to be per-worker? Do we no
abarth-chromium
2014/03/10 21:33:29
If this maps to a command-line flag in Chromium, i
| |
| 40 | |
| 41 #if BLINK_IMPLEMENTATION | |
| 42 WebWorkerSettings(const WTF::PassOwnPtr<WebCore::WorkerSettings>&); | |
| 43 operator WTF::PassOwnPtr<WebCore::WorkerSettings>() const; | |
| 44 #endif | |
| 45 | |
| 46 private: | |
| 47 WebPrivateOwnPtr<WebCore::WorkerSettings> m_private; | |
| 48 }; | |
| 49 | |
| 50 } // namespace blink | |
| 51 | |
| 52 #endif | |
| OLD | NEW |