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

Side by Side Diff: tools/viewer/sk_app/Window.cpp

Issue 2015213002: Revert of Add OpenGL support to Linux viewer (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: Created 4 years, 6 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
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 #include "Window.h" 8 #include "Window.h"
9 9
10 #include "SkSurface.h" 10 #include "SkSurface.h"
(...skipping 65 matching lines...) Expand 10 before | Expand all | Expand 10 after
76 if (backbuffer) { 76 if (backbuffer) {
77 // draw into the canvas of this surface 77 // draw into the canvas of this surface
78 SkCanvas* canvas = backbuffer->getCanvas(); 78 SkCanvas* canvas = backbuffer->getCanvas();
79 79
80 fPaintFunc(canvas, fPaintUserData); 80 fPaintFunc(canvas, fPaintUserData);
81 81
82 canvas->flush(); 82 canvas->flush();
83 83
84 fWindowContext->swapBuffers(); 84 fWindowContext->swapBuffers();
85 } else { 85 } else {
86 printf("no backbuffer!?\n");
87 // try recreating testcontext 86 // try recreating testcontext
88 } 87 }
89 } 88 }
90 89
91 void Window::onResize(uint32_t w, uint32_t h) { 90 void Window::onResize(uint32_t w, uint32_t h) {
92 fWidth = w; 91 fWidth = w;
93 fHeight = h; 92 fHeight = h;
94 fWindowContext->resize(w, h); 93 fWindowContext->resize(w, h);
95 } 94 }
96 95
(...skipping 10 matching lines...) Expand all
107 fIsContentInvalidated = true; 106 fIsContentInvalidated = true;
108 onInval(); 107 onInval();
109 } 108 }
110 } 109 }
111 110
112 void Window::markInvalProcessed() { 111 void Window::markInvalProcessed() {
113 fIsContentInvalidated = false; 112 fIsContentInvalidated = false;
114 } 113 }
115 114
116 } // namespace sk_app 115 } // namespace sk_app
OLDNEW
« no previous file with comments | « tools/viewer/sk_app/VulkanWindowContext.cpp ('k') | tools/viewer/sk_app/unix/VulkanWindowContext_unix.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698