Merge "use modern construct '= default' for special functions." into devel/master
[platform/core/uifw/dali-core.git] / dali / internal / event / actors / custom-actor-internal.cpp
index 273b6ac..33f302a 100644 (file)
@@ -17,6 +17,7 @@
 
 // CLASS HEADER
 #include <dali/internal/event/actors/custom-actor-internal.h>
+#include <dali/public-api/object/type-info.h>
 
 namespace Dali
 {
@@ -26,7 +27,7 @@ namespace Internal
 
 CustomActorPtr CustomActor::New(CustomActorImpl& extension)
 {
-  CustomActorPtr actor(new CustomActor(extension));
+  CustomActorPtr actor(new CustomActor( *CreateNode(), extension));
 
   // Second-phase construction
   extension.Initialize(*actor);
@@ -35,17 +36,19 @@ CustomActorPtr CustomActor::New(CustomActorImpl& extension)
   return actor;
 }
 
-CustomActor::CustomActor(CustomActorImpl& extension)
-: Actor( Actor::BASIC ),
+CustomActor::CustomActor( const SceneGraph::Node& node, CustomActorImpl& extension)
+: Actor( Actor::BASIC, node ),
   mImpl( &extension )
 {
-  mDerivedRequiresTouch = extension.RequiresTouchEvents();
-  mDerivedRequiresHover = extension.RequiresHoverEvents();
-  mDerivedRequiresMouseWheelEvent = extension.RequiresMouseWheelEvents();
+  SetRelayoutEnabled( extension.IsRelayoutEnabled() );
 }
 
-CustomActor::~CustomActor()
+CustomActor::~CustomActor() = default;
+
+Dali::TypeInfo CustomActor::GetTypeInfo()
 {
+  Dali::TypeInfo handle ( const_cast<Dali::Internal::TypeInfo*>(Object::GetTypeInfo()) );
+  return handle;
 }
 
 } // namespace Internal