Chromium Code Reviews| Index: src/cancelable-task.h |
| diff --git a/src/cancelable-task.h b/src/cancelable-task.h |
| index 578db6f6b997c624a0c3a7af901978f6fd534de7..7636bf6f13c7dd3ff6c9c0aea2070612b989422f 100644 |
| --- a/src/cancelable-task.h |
| +++ b/src/cancelable-task.h |
| @@ -45,6 +45,17 @@ class V8_EXPORT_PRIVATE CancelableTaskManager { |
| // already running. This disallows subsequent Register calls. |
| void CancelAndWait(); |
| + // Tries to cancel all remaining registered tasks. The return value indicates |
| + // whether |
| + // |
| + // 1) No tasks were registered (kTaskRemoved), or |
| + // |
| + // 2) There is at least one remaining task that couldn't be cancled |
| + // (kTaskRunning), or |
| + // |
| + // 3) All registered tasks were cancelled (kTaskAborted). |
| + TryAbortResult Cancel(); |
|
marja
2017/01/04 12:54:43
The naming is confusing but it's there because of
jochen (gone - plz use gerrit)
2017/01/04 13:18:31
what about just renaming Cancel to TryAbortAll? Ca
|
| + |
| private: |
| // Only called by {Cancelable} destructor. The task is done with executing, |
| // but needs to be removed. |