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

Unified Diff: examples/audio_play_test/play_wav.cc

Issue 1915403002: ApplicationImpl::ConnectToServiceDeprecated() -> mojo::ConnectToService() conversion, part 2. (Closed) Base URL: https://github.com/domokit/mojo.git@master
Patch Set: doh Created 4 years, 8 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « examples/audio_play_test/play_tone.cc ('k') | services/asset_bundle/asset_bundle_apptest.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: examples/audio_play_test/play_wav.cc
diff --git a/examples/audio_play_test/play_wav.cc b/examples/audio_play_test/play_wav.cc
index 581e48268751fc1aa12b33e3fa49f83d472a3028..d5dc2e16837ee105d4fa861f6bff53265b1560d1 100644
--- a/examples/audio_play_test/play_wav.cc
+++ b/examples/audio_play_test/play_wav.cc
@@ -8,6 +8,7 @@
#include "mojo/public/cpp/application/application_delegate.h"
#include "mojo/public/cpp/application/application_impl.h"
#include "mojo/public/cpp/application/application_runner.h"
+#include "mojo/public/cpp/application/connect.h"
#include "mojo/public/cpp/system/data_pipe.h"
#include "mojo/public/cpp/system/wait.h"
#include "mojo/public/cpp/utility/run_loop.h"
@@ -157,12 +158,13 @@ const std::set<uint16_t> PlayWAVApp::VALID_BITS_PER_SAMPLES({
});
void PlayWAVApp::Initialize(ApplicationImpl* app) {
- app->ConnectToServiceDeprecated("mojo:audio_server", &audio_server_);
+ ConnectToService(app->shell(), "mojo:audio_server", GetProxy(&audio_server_));
audio_server_.set_connection_error_handler([this]() {
OnConnectionError("audio_server");
});
- app->ConnectToServiceDeprecated("mojo:network_service", &network_service_);
+ ConnectToService(app->shell(), "mojo:network_service",
+ GetProxy(&network_service_));
audio_server_.set_connection_error_handler([this]() {
OnConnectionError("network_service");
});
« no previous file with comments | « examples/audio_play_test/play_tone.cc ('k') | services/asset_bundle/asset_bundle_apptest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698