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

Side by Side Diff: Source/web/tests/sim/SimCompositor.h

Issue 1316673009: Revert of Add a FOUC painting test. (Closed) Base URL: svn://svn.chromium.org/blink/trunk
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 unified diff | Download patch | Annotate | Revision Log
OLDNEW
(Empty)
1 // Copyright 2015 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
4
5 #ifndef SimCompositor_h
6 #define SimCompositor_h
7
8 namespace blink {
9
10 class SimLayerTreeView;
11 class WebViewImpl;
12
13 // Simulated very basic compositor that's capable of running the BeginMainFrame
14 // processing steps on WebView: beginFrame, layout, paint.
15 //
16 // The painting capabilities are very limited in that only the main layer of
17 // every CompositedDeprecatedPaintLayerMapping will be painted, squashed layers
18 // are not supported and the entirety of every layer is always repainted even if
19 // only part of the layer was invalid.
20 //
21 // Note: This also does not support compositor driven animations.
22 class SimCompositor final {
23 public:
24 explicit SimCompositor(SimLayerTreeView&);
25 ~SimCompositor();
26
27 void setWebViewImpl(WebViewImpl&);
28
29 struct BeginFrameResult {
30 // If any text was drawn in any layer by the painting phase.
31 bool didDrawText = false;
32
33 // Approximate number of draw commands issued by the painting phase of
34 // beginFrame.
35 int drawCount = 0;
36 };
37
38 // Execute the BeginMainFrame processing steps, an approximation of what
39 // cc::ThreadProxy::BeginMainFrame would do.
40 BeginFrameResult beginFrame();
41
42 private:
43 SimLayerTreeView* m_layerTreeView;
44 WebViewImpl* m_webViewImpl;
45 double m_lastFrameTimeMonotonic;
46 };
47
48 } // namespace blink
49
50 #endif
OLDNEW
« no previous file with comments | « Source/web/tests/DocumentLoadingRenderingTest.cpp ('k') | Source/web/tests/sim/SimCompositor.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698