1234567891011121314151617181920212223242526272829303132333435363738394041424344 |
- // Copyright 2018 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 ASH_SYSTEM_POWER_POWER_EVENT_OBSERVER_TEST_API_H_
- #define ASH_SYSTEM_POWER_POWER_EVENT_OBSERVER_TEST_API_H_
- namespace ui {
- class Compositor;
- }
- namespace ash {
- class PowerEventObserver;
- class PowerEventObserverTestApi {
- public:
- explicit PowerEventObserverTestApi(PowerEventObserver* power_event_observer);
- PowerEventObserverTestApi(const PowerEventObserverTestApi&) = delete;
- PowerEventObserverTestApi& operator=(const PowerEventObserverTestApi&) =
- delete;
- ~PowerEventObserverTestApi();
- void CompositingDidCommit(ui::Compositor* compositor);
- void CompositingStarted(ui::Compositor* compositor);
- void CompositingEnded(ui::Compositor* compositor);
- // Same as calling CompositingDidCommit, CompositingStarted and
- // CompositingEnded in sequence.
- void CompositeFrame(ui::Compositor* compositor);
- bool SimulateCompositorsReadyForSuspend();
- bool TrackingLockOnSuspendUsage() const;
- private:
- PowerEventObserver* power_event_observer_;
- };
- } // namespace ash
- #endif // ASH_SYSTEM_POWER_POWER_EVENT_OBSERVER_TEST_API_H_
|