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

Side by Side Diff: dbus/bus.cc

Issue 8175009: Eliminate a timed wait from ExportedObject::HandleMessage(). (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 9 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 | Annotate | Revision Log
« no previous file with comments | « dbus/bus.h ('k') | dbus/exported_object.h » ('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 (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 // TODO(satorux): 5 // TODO(satorux):
6 // - Handle "disconnected" signal. 6 // - Handle "disconnected" signal.
7 7
8 #include "dbus/bus.h" 8 #include "dbus/bus.h"
9 9
10 #include "base/bind.h" 10 #include "base/bind.h"
(...skipping 372 matching lines...) Expand 10 before | Expand all | Expand 10 after
383 ProcessAllIncomingDataIfAny(); 383 ProcessAllIncomingDataIfAny();
384 384
385 bool success = dbus_connection_set_watch_functions(connection_, 385 bool success = dbus_connection_set_watch_functions(connection_,
386 &Bus::OnAddWatchThunk, 386 &Bus::OnAddWatchThunk,
387 &Bus::OnRemoveWatchThunk, 387 &Bus::OnRemoveWatchThunk,
388 &Bus::OnToggleWatchThunk, 388 &Bus::OnToggleWatchThunk,
389 this, 389 this,
390 NULL); 390 NULL);
391 CHECK(success) << "Unable to allocate memory"; 391 CHECK(success) << "Unable to allocate memory";
392 392
393 // TODO(satorux): Timeout is not yet implemented.
394 success = dbus_connection_set_timeout_functions(connection_, 393 success = dbus_connection_set_timeout_functions(connection_,
395 &Bus::OnAddTimeoutThunk, 394 &Bus::OnAddTimeoutThunk,
396 &Bus::OnRemoveTimeoutThunk, 395 &Bus::OnRemoveTimeoutThunk,
397 &Bus::OnToggleTimeoutThunk, 396 &Bus::OnToggleTimeoutThunk,
398 this, 397 this,
399 NULL); 398 NULL);
400 CHECK(success) << "Unable to allocate memory"; 399 CHECK(success) << "Unable to allocate memory";
401 400
402 dbus_connection_set_dispatch_status_function( 401 dbus_connection_set_dispatch_status_function(
403 connection_, 402 connection_,
(...skipping 336 matching lines...) Expand 10 before | Expand all | Expand 10 after
740 } 739 }
741 740
742 void Bus::OnDispatchStatusChangedThunk(DBusConnection* connection, 741 void Bus::OnDispatchStatusChangedThunk(DBusConnection* connection,
743 DBusDispatchStatus status, 742 DBusDispatchStatus status,
744 void* data) { 743 void* data) {
745 Bus* self = static_cast<Bus*>(data); 744 Bus* self = static_cast<Bus*>(data);
746 return self->OnDispatchStatusChanged(connection, status); 745 return self->OnDispatchStatusChanged(connection, status);
747 } 746 }
748 747
749 } // namespace dbus 748 } // namespace dbus
OLDNEW
« no previous file with comments | « dbus/bus.h ('k') | dbus/exported_object.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698