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

Unified Diff: examples/trace_me/trace_me_app.cc

Issue 1357503002: Add tracing event for first connection. (Closed) Base URL: https://github.com/domokit/mojo.git@master
Patch Set: Created 5 years, 3 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/dart/traced_application/lib/main.dart ('k') | mojo/tools/data/benchmarks » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: examples/trace_me/trace_me_app.cc
diff --git a/examples/trace_me/trace_me_app.cc b/examples/trace_me/trace_me_app.cc
index f6f43df8bcd0991ddc7f8f32e648635bbb8f7be3..841566206a435d03931901e3d445b6c64b6e6228 100644
--- a/examples/trace_me/trace_me_app.cc
+++ b/examples/trace_me/trace_me_app.cc
@@ -58,7 +58,15 @@ class TraceMeApp : public mojo::ApplicationDelegate {
TRACE_EVENT0("trace_me", "initialized");
- base::MessageLoop::current()->PostTask(FROM_HERE, base::Bind(&DoWork));
+ base::MessageLoop::current()->PostDelayedTask(
+ FROM_HERE, base::Bind(&DoWork), kDoWorkDelay);
+ }
+
+ // mojo:ApplicationDelegate:
+ bool ConfigureIncomingConnection(
+ mojo::ApplicationConnection* connection) override {
+ TRACE_EVENT0("trace_me", "connected");
+ return true;
}
private:
« no previous file with comments | « examples/dart/traced_application/lib/main.dart ('k') | mojo/tools/data/benchmarks » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698