[dali_2.3.26] Merge branch 'devel/master'
[platform/core/uifw/dali-core.git] / dali / internal / event / common / property-notification-manager.h
index 4229be2..c6d0477 100644 (file)
@@ -2,7 +2,7 @@
 #define DALI_INTERNAL_PROPERTY_NOTIFICATION_MANAGER_H
 
 /*
- * Copyright (c) 2023 Samsung Electronics Co., Ltd.
+ * Copyright (c) 2024 Samsung Electronics Co., Ltd.
  *
  * Licensed under the Apache License, Version 2.0 (the "License");
  * you may not use this file except in compliance with the License.
  *
  */
 
-// EXTERNAL INCLUDES
-#include <unordered_map>
-
 // INTERNAL INCLUDES
-#include <dali/internal/common/ordered-set.h>
+#include <dali/integration-api/ordered-set.h>
 #include <dali/internal/event/common/property-notifier.h>
+#include <dali/internal/event/common/scene-graph-notifier-interface-mapper.h>
 #include <dali/public-api/common/dali-vector.h>
 
 namespace Dali
@@ -38,7 +36,7 @@ class PropertyNotification;
  * It also monitors the lifetime of PropertyNotification objects and will
  * only emit signals for PropertyNotification objects which are still valid.
  */
-class PropertyNotificationManager : public PropertyNotifier
+class PropertyNotificationManager : public PropertyNotifier, public SceneGraphNotifierInterfaceMapper<PropertyNotification>
 {
 public:
   /**
@@ -62,21 +60,11 @@ public:
    */
   void PropertyNotificationDestroyed(PropertyNotification& propertyNotification);
 
-  /**
-   * Called when a SceneGraph::PropertyNotification is mapping by PropertyNotification.
-   */
-  void PropertyNotificationSceneObjectMapping(const SceneGraph::PropertyNotification* sceneGraphPropertyNotification, PropertyNotification& propertyNotification);
-
-  /**
-   * Called when a SceneGraph::PropertyNotification is unmaped from PropertyNotification.
-   */
-  void PropertyNotificationSceneObjectUnmapping(const SceneGraph::PropertyNotification* sceneGraphPropertyNotification);
-
 private: // private virtual overrides
   /**
    * @copydoc PropertyNotifier::NotifyProperty
    */
-  void NotifyProperty(SceneGraph::PropertyNotification* sceneGraphPropertyNotification, bool validity) override;
+  void NotifyProperty(NotifierInterface::NotifyId notifyId, bool validity) override;
 
 private:
   /**
@@ -91,9 +79,7 @@ private:
   PropertyNotificationManager& operator=(const PropertyNotificationManager& rhs);
 
 private:
-  OrderedSet<PropertyNotification, false> mPropertyNotifications; ///< All existing PropertyNotifications (not owned)
-
-  std::unordered_map<const SceneGraph::PropertyNotification*, PropertyNotification*> mSceneGraphObjectMap; ///< Converter from SceneGraph object pointer to Event object.
+  Integration::OrderedSet<PropertyNotification, false> mPropertyNotifications; ///< All existing PropertyNotifications (not owned)
 };
 
 } // namespace Internal