OLD | NEW |
1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 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 PPAPI_TESTS_TEST_FLASH_FULLSCREEN_FOR_BROWSER_UI_H_ | 5 #ifndef PPAPI_TESTS_TEST_FLASH_FULLSCREEN_FOR_BROWSER_UI_H_ |
6 #define PPAPI_TESTS_TEST_FLASH_FULLSCREEN_FOR_BROWSER_UI_H_ | 6 #define PPAPI_TESTS_TEST_FLASH_FULLSCREEN_FOR_BROWSER_UI_H_ |
7 | 7 |
8 #include <string> | 8 #include <string> |
9 | 9 |
10 #include "ppapi/cpp/compositor.h" | 10 #include "ppapi/cpp/compositor.h" |
(...skipping 11 matching lines...) Expand all Loading... |
22 // chrome/browser/ui/exclusive_access/ | 22 // chrome/browser/ui/exclusive_access/ |
23 // flash_fullscreen_interactive_browsertest.cc. | 23 // flash_fullscreen_interactive_browsertest.cc. |
24 // | 24 // |
25 // At start, this simulated Flash plugin will enter fullscreen and paint a green | 25 // At start, this simulated Flash plugin will enter fullscreen and paint a green |
26 // color fill. From there, it will respond to mouse clicks or key presses by | 26 // color fill. From there, it will respond to mouse clicks or key presses by |
27 // toggling its fill color between red and blue. The browser test reads these | 27 // toggling its fill color between red and blue. The browser test reads these |
28 // color changes to detect the desired behavior. | 28 // color changes to detect the desired behavior. |
29 class TestFlashFullscreenForBrowserUI : public TestCase { | 29 class TestFlashFullscreenForBrowserUI : public TestCase { |
30 public: | 30 public: |
31 explicit TestFlashFullscreenForBrowserUI(TestingInstance* instance); | 31 explicit TestFlashFullscreenForBrowserUI(TestingInstance* instance); |
32 virtual ~TestFlashFullscreenForBrowserUI(); | 32 ~TestFlashFullscreenForBrowserUI() override; |
33 | 33 |
34 // TestCase implementation. | 34 // TestCase implementation. |
35 virtual bool Init() override; | 35 bool Init() override; |
36 virtual void RunTests(const std::string& filter) override; | 36 void RunTests(const std::string& filter) override; |
37 virtual void DidChangeView(const pp::View& view) override; | 37 void DidChangeView(const pp::View& view) override; |
38 virtual bool HandleInputEvent(const pp::InputEvent& event) override; | 38 bool HandleInputEvent(const pp::InputEvent& event) override; |
39 | 39 |
40 private: | 40 private: |
41 std::string TestEnterFullscreen(); | 41 std::string TestEnterFullscreen(); |
42 void Paint(int32_t last_compositor_result); | 42 void Paint(int32_t last_compositor_result); |
43 | 43 |
44 pp::FlashFullscreen screen_mode_; | 44 pp::FlashFullscreen screen_mode_; |
45 NestedEvent view_change_event_; | 45 NestedEvent view_change_event_; |
46 | 46 |
47 pp::Compositor compositor_; | 47 pp::Compositor compositor_; |
48 pp::Size layer_size_; | 48 pp::Size layer_size_; |
49 pp::CompositorLayer color_layer_; | 49 pp::CompositorLayer color_layer_; |
50 | 50 |
51 int num_trigger_events_; | 51 int num_trigger_events_; |
52 | 52 |
53 pp::CompletionCallbackFactory<TestFlashFullscreenForBrowserUI> | 53 pp::CompletionCallbackFactory<TestFlashFullscreenForBrowserUI> |
54 callback_factory_; | 54 callback_factory_; |
55 }; | 55 }; |
56 | 56 |
57 #endif // PPAPI_TESTS_TEST_FLASH_FULLSCREEN_FOR_BROWSER_UI_H_ | 57 #endif // PPAPI_TESTS_TEST_FLASH_FULLSCREEN_FOR_BROWSER_UI_H_ |
OLD | NEW |