audioflinger: Make use of android-base/macros.h
Replace local definitions of "array size" macro, and
declarations of non-copyable objects with corresponding
constructs from android-base/macros.h.
Also change "protected:" to "private:" for classes
not designed to be inherited.
Change-Id: I2d1e6d153511ed84d52fe6377879f83258890653
Test: make
diff --git a/services/audioflinger/AudioFlinger.h b/services/audioflinger/AudioFlinger.h
index 5570d86..2e0bc66 100644
--- a/services/audioflinger/AudioFlinger.h
+++ b/services/audioflinger/AudioFlinger.h
@@ -25,6 +25,8 @@
#include <sys/types.h>
#include <limits.h>
+#include <android-base/macros.h>
+
#include <cutils/compiler.h>
#include <cutils/properties.h>
@@ -445,8 +447,8 @@
sp<AudioFlinger> audioFlinger() const { return mAudioFlinger; }
private:
- Client(const Client&);
- Client& operator = (const Client&);
+ DISALLOW_COPY_AND_ASSIGN(Client);
+
const sp<AudioFlinger> mAudioFlinger;
sp<MemoryDealer> mMemoryDealer;
const pid_t mPid;
@@ -466,8 +468,7 @@
virtual void binderDied(const wp<IBinder>& who);
private:
- NotificationClient(const NotificationClient&);
- NotificationClient& operator = (const NotificationClient&);
+ DISALLOW_COPY_AND_ASSIGN(NotificationClient);
const sp<AudioFlinger> mAudioFlinger;
const pid_t mPid;