Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(3)

Side by Side Diff: tools/viewer/sk_app/win/Window_win.h

Issue 2184163003: Enable backend switching for Windows Viewer (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: Delete extra glMakeCurrent Created 4 years, 4 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « tools/viewer/sk_app/win/GLWindowContext_win.cpp ('k') | tools/viewer/sk_app/win/Window_win.cpp » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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 #ifndef Window_win_DEFINED 8 #ifndef Window_win_DEFINED
9 #define Window_win_DEFINED 9 #define Window_win_DEFINED
10 10
11 #include <windows.h> 11 #include <windows.h>
12 #include "../Window.h" 12 #include "../Window.h"
13 13
14 namespace sk_app { 14 namespace sk_app {
15 15
16 class Window_win : public Window { 16 class Window_win : public Window {
17 public: 17 public:
18 Window_win() : Window() {} 18 Window_win() : Window() {}
19 ~Window_win() override {} 19 ~Window_win() override { DestroyWindow(fHWnd); }
20 20
21 bool init(HINSTANCE instance); 21 bool init(HINSTANCE instance);
22 22
23 void setTitle(const char*) override; 23 void setTitle(const char*) override;
24 void show() override; 24 void show() override;
25 25
26 bool attach(BackendType attachType, const DisplayParams& params) override; 26 bool attach(BackendType attachType, const DisplayParams& params) override;
27 27
28 void onInval() override; 28 void onInval() override;
29 29
30 private: 30 private:
31 HINSTANCE fHInstance; 31 HINSTANCE fHInstance;
32 HWND fHWnd; 32 HWND fHWnd;
33 }; 33 };
34 34
35 } // namespace sk_app 35 } // namespace sk_app
36 36
37 #endif 37 #endif
OLDNEW
« no previous file with comments | « tools/viewer/sk_app/win/GLWindowContext_win.cpp ('k') | tools/viewer/sk_app/win/Window_win.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698