OLD | NEW |
1 /* | 1 /* |
2 * Copyright 2016 Google Inc. | 2 * Copyright 2016 Google Inc. |
3 * | 3 * |
4 * Use of this source code is governed by a BSD-style license that can be | 4 * Use of this source code is governed by a BSD-style license that can be |
5 * found in the LICENSE file. | 5 * found in the LICENSE file. |
6 */ | 6 */ |
7 | 7 |
8 #include "Window.h" | 8 #include "Window.h" |
9 | 9 |
10 #include "SkSurface.h" | 10 #include "SkSurface.h" |
11 #include "SkCanvas.h" | 11 #include "SkCanvas.h" |
12 #include "VulkanTestContext.h" | 12 #include "VulkanTestContext.h" |
13 | 13 |
| 14 namespace sk_app { |
| 15 |
14 static bool default_char_func(SkUnichar c, uint32_t modifiers, void* userData) { | 16 static bool default_char_func(SkUnichar c, uint32_t modifiers, void* userData) { |
15 return false; | 17 return false; |
16 } | 18 } |
17 | 19 |
18 static bool default_key_func(Window::Key key, Window::InputState state, uint32_t
modifiers, | 20 static bool default_key_func(Window::Key key, Window::InputState state, uint32_t
modifiers, |
19 void* userData) { | 21 void* userData) { |
20 return false; | 22 return false; |
21 } | 23 } |
22 | 24 |
23 static bool default_mouse_func(int x, int y, Window::InputState state, uint32_t
modifiers, | 25 static bool default_mouse_func(int x, int y, Window::InputState state, uint32_t
modifiers, |
(...skipping 41 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
65 // try recreating testcontext | 67 // try recreating testcontext |
66 } | 68 } |
67 | 69 |
68 } | 70 } |
69 | 71 |
70 void Window::onResize(uint32_t w, uint32_t h) { | 72 void Window::onResize(uint32_t w, uint32_t h) { |
71 fWidth = w; | 73 fWidth = w; |
72 fHeight = h; | 74 fHeight = h; |
73 fTestContext->resize(w, h); | 75 fTestContext->resize(w, h); |
74 } | 76 } |
| 77 |
| 78 } // namespace sk_app |
OLD | NEW |