| OLD | NEW |
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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 PPAPI_CPP_MESSAGE_LOOP_H_ | 5 #ifndef PPAPI_CPP_MESSAGE_LOOP_H_ |
| 6 #define PPAPI_CPP_MESSAGE_LOOP_H_ | 6 #define PPAPI_CPP_MESSAGE_LOOP_H_ |
| 7 | 7 |
| 8 #include <stdint.h> | 8 #include <stdint.h> |
| 9 | 9 |
| 10 #include "ppapi/cpp/resource.h" | 10 #include "ppapi/cpp/resource.h" |
| (...skipping 166 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 177 /// loop attached to it. See the interface level discussion about these | 177 /// loop attached to it. See the interface level discussion about these |
| 178 /// special threads, which include realtime audio threads. | 178 /// special threads, which include realtime audio threads. |
| 179 int32_t AttachToCurrentThread(); | 179 int32_t AttachToCurrentThread(); |
| 180 | 180 |
| 181 /// Runs the thread message loop. Running the message loop is required for | 181 /// Runs the thread message loop. Running the message loop is required for |
| 182 /// you to get issued completion callbacks on the thread. | 182 /// you to get issued completion callbacks on the thread. |
| 183 /// | 183 /// |
| 184 /// The message loop identified by the argument must have been previously | 184 /// The message loop identified by the argument must have been previously |
| 185 /// successfully attached to the current thread. | 185 /// successfully attached to the current thread. |
| 186 /// | 186 /// |
| 187 /// You may not run nested message loops. Since the main thread has an | 187 /// You may not run nested run loops. Since the main thread has an |
| 188 /// implicit message loop that the system runs, you may not call Run on the | 188 /// implicit message loop that the system runs, you may not call Run on the |
| 189 /// main thread. | 189 /// main thread. |
| 190 /// | 190 /// |
| 191 /// @return | 191 /// @return |
| 192 /// - PP_OK: The message loop was successfully run. Note that on | 192 /// - PP_OK: The message loop was successfully run. Note that on |
| 193 /// success, the message loop will only exit when you call PostQuit(). | 193 /// success, the message loop will only exit when you call PostQuit(). |
| 194 /// - PP_ERROR_BADRESOURCE: The given message loop resource is invalid. | 194 /// - PP_ERROR_BADRESOURCE: The given message loop resource is invalid. |
| 195 /// - PP_ERROR_WRONG_THREAD: You are attempting to run a message loop that | 195 /// - PP_ERROR_WRONG_THREAD: You are attempting to run a message loop that |
| 196 /// has not been successfully attached to the current thread. Call | 196 /// has not been successfully attached to the current thread. Call |
| 197 /// AttachToCurrentThread(). | 197 /// AttachToCurrentThread(). |
| (...skipping 63 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 261 /// - PP_ERROR_BADRESOURCE: The message loop was invalid. | 261 /// - PP_ERROR_BADRESOURCE: The message loop was invalid. |
| 262 /// - PP_ERROR_WRONG_THREAD: You are attempting to quit the main thread. | 262 /// - PP_ERROR_WRONG_THREAD: You are attempting to quit the main thread. |
| 263 /// The main thread's message loop is managed by the system and can't be | 263 /// The main thread's message loop is managed by the system and can't be |
| 264 /// quit. | 264 /// quit. |
| 265 int32_t PostQuit(bool should_destroy); | 265 int32_t PostQuit(bool should_destroy); |
| 266 }; | 266 }; |
| 267 | 267 |
| 268 } // namespace pp | 268 } // namespace pp |
| 269 | 269 |
| 270 #endif // PPAPI_CPP_MESSAGE_LOOP_H_ | 270 #endif // PPAPI_CPP_MESSAGE_LOOP_H_ |
| OLD | NEW |