| 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 ANDROID_WEBVIEW_BROWSER_TEST_FAKE_WINDOW_H_ | 5 #ifndef ANDROID_WEBVIEW_BROWSER_TEST_FAKE_WINDOW_H_ |
| 6 #define ANDROID_WEBVIEW_BROWSER_TEST_FAKE_WINDOW_H_ | 6 #define ANDROID_WEBVIEW_BROWSER_TEST_FAKE_WINDOW_H_ |
| 7 | 7 |
| 8 #include <map> | 8 #include <map> |
| 9 | 9 |
| 10 #include "android_webview/public/browser/draw_gl.h" | 10 #include "android_webview/public/browser/draw_gl.h" |
| (...skipping 35 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 46 public: | 46 public: |
| 47 FakeWindow(BrowserViewRenderer* view, | 47 FakeWindow(BrowserViewRenderer* view, |
| 48 RenderThreadManager* functor, | 48 RenderThreadManager* functor, |
| 49 WindowHooks* hooks, | 49 WindowHooks* hooks, |
| 50 gfx::Rect location); | 50 gfx::Rect location); |
| 51 ~FakeWindow(); | 51 ~FakeWindow(); |
| 52 | 52 |
| 53 void Detach(); | 53 void Detach(); |
| 54 | 54 |
| 55 // BrowserViewRendererClient methods. | 55 // BrowserViewRendererClient methods. |
| 56 void RequestDrawGL(bool wait_for_completion); | 56 void RequestInvokeGL(bool wait_for_completion); |
| 57 void PostInvalidate(); | 57 void PostInvalidate(); |
| 58 const gfx::Size& surface_size() { return surface_size_; } | 58 const gfx::Size& surface_size() { return surface_size_; } |
| 59 | 59 |
| 60 private: | 60 private: |
| 61 class ScopedMakeCurrent; | 61 class ScopedMakeCurrent; |
| 62 | 62 |
| 63 void OnDrawHardware(); | 63 void OnDrawHardware(); |
| 64 void CheckCurrentlyOnUIThread(); | 64 void CheckCurrentlyOnUIThread(); |
| 65 void CreateRenderThreadIfNeeded(); | 65 void CreateRenderThreadIfNeeded(); |
| 66 | 66 |
| (...skipping 23 matching lines...) Expand all Loading... |
| 90 bool context_current_; | 90 bool context_current_; |
| 91 | 91 |
| 92 base::WeakPtrFactory<FakeWindow> weak_ptr_factory_; | 92 base::WeakPtrFactory<FakeWindow> weak_ptr_factory_; |
| 93 | 93 |
| 94 DISALLOW_COPY_AND_ASSIGN(FakeWindow); | 94 DISALLOW_COPY_AND_ASSIGN(FakeWindow); |
| 95 }; | 95 }; |
| 96 | 96 |
| 97 } // namespace android_webview | 97 } // namespace android_webview |
| 98 | 98 |
| 99 #endif // ANDROID_WEBVIEW_BROWSER_TEST_FAKE_WINDOW_H_ | 99 #endif // ANDROID_WEBVIEW_BROWSER_TEST_FAKE_WINDOW_H_ |
| OLD | NEW |