summaryrefslogtreecommitdiffstats
path: root/cmds/screenrecord/Overlay.h
diff options
context:
space:
mode:
authorAndy McFadden <fadden@android.com>2014-03-03 17:09:54 -0800
committerAndy McFadden <fadden@android.com>2014-03-03 17:09:54 -0800
commit778dccf9a7aa05e0c8df1481ea1d6048bb659667 (patch)
treea30af7320f717273bdebebf11be17849d850989e /cmds/screenrecord/Overlay.h
parentfeac1a43c8b674c4b526214fa8061452fd6e4846 (diff)
downloadframeworks_av-778dccf9a7aa05e0c8df1481ea1d6048bb659667.zip
frameworks_av-778dccf9a7aa05e0c8df1481ea1d6048bb659667.tar.gz
frameworks_av-778dccf9a7aa05e0c8df1481ea1d6048bb659667.tar.bz2
Fix destructors
Make destructors private -- only RefBase should be able to destroy instances of these. Change-Id: Iff52e226995fe5740a9dfc35af53dd6dd9d74501
Diffstat (limited to 'cmds/screenrecord/Overlay.h')
-rw-r--r--cmds/screenrecord/Overlay.h4
1 files changed, 3 insertions, 1 deletions
diff --git a/cmds/screenrecord/Overlay.h b/cmds/screenrecord/Overlay.h
index b8473b4..48e48e0 100644
--- a/cmds/screenrecord/Overlay.h
+++ b/cmds/screenrecord/Overlay.h
@@ -47,7 +47,6 @@ public:
mLastFrameNumber(-1),
mTotalDroppedFrames(0)
{}
- virtual ~Overlay() { assert(mState == UNINITIALIZED || mState == STOPPED); }
// Creates a thread that performs the overlay. Pass in the surface that
// output will be sent to.
@@ -71,6 +70,9 @@ private:
Overlay(const Overlay&);
Overlay& operator=(const Overlay&);
+ // Destruction via RefBase.
+ virtual ~Overlay() { assert(mState == UNINITIALIZED || mState == STOPPED); }
+
// Draw the initial info screen.
static void doDrawInfoPage(const EglWindow& window,
const Program& texRender, TextRenderer& textRenderer);