ImageEn for Delphi and C++ Builder ImageEn for Delphi and C++ Builder

 

ImageEn Forum
Profile    Join    Active Topics    Forum FAQ    Search this forumSearch
Forum membership is Free!  Click Join to sign-up
Username:
Password:
Save Password
Forgot your Password?

 All Forums
 ImageEn Library for Delphi, C++ and .Net
 ImageEn and IEvolution Support Forum
 Memory Leak in TImageEnVect
 New Topic  Reply to Topic
Author Previous Topic Topic Next Topic  

Siluro

Germany
2 Posts

Posted - Jun 11 2015 :  02:53:22  Show Profile  Reply
Hi,

I'm using TImageEnVect for a WYSIWYG page designer. For each object on the page I insert a bitmap object. For the data that I need for each object, I've created a custom class TUserData. Each bitmap object (ObjUserData) therefore has an instance of TUserData. When I remove an object from the canvas, I free the instance of TUserData.

So far everything works great but when I run proc.undo, I have an instance of TUserData in memory for each affected bitmap object and don't know how to free.

Maybe I'm just too blind to find the solution. Would be grateful for any help.

Best regards

Björn

xequte

38510 Posts

Posted - Jun 15 2015 :  00:34:32  Show Profile  Reply
Hi Bjorn

If ObjUserData and ObjUserDataLength have been set then the memory of ObjUserData should be cleared automatically when the object is destroyed. You should not need to be freeing the memory yourself.


Nigel
Xequte Software
www.xequte.com
nigel@xequte.com
Go to Top of Page
  Previous Topic Topic Next Topic  
 New Topic  Reply to Topic
Jump To: