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

Side by Side Diff: ui/gfx/gl/gl_surface_nsview.mm

Issue 8687016: GLContextNSView should not assume concrete type GLSurface is GLSurfaceNSView (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 9 years 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 | Annotate | Revision Log
« no previous file with comments | « ui/gfx/gl/gl_surface_nsview.h ('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 (c) 2011 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 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/gfx/gl/gl_surface_nsview.h" 5 #include "ui/gfx/gl/gl_surface_nsview.h"
6 6
7 #import <AppKit/NSOpenGL.h> 7 #import <AppKit/NSOpenGL.h>
8 #import <AppKit/NSView.h> 8 #import <AppKit/NSView.h>
9 9
10 #include "ui/gfx/gl/gl_context_nsview.h" 10 #include "ui/gfx/gl/gl_context_nsview.h"
(...skipping 21 matching lines...) Expand all
32 } 32 }
33 33
34 gfx::Size GLSurfaceNSView::GetSize() { 34 gfx::Size GLSurfaceNSView::GetSize() {
35 return gfx::Size(NSSizeToCGSize([view_ bounds].size)); 35 return gfx::Size(NSSizeToCGSize([view_ bounds].size));
36 } 36 }
37 37
38 void* GLSurfaceNSView::GetHandle() { 38 void* GLSurfaceNSView::GetHandle() {
39 return view_; 39 return view_;
40 } 40 }
41 41
42 void GLSurfaceNSView::SetGLContext(GLContextNSView* context) { 42 bool GLSurfaceNSView::OnMakeCurrent(GLContext* context) {
43 context_ = context; 43 context_ = static_cast<GLContextNSView *>(context);
Ken Russell (switch to Gerrit) 2011/11/30 00:39:01 Given the other cleanup in this CL, the downcast i
44 return true;
44 } 45 }
45 46
46 } // namespace gfx 47 } // namespace gfx
OLDNEW
« no previous file with comments | « ui/gfx/gl/gl_surface_nsview.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698