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

Side by Side Diff: ipc/mojo/ipc_channel_mojo.cc

Issue 1991323002: Send input event IPCs directly from the UI thread (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 7 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 | « ipc/ipc_sync_message_filter.cc ('k') | no next file » | 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 "ipc/mojo/ipc_channel_mojo.h" 5 #include "ipc/mojo/ipc_channel_mojo.h"
6 6
7 #include <stddef.h> 7 #include <stddef.h>
8 #include <stdint.h> 8 #include <stdint.h>
9 9
10 #include <memory> 10 #include <memory>
(...skipping 333 matching lines...) Expand 10 before | Expand all | Expand 10 after
344 344
345 if (!sent) { 345 if (!sent) {
346 OnPipeError(); 346 OnPipeError();
347 return false; 347 return false;
348 } 348 }
349 349
350 return true; 350 return true;
351 } 351 }
352 352
353 bool ChannelMojo::IsSendThreadSafe() const { 353 bool ChannelMojo::IsSendThreadSafe() const {
354 return false; 354 return true;
355 } 355 }
356 356
357 base::ProcessId ChannelMojo::GetPeerPID() const { 357 base::ProcessId ChannelMojo::GetPeerPID() const {
358 base::AutoLock lock(lock_); 358 base::AutoLock lock(lock_);
359 if (!message_reader_) 359 if (!message_reader_)
360 return base::kNullProcessId; 360 return base::kNullProcessId;
361 361
362 return message_reader_->GetPeerPid(); 362 return message_reader_->GetPeerPid();
363 } 363 }
364 364
(...skipping 71 matching lines...) Expand 10 before | Expand all | Expand 10 after
436 DCHECK(ok); 436 DCHECK(ok);
437 if (!ok) { 437 if (!ok) {
438 LOG(ERROR) << "Failed to add new Mojo handle."; 438 LOG(ERROR) << "Failed to add new Mojo handle.";
439 return MOJO_RESULT_UNKNOWN; 439 return MOJO_RESULT_UNKNOWN;
440 } 440 }
441 } 441 }
442 return MOJO_RESULT_OK; 442 return MOJO_RESULT_OK;
443 } 443 }
444 444
445 } // namespace IPC 445 } // namespace IPC
OLDNEW
« no previous file with comments | « ipc/ipc_sync_message_filter.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698