Added a name to Surface created by SurfaceFlinger
Updated the window manager to use this new facility.
Surfaces name are now printed by "dumpsys".
diff --git a/libs/surfaceflinger/LayerBase.h b/libs/surfaceflinger/LayerBase.h
index 6aacd82..7ac8bc5 100644
--- a/libs/surfaceflinger/LayerBase.h
+++ b/libs/surfaceflinger/LayerBase.h
@@ -320,6 +320,8 @@
const sp<Client>& client, int32_t i);
virtual ~LayerBaseClient();
virtual void onFirstRef();
+ void setName(const String8& name);
+ String8 getName() const;
const wp<Client> client;
@@ -333,6 +335,7 @@
virtual void onRemoved();
+
class Surface : public BnSurface
{
public:
@@ -371,6 +374,7 @@
mutable Mutex mLock;
mutable wp<Surface> mClientSurface;
// only read
+ String8 mName;
const uint32_t mIdentity;
static int32_t sIdentity;
};