Browse Source

Don't use Releasable on ElementInstancer, lifetime should be handled by user.

Michael Ragazzon 6 years ago
parent
commit
8764f8ee89

+ 1 - 1
Include/RmlUi/Core/ElementInstancer.h

@@ -52,7 +52,7 @@ class Element;
 	@author Lloyd Weehuizen
  */ 
 
-class RMLUICORE_API ElementInstancer : public Releasable
+class RMLUICORE_API ElementInstancer : public NonCopyMoveable
 {
 public:
 	virtual ~ElementInstancer();

+ 0 - 3
Include/RmlUi/Core/ElementInstancerGeneric.h

@@ -57,9 +57,6 @@ public:
 	/// Releases the given element
 	/// @param element to release
 	void ReleaseElement(Element* element) override;
-
-	/// Release the instancer
-	void Release() override;
 };
 
 }

+ 0 - 8
Include/RmlUi/Core/ElementInstancerGeneric.inl

@@ -50,13 +50,5 @@ void ElementInstancerGeneric<T>::ReleaseElement(Element* element)
 	delete element;
 }
 
-
-// Release the instancer
-template <typename T>
-void ElementInstancerGeneric<T>::Release()
-{
-	delete this;
-}
-
 }
 }