Chromium Code Reviews| OLD | NEW |
|---|---|
| (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 SKY_SHELL_UI_ANIMATOR_H_ | |
| 6 #define SKY_SHELL_UI_ANIMATOR_H_ | |
| 7 | |
| 8 #include "base/memory/weak_ptr.h" | |
| 9 #include "sky/shell/ui/engine.h" | |
| 10 | |
| 11 namespace sky { | |
| 12 namespace shell { | |
| 13 | |
| 14 class Animator { | |
| 15 public: | |
| 16 explicit Animator(const Engine::Config& config, Engine* engine); | |
| 17 ~Animator(); | |
| 18 | |
| 19 void RequestFrame(); | |
| 20 | |
| 21 private: | |
| 22 void BeginFrame(); | |
| 23 void OnFrameComplete(); | |
| 24 | |
| 25 Engine::Config config_; | |
| 26 Engine* engine_; | |
| 27 bool frame_requested_; | |
|
eseidel
2015/02/18 20:55:56
You should either rename these to be more clear th
eseidel
2015/02/18 20:55:56
client_requested_frame?
| |
| 28 bool frame_pending_; | |
|
eseidel
2015/02/18 20:55:57
started_frame_creation?
| |
| 29 | |
| 30 base::WeakPtrFactory<Animator> weak_factory_; | |
| 31 | |
| 32 DISALLOW_COPY_AND_ASSIGN(Animator); | |
| 33 }; | |
| 34 | |
| 35 } // namespace shell | |
| 36 } // namespace sky | |
| 37 | |
| 38 #endif // SKY_SHELL_UI_ANIMATOR_H_ | |
| OLD | NEW |