From 0fd02aa33dcbca0296b2fd197cb750e0d11c4925 Mon Sep 17 00:00:00 2001 From: Chris Blume Date: Mon, 19 Nov 2018 14:25:31 -0800 Subject: [PATCH] Use "override" keyword instead of "virtual". "override" provides a compile-time gaurantee that the function is indeed overriding a virtual function. This prevents the potential mistake of creating a new virtual function rather than overriding the original. I happened to notice we could use "override" here instead of "virtual". Might as well tidy up a bit. Test: Built locally BUG=115613038 Change-Id: I7f43f4a466d8ceaa1b863d6a2af054e69618d0c8 --- native/webview/plat_support/draw_gl_functor.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/native/webview/plat_support/draw_gl_functor.cpp b/native/webview/plat_support/draw_gl_functor.cpp index 7cb49da483dea..e3e52b1ea1f1a 100644 --- a/native/webview/plat_support/draw_gl_functor.cpp +++ b/native/webview/plat_support/draw_gl_functor.cpp @@ -42,10 +42,10 @@ AwDrawGLFunction* g_aw_drawgl_function = NULL; class DrawGLFunctor : public Functor { public: explicit DrawGLFunctor(jlong view_context) : view_context_(view_context) {} - virtual ~DrawGLFunctor() {} + ~DrawGLFunctor() override {} // Functor - virtual status_t operator ()(int what, void* data) { + status_t operator ()(int what, void* data) override { using uirenderer::DrawGlInfo; if (!g_aw_drawgl_function) { ALOGE("Cannot draw: no DrawGL Function installed");