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

Unified Diff: content/renderer/render_widget.h

Issue 83483007: Expose synthetic delays through the GPU benchmarking extension (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 7 years, 1 month 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
Index: content/renderer/render_widget.h
diff --git a/content/renderer/render_widget.h b/content/renderer/render_widget.h
index 9a260470721c121759982b09b36c78f14b340c69..6b5745117fa5352e77b5e50b6502209676df6e95 100644
--- a/content/renderer/render_widget.h
+++ b/content/renderer/render_widget.h
@@ -10,6 +10,7 @@
#include "base/basictypes.h"
#include "base/compiler_specific.h"
+#include "base/debug/trace_event_synthetic_delay.h"
#include "base/memory/ref_counted.h"
#include "base/memory/scoped_ptr.h"
#include "base/time/time.h"
@@ -198,6 +199,15 @@ class CONTENT_EXPORT RenderWidget
int anchor_y,
const SyntheticGestureCompletionCallback& callback);
+ // Configure a synthetic delay across all processes. Once all processes have
+ // acknowledged the new delay configuration, |callback| will be called back.
+ typedef base::Callback<void()> SyntheticDelayConfigurationCallback;
+ void ConfigureSyntheticDelay(
+ const std::string& name,
+ base::TimeDelta target_duration,
+ base::debug::TraceEventSyntheticDelay::Mode mode,
+ const SyntheticDelayConfigurationCallback& callback);
+
// Close the underlying WebWidget.
virtual void Close();
@@ -358,6 +368,7 @@ class CONTENT_EXPORT RenderWidget
const gfx::Size& desired_size);
void OnRepaint(gfx::Size size_to_paint);
void OnSyntheticGestureCompleted();
+ void OnConfigureSyntheticDelayAck();
void OnSetTextDirection(blink::WebTextDirection direction);
void OnGetFPS();
void OnUpdateScreenRects(const gfx::Rect& view_screen_rect,
@@ -760,6 +771,8 @@ class CONTENT_EXPORT RenderWidget
// (e.g. BeginSmoothScroll).
SyntheticGestureCompletionCallback pending_synthetic_gesture_;
+ SyntheticDelayConfigurationCallback pending_delay_configuration_;
+
// Specified whether the compositor will run in its own thread.
bool is_threaded_compositing_enabled_;

Powered by Google App Engine
This is Rietveld 408576698