OLD | NEW |
1 // Copyright (c) 2013 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2013 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #include "content/browser/streams/stream_handle_impl.h" | 5 #include "content/browser/streams/stream_handle_impl.h" |
6 | 6 |
7 #include <stddef.h> | 7 #include <stddef.h> |
8 | 8 |
9 #include "base/bind.h" | 9 #include "base/bind.h" |
10 #include "base/location.h" | 10 #include "base/location.h" |
11 #include "base/thread_task_runner_handle.h" | 11 #include "base/threading/thread_task_runner_handle.h" |
12 #include "content/browser/streams/stream.h" | 12 #include "content/browser/streams/stream.h" |
13 | 13 |
14 namespace content { | 14 namespace content { |
15 | 15 |
16 namespace { | 16 namespace { |
17 | 17 |
18 void RunCloseListeners(const std::vector<base::Closure>& close_listeners) { | 18 void RunCloseListeners(const std::vector<base::Closure>& close_listeners) { |
19 for (size_t i = 0; i < close_listeners.size(); ++i) | 19 for (size_t i = 0; i < close_listeners.size(); ++i) |
20 close_listeners[i].Run(); | 20 close_listeners[i].Run(); |
21 } | 21 } |
(...skipping 14 matching lines...) Expand all Loading... |
36 | 36 |
37 const GURL& StreamHandleImpl::GetURL() { | 37 const GURL& StreamHandleImpl::GetURL() { |
38 return url_; | 38 return url_; |
39 } | 39 } |
40 | 40 |
41 void StreamHandleImpl::AddCloseListener(const base::Closure& callback) { | 41 void StreamHandleImpl::AddCloseListener(const base::Closure& callback) { |
42 close_listeners_.push_back(callback); | 42 close_listeners_.push_back(callback); |
43 } | 43 } |
44 | 44 |
45 } // namespace content | 45 } // namespace content |
OLD | NEW |