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

Side by Side Diff: ui/gl/init/gl_factory_mac.cc

Issue 2702403009: Make surface GetFormat pure virtual, add missing overrides. (Closed)
Patch Set: Fix class name for Windows Created 3 years, 9 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 | « ui/gl/gl_surface_wgl.cc ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2016 The Chromium Authors. All rights reserved. 1 // Copyright 2016 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 #include "ui/gl/init/gl_factory.h" 5 #include "ui/gl/init/gl_factory.h"
6 6
7 #include "base/logging.h" 7 #include "base/logging.h"
8 #include "base/macros.h" 8 #include "base/macros.h"
9 #include "base/trace_event/trace_event.h" 9 #include "base/trace_event/trace_event.h"
10 #include "ui/gl/gl_bindings.h" 10 #include "ui/gl/gl_bindings.h"
(...skipping 25 matching lines...) Expand all
36 void Destroy() override {} 36 void Destroy() override {}
37 bool IsOffscreen() override { return true; } 37 bool IsOffscreen() override { return true; }
38 gfx::SwapResult SwapBuffers() override { 38 gfx::SwapResult SwapBuffers() override {
39 NOTREACHED() << "Cannot call SwapBuffers on a NoOpGLSurface."; 39 NOTREACHED() << "Cannot call SwapBuffers on a NoOpGLSurface.";
40 return gfx::SwapResult::SWAP_FAILED; 40 return gfx::SwapResult::SWAP_FAILED;
41 } 41 }
42 gfx::Size GetSize() override { return size_; } 42 gfx::Size GetSize() override { return size_; }
43 void* GetHandle() override { return nullptr; } 43 void* GetHandle() override { return nullptr; }
44 void* GetDisplay() override { return nullptr; } 44 void* GetDisplay() override { return nullptr; }
45 bool IsSurfaceless() const override { return true; } 45 bool IsSurfaceless() const override { return true; }
46 GLSurfaceFormat GetFormat() override { return GLSurfaceFormat(); }
46 47
47 protected: 48 protected:
48 ~NoOpGLSurface() override {} 49 ~NoOpGLSurface() override {}
49 50
50 private: 51 private:
51 gfx::Size size_; 52 gfx::Size size_;
52 53
53 DISALLOW_COPY_AND_ASSIGN(NoOpGLSurface); 54 DISALLOW_COPY_AND_ASSIGN(NoOpGLSurface);
54 }; 55 };
55 56
(...skipping 81 matching lines...) Expand 10 before | Expand all | Expand 10 after
137 case kGLImplementationStubGL: 138 case kGLImplementationStubGL:
138 return new GLSurfaceStub; 139 return new GLSurfaceStub;
139 default: 140 default:
140 NOTREACHED(); 141 NOTREACHED();
141 return nullptr; 142 return nullptr;
142 } 143 }
143 } 144 }
144 145
145 } // namespace init 146 } // namespace init
146 } // namespace gl 147 } // namespace gl
OLDNEW
« no previous file with comments | « ui/gl/gl_surface_wgl.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698