| Index: cc/output/forced_redraw_swap_promise.h
|
| diff --git a/cc/output/forced_redraw_swap_promise.h b/cc/output/forced_redraw_swap_promise.h
|
| new file mode 100644
|
| index 0000000000000000000000000000000000000000..4fa2ff6dfc26e4dbf5126cc736f5578415b6a4ab
|
| --- /dev/null
|
| +++ b/cc/output/forced_redraw_swap_promise.h
|
| @@ -0,0 +1,34 @@
|
| +// Copyright 2016 The Chromium Authors. All rights reserved.
|
| +// Use of this source code is governed by a BSD-style license that can be
|
| +// found in the LICENSE file.
|
| +
|
| +#ifndef CC_OUTPUT_FORCED_REDRAW_SWAP_PROMISE_H_
|
| +#define CC_OUTPUT_FORCED_REDRAW_SWAP_PROMISE_H_
|
| +
|
| +#include "base/compiler_specific.h"
|
| +#include "cc/output/swap_promise.h"
|
| +#include "ui/events/latency_info.h"
|
| +
|
| +namespace cc {
|
| +
|
| +// This class represents promise which is robust to (will not be broken by)
|
| +// |DidNotSwapReason::SWAP_FAILS| events.
|
| +class CC_EXPORT ForcedRedrawSwapPromise : public SwapPromise {
|
| + public:
|
| + explicit ForcedRedrawSwapPromise(const ui::LatencyInfo& latency_info);
|
| + ~ForcedRedrawSwapPromise() override;
|
| +
|
| + void DidActivate() override {}
|
| + void DidSwap(CompositorFrameMetadata* metadata) override;
|
| + bool DidNotSwap(DidNotSwapReason reason) override;
|
| + void OnCommit() override {}
|
| +
|
| + int64_t TraceId() const override;
|
| +
|
| + private:
|
| + ui::LatencyInfo latency_;
|
| +};
|
| +
|
| +} // namespace cc
|
| +
|
| +#endif // CC_OUTPUT_FORCED_REDRAW_SWAP_PROMISE_H_
|
|
|