diff options
| author | 2019-03-06 18:00:40 +0000 | |
|---|---|---|
| committer | 2019-03-06 18:00:40 +0000 | |
| commit | 4800f2e1eeef510329d78a69945724e7df084b32 (patch) | |
| tree | 6b79d90372fd88ca04bd13c8aca19274e53859ca | |
| parent | 9f166127de7f8673d59783fb7f2f72d57f515251 (diff) | |
| parent | 7b743be32dbf576f43931be3ac968332dd0f070c (diff) | |
Merge "SF: fix up DispSync interface"
| -rw-r--r-- | services/surfaceflinger/Scheduler/DispSync.cpp | 1 | ||||
| -rw-r--r-- | services/surfaceflinger/Scheduler/DispSync.h | 17 |
2 files changed, 13 insertions, 5 deletions
diff --git a/services/surfaceflinger/Scheduler/DispSync.cpp b/services/surfaceflinger/Scheduler/DispSync.cpp index 665179e93e..1eccf9a73b 100644 --- a/services/surfaceflinger/Scheduler/DispSync.cpp +++ b/services/surfaceflinger/Scheduler/DispSync.cpp @@ -43,6 +43,7 @@ using std::min; namespace android { DispSync::~DispSync() = default; +DispSync::Callback::~Callback() = default; namespace impl { diff --git a/services/surfaceflinger/Scheduler/DispSync.h b/services/surfaceflinger/Scheduler/DispSync.h index 4a90f10215..f62969760f 100644 --- a/services/surfaceflinger/Scheduler/DispSync.h +++ b/services/surfaceflinger/Scheduler/DispSync.h @@ -14,8 +14,7 @@ * limitations under the License. */ -#ifndef ANDROID_DISPSYNC_H -#define ANDROID_DISPSYNC_H +#pragma once #include <stddef.h> @@ -35,10 +34,16 @@ class DispSync { public: class Callback { public: - virtual ~Callback() = default; + Callback() = default; + virtual ~Callback(); virtual void onDispSyncEvent(nsecs_t when) = 0; + + protected: + Callback(Callback const&) = delete; + Callback& operator=(Callback const&) = delete; }; + DispSync() = default; virtual ~DispSync(); virtual void reset() = 0; @@ -57,6 +62,10 @@ public: virtual nsecs_t expectedPresentTime() = 0; virtual void dump(std::string& result) const = 0; + +protected: + DispSync(DispSync const&) = delete; + DispSync& operator=(DispSync const&) = delete; }; namespace impl { @@ -239,5 +248,3 @@ private: } // namespace impl } // namespace android - -#endif // ANDROID_DISPSYNC_H |