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

Unified Diff: blimp/client/app/android/blimp_view.cc

Issue 1962393004: Added a debug info UI for Blimp (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Added empty implementation for linux client 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « blimp/client/app/android/blimp_view.h ('k') | blimp/client/app/android/java/res/layout/blimp_main.xml » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: blimp/client/app/android/blimp_view.cc
diff --git a/blimp/client/app/android/blimp_view.cc b/blimp/client/app/android/blimp_view.cc
index 37db8ed0de5ae31539dfedb12b0bf5f8ba7cbc4f..50bde2bd982fb621590725c77d8a3067abe87500 100644
--- a/blimp/client/app/android/blimp_view.cc
+++ b/blimp/client/app/android/blimp_view.cc
@@ -32,7 +32,8 @@ static jlong Init(JNIEnv* env,
return reinterpret_cast<intptr_t>(new BlimpView(
env, jobj, gfx::Size(real_width, real_height), gfx::Size(width, height),
- dp_to_px, client_session->GetRenderWidgetFeature()));
+ dp_to_px, client_session->GetRenderWidgetFeature(),
+ client_session->GetBlimpConnectionStatistics()));
}
// static
@@ -45,7 +46,8 @@ BlimpView::BlimpView(JNIEnv* env,
const gfx::Size& real_size,
const gfx::Size& size,
float dp_to_px,
- RenderWidgetFeature* render_widget_feature)
+ RenderWidgetFeature* render_widget_feature,
+ BlimpConnectionStatistics* blimp_connection_statistics)
: device_scale_factor_(dp_to_px),
compositor_manager_(
BlimpCompositorManagerAndroid::Create(real_size,
@@ -53,7 +55,8 @@ BlimpView::BlimpView(JNIEnv* env,
render_widget_feature,
this)),
current_surface_format_(0),
- window_(gfx::kNullAcceleratedWidget) {
+ window_(gfx::kNullAcceleratedWidget),
+ blimp_connection_statistics_(blimp_connection_statistics) {
java_obj_.Reset(env, jobj);
}
@@ -180,5 +183,10 @@ void BlimpView::OnSwapBuffersCompleted() {
Java_BlimpView_onSwapBuffersCompleted(env, java_obj_.obj());
}
+void BlimpView::DidCommitAndDrawFrame() {
+ DCHECK(blimp_connection_statistics_);
+ blimp_connection_statistics_->Add(BlimpConnectionStatistics::COMMIT, 1);
+}
+
} // namespace client
} // namespace blimp
« no previous file with comments | « blimp/client/app/android/blimp_view.h ('k') | blimp/client/app/android/java/res/layout/blimp_main.xml » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698