Commit a803592b authored by dhollowa@chromium.org's avatar dhollowa@chromium.org

Chromium style clang fixes for OVERRIDE in compositor_unittests

Fixes clang plugin complaint about missing override:
./ui/gfx/compositor/compositor_cc.h:35:11: error: [chromium-style] Overriding method must be marked with OVERRIDE.
  virtual void* GetDisplay();
          ^
Also, adds |SetCurrent| call to properly track context in |GLContextNSView::MakeCurrent|.

BUG=104390
TEST=Compiles on Mac/clang.  compositor_unittests pass.
R=piman@chromium.org, kbr@chromium.org


Review URL: http://codereview.chromium.org/8748018

git-svn-id: svn://svn.chromium.org/chrome/trunk/src@112291 0039d316-1c4b-4281-b951-d872f2087c98
parent 2167cd62
......@@ -32,7 +32,7 @@ class COMPOSITOR_EXPORT SharedResourcesCC
virtual gfx::ScopedMakeCurrent* GetScopedMakeCurrent() OVERRIDE;
virtual void* GetDisplay();
virtual void* GetDisplay() OVERRIDE;
gfx::GLShareGroup* GetShareGroup();
......
......@@ -17,14 +17,15 @@
#include "third_party/WebKit/Source/WebKit/chromium/public/WebSize.h"
#include "ui/base/animation/animation.h"
#include "ui/gfx/canvas_skia.h"
#if defined(USE_WEBKIT_COMPOSITOR)
#include "ui/gfx/compositor/compositor_cc.h"
#endif
#include "ui/gfx/compositor/compositor_switches.h"
#include "ui/gfx/compositor/layer_animator.h"
#include "ui/gfx/interpolated_transform.h"
#include "ui/gfx/point3.h"
#if defined(USE_WEBKIT_COMPOSITOR)
#include "ui/gfx/compositor/compositor_cc.h"
#endif
namespace {
const float EPSILON = 1e-3f;
......
......@@ -62,6 +62,8 @@ bool GLContextNSView::MakeCurrent(GLSurface* surface) {
[context_ setView:view];
[context_ makeCurrentContext];
SetCurrent(this, surface);
if (!surface->OnMakeCurrent(this)) {
LOG(ERROR) << "Unable to make gl context current.";
return false;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment