diff options
author | bsalomon <bsalomon@google.com> | 2016-07-26 12:02:50 -0700 |
---|---|---|
committer | Commit bot <commit-bot@chromium.org> | 2016-07-26 12:02:51 -0700 |
commit | d1bdd1fcbd308afb9903f39d231742f5c951cf07 (patch) | |
tree | 786715537d870e3ff8bc3686ea40b83b62c43d6b /tools/viewer/sk_app/mac/Window_mac.cpp | |
parent | 1ed2ae45f59c2864ea05838b4da2750b85472824 (diff) |
Use Windowing system-specific WindowContext factories.
BUG=skia:
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2169543002
Review-Url: https://codereview.chromium.org/2169543002
Diffstat (limited to 'tools/viewer/sk_app/mac/Window_mac.cpp')
-rw-r--r-- | tools/viewer/sk_app/mac/Window_mac.cpp | 15 |
1 files changed, 8 insertions, 7 deletions
diff --git a/tools/viewer/sk_app/mac/Window_mac.cpp b/tools/viewer/sk_app/mac/Window_mac.cpp index fdc6f80bd6..b1ab5c9fe7 100644 --- a/tools/viewer/sk_app/mac/Window_mac.cpp +++ b/tools/viewer/sk_app/mac/Window_mac.cpp @@ -9,7 +9,7 @@ #include "SkUtils.h" #include "Timer.h" -#include "../GLWindowContext.h" +#include "WindowContextFactory_mac.h" #include "Window_mac.h" namespace sk_app { @@ -270,19 +270,20 @@ void Window_mac::show() { bool Window_mac::attach(BackendType attachType, const DisplayParams& params) { this->initWindow(fDisplay, ¶ms); - ContextPlatformData_mac platformData; - platformData.fDisplay = fDisplay; - platformData.fWindow = fWindow; - platformData.fVisualInfo = fVisualInfo; + MacWindowInfo info; +#if 0 + // Init Mac window info here + info.foo = foo; +#endif switch (attachType) { #ifdef SK_VULKAN case kVulkan_BackendType: - fWindowContext = VulkanWindowContext::Create((void*)&platformData, params); + fWindowContext = NewVulkanForMac(info, params); break; #endif case kNativeGL_BackendType: default: - fWindowContext = GLWindowContext::Create((void*)&platformData, params); + fWindowContext = NewGLForMac(info, params); break; } |