Add move semantics to common and base Toolkit classes
[platform/core/uifw/dali-toolkit.git] / dali-toolkit / public-api / controls / buttons / push-button.cpp
index 6a70aaf..0cc3706 100644 (file)
@@ -1,5 +1,5 @@
 /*
- * Copyright (c) 2019 Samsung Electronics Co., Ltd.
+ * Copyright (c) 2020 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.
@@ -21,7 +21,6 @@
 // EXTERNAL INCLUDES
 #include <dali/integration-api/debug.h>
 
-#include <dali/public-api/images/resource-image.h>
 
 // INTERNAL INCLUDES
 #include <dali-toolkit/internal/controls/buttons/push-button-impl.h>
@@ -42,19 +41,13 @@ PushButton::PushButton( Internal::PushButton& implementation )
 {
 }
 
-PushButton::PushButton( const PushButton& pushButton )
-: Button( pushButton )
-{
-}
+PushButton::PushButton( const PushButton& pushButton ) = default;
 
-PushButton& PushButton::operator=( const PushButton& pushButton )
-{
-  if( &pushButton != this )
-  {
-    Button::operator=( pushButton );
-  }
-  return *this;
-}
+PushButton::PushButton( PushButton&& rhs ) = default;
+
+PushButton& PushButton::operator=( const PushButton& pushButton ) = default;
+
+PushButton& PushButton::operator=( PushButton&& rhs ) = default;
 
 PushButton::PushButton( Dali::Internal::CustomActor* internal )
 : Button( internal )