| OLD | NEW |
| 1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #ifndef PAPPI_TESTS_TEST_FULLSCREEN_H_ | 5 #ifndef PAPPI_TESTS_TEST_FULLSCREEN_H_ |
| 6 #define PAPPI_TESTS_TEST_FULLSCREEN_H_ | 6 #define PAPPI_TESTS_TEST_FULLSCREEN_H_ |
| 7 | 7 |
| 8 #include <string> | 8 #include <string> |
| 9 | 9 |
| 10 #include "ppapi/cpp/fullscreen.h" | 10 #include "ppapi/cpp/fullscreen.h" |
| (...skipping 14 matching lines...) Expand all Loading... |
| 25 // TestCase implementation. | 25 // TestCase implementation. |
| 26 virtual bool Init(); | 26 virtual bool Init(); |
| 27 virtual void RunTests(const std::string& filter); | 27 virtual void RunTests(const std::string& filter); |
| 28 virtual bool HandleInputEvent(const pp::InputEvent& event); | 28 virtual bool HandleInputEvent(const pp::InputEvent& event); |
| 29 virtual void DidChangeView(const pp::Rect& position, const pp::Rect& clip); | 29 virtual void DidChangeView(const pp::Rect& position, const pp::Rect& clip); |
| 30 | 30 |
| 31 private: | 31 private: |
| 32 std::string TestGetScreenSize(); | 32 std::string TestGetScreenSize(); |
| 33 std::string TestNormalToFullscreenToNormal(); | 33 std::string TestNormalToFullscreenToNormal(); |
| 34 | 34 |
| 35 void SimulateUserGesture(); |
| 36 |
| 35 void FailFullscreenTest(const std::string& error); | 37 void FailFullscreenTest(const std::string& error); |
| 36 | 38 |
| 37 bool GotError(); | 39 bool GotError(); |
| 38 std::string Error(); | 40 std::string Error(); |
| 39 | 41 |
| 40 std::string error_; | 42 std::string error_; |
| 41 | 43 |
| 42 pp::Fullscreen screen_mode_; | 44 pp::Fullscreen screen_mode_; |
| 43 pp::Size screen_size_; | 45 pp::Size screen_size_; |
| 44 pp::Rect normal_position_; | 46 pp::Rect normal_position_; |
| 45 | 47 |
| 46 bool fullscreen_pending_; | 48 bool fullscreen_pending_; |
| 47 bool normal_pending_; | 49 bool normal_pending_; |
| 48 bool saw_first_fullscreen_didchangeview; | 50 bool saw_first_fullscreen_didchangeview; |
| 49 pp::Graphics2D graphics2d_fullscreen_; | 51 pp::Graphics2D graphics2d_fullscreen_; |
| 50 pp::Graphics2D graphics2d_normal_; | 52 pp::Graphics2D graphics2d_normal_; |
| 51 TestCompletionCallback set_fullscreen_true_callback_; | 53 TestCompletionCallback set_fullscreen_true_callback_; |
| 52 TestCompletionCallback fullscreen_callback_; | 54 TestCompletionCallback fullscreen_callback_; |
| 53 TestCompletionCallback normal_callback_; | 55 TestCompletionCallback normal_callback_; |
| 54 }; | 56 }; |
| 55 | 57 |
| 56 #endif // PAPPI_TESTS_TEST_FULLSCREEN_H_ | 58 #endif // PAPPI_TESTS_TEST_FULLSCREEN_H_ |
| OLD | NEW |