[Overview][Constants][Types][Classes][Procedures and functions][Variables][Index] |
Frees the shared image in the bitmap, and creates a new one.
Source position: graphics.pp line 1418
protected procedure TCustomBitmap.UnshareImage( |
CopyContent: Boolean |
); override; |
CopyContent |
|
True copies the existing content in the shared image. |
UnshareImage is an overridden method used to free the shared image in the bitmap, and create a new one. UnshareImage implements the abstract virtual method defined in the ancestor class.
UnshareImage calls GetSharedImageClass to get the class type used for the shared image, and creates a new instance of the class. It is cast to TSharedCustomBitmap, and its Reference method is called to increment the reference count for the shared image.
CopyContent indicates whether the existing image data is copied into the new shared image instance. When set to True, the content in the existing shared image is copied and stored in the new shared image instance. When set to False, only the image descriptor in the shared image is copied. This gets the metadata for the image.
UnshareImage calls FreeCanvasContext to free the device context for the Canvas used in the image.
|
Unshares a shared image when its handle is changed or the save stream is freed. |
Version 3.2 | Generated 2024-02-25 | Home |