| OLD | NEW |
| 1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 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 #ifndef NET_BASE_COMPLETION_CALLBACK_H__ | 5 #ifndef NET_BASE_COMPLETION_CALLBACK_H__ |
| 6 #define NET_BASE_COMPLETION_CALLBACK_H__ | 6 #define NET_BASE_COMPLETION_CALLBACK_H__ |
| 7 #pragma once | 7 #pragma once |
| 8 | 8 |
| 9 #include "base/callback_old.h" | 9 #include "base/callback_old.h" |
| 10 #include "base/callback.h" | 10 #include "base/callback.h" |
| (...skipping 42 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 53 base::RefCounted<CancelableOldCompletionCallback<T> >::Release(); | 53 base::RefCounted<CancelableOldCompletionCallback<T> >::Release(); |
| 54 } else { | 54 } else { |
| 55 OldCompletionCallbackImpl<T>::RunWithParams(params); | 55 OldCompletionCallbackImpl<T>::RunWithParams(params); |
| 56 } | 56 } |
| 57 } | 57 } |
| 58 | 58 |
| 59 private: | 59 private: |
| 60 bool is_canceled_; | 60 bool is_canceled_; |
| 61 }; | 61 }; |
| 62 | 62 |
| 63 // Helper function for using OldCompletionCallback objects with |
| 64 // the newer CompletionCallback APIs. |
| 65 // |
| 66 // This is a transitional function and should be removed when |
| 67 // OldCompletionCallbackAdapter is deleted. |
| 68 void OldCompletionCallbackAdapter(OldCompletionCallback* old_callback, int rv); |
| 69 |
| 63 } // namespace net | 70 } // namespace net |
| 64 | 71 |
| 65 #endif // NET_BASE_COMPLETION_CALLBACK_H__ | 72 #endif // NET_BASE_COMPLETION_CALLBACK_H__ |
| OLD | NEW |