Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(365)

Side by Side Diff: mojo/public/cpp/bindings/lib/router.cc

Issue 2397353002: Purge references of "Mojo Application" from comments & var names. (Closed)
Patch Set: Created 4 years, 2 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « mojo/public/cpp/bindings/lib/interface_endpoint_client.cc ('k') | mojo/public/js/threading.js » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 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 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 "mojo/public/cpp/bindings/lib/router.h" 5 #include "mojo/public/cpp/bindings/lib/router.h"
6 6
7 #include <stdint.h> 7 #include <stdint.h>
8 8
9 #include <utility> 9 #include <utility>
10 10
(...skipping 20 matching lines...) Expand all
31 31
32 class ResponderThunk : public MessageReceiverWithStatus { 32 class ResponderThunk : public MessageReceiverWithStatus {
33 public: 33 public:
34 explicit ResponderThunk(const base::WeakPtr<Router>& router, 34 explicit ResponderThunk(const base::WeakPtr<Router>& router,
35 scoped_refptr<base::SingleThreadTaskRunner> runner) 35 scoped_refptr<base::SingleThreadTaskRunner> runner)
36 : router_(router), 36 : router_(router),
37 accept_was_invoked_(false), 37 accept_was_invoked_(false),
38 task_runner_(std::move(runner)) {} 38 task_runner_(std::move(runner)) {}
39 ~ResponderThunk() override { 39 ~ResponderThunk() override {
40 if (!accept_was_invoked_) { 40 if (!accept_was_invoked_) {
41 // The Mojo application handled a message that was expecting a response 41 // The Service handled a message that was expecting a response
42 // but did not send a response. 42 // but did not send a response.
43 // We raise an error to signal the calling application that an error 43 // We raise an error to signal the calling application that an error
44 // condition occurred. Without this the calling application would have no 44 // condition occurred. Without this the calling application would have no
45 // way of knowing it should stop waiting for a response. 45 // way of knowing it should stop waiting for a response.
46 if (task_runner_->RunsTasksOnCurrentThread()) { 46 if (task_runner_->RunsTasksOnCurrentThread()) {
47 // Please note that even if this code is run from a different task 47 // Please note that even if this code is run from a different task
48 // runner on the same thread as |task_runner_|, it is okay to directly 48 // runner on the same thread as |task_runner_|, it is okay to directly
49 // call Router::RaiseError(), because it will raise error from the 49 // call Router::RaiseError(), because it will raise error from the
50 // correct task runner asynchronously. 50 // correct task runner asynchronously.
51 if (router_) 51 if (router_)
(...skipping 284 matching lines...) Expand 10 before | Expand all | Expand 10 after
336 std::string description = control_message_handler_.disconnect_description(); 336 std::string description = control_message_handler_.disconnect_description();
337 error_with_reason_handler_.Run( 337 error_with_reason_handler_.Run(
338 control_message_handler_.disconnect_custom_reason(), description); 338 control_message_handler_.disconnect_custom_reason(), description);
339 } 339 }
340 } 340 }
341 341
342 // ---------------------------------------------------------------------------- 342 // ----------------------------------------------------------------------------
343 343
344 } // namespace internal 344 } // namespace internal
345 } // namespace mojo 345 } // namespace mojo
OLDNEW
« no previous file with comments | « mojo/public/cpp/bindings/lib/interface_endpoint_client.cc ('k') | mojo/public/js/threading.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698