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

Side by Side Diff: cc/output/forced_redraw_swap_promise.h

Issue 2185823005: Make RenderViewImpl::OnForceRedraw more robust (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Fix comments and add tests Created 4 years, 4 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
OLDNEW
(Empty)
1 // Copyright 2016 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 CC_OUTPUT_FORCED_REDRAW_SWAP_PROMISE_H_
6 #define CC_OUTPUT_FORCED_REDRAW_SWAP_PROMISE_H_
7
8 #include "base/compiler_specific.h"
9 #include "cc/output/swap_promise.h"
10 #include "ui/events/latency_info.h"
11
12 namespace cc {
13
14 // This class represents promise which is robust to (will not be broken by)
15 // |DidNotSwapReason::SWAP_FAILS| events.
16 class CC_EXPORT ForcedRedrawSwapPromise : public SwapPromise {
danakj 2016/08/10 01:04:15 nit: i prefer AlwaysDrawSwapPromise. "Forced draws
svartmetal 2016/08/10 17:38:21 Fixed.
17 public:
18 explicit ForcedRedrawSwapPromise(const ui::LatencyInfo& latency_info);
19 ~ForcedRedrawSwapPromise() override;
20
21 void DidActivate() override {}
22 void DidSwap(CompositorFrameMetadata* metadata) override;
23 DidNotSwapAction DidNotSwap(DidNotSwapReason reason) override;
24 void OnCommit() override {}
25
26 int64_t TraceId() const override;
27
28 private:
29 ui::LatencyInfo latency_;
30 };
31
32 } // namespace cc
33
34 #endif // CC_OUTPUT_FORCED_REDRAW_SWAP_PROMISE_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698