From d8692f2b805de780a6a625879abbe550830a5bab Mon Sep 17 00:00:00 2001 From: Vadim Zeitlin Date: Mon, 4 Aug 2003 17:48:35 +0000 Subject: [PATCH] copy wxImage options when copying the images (replaces patch 780705) git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@22588 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775 --- src/common/image.cpp | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/src/common/image.cpp b/src/common/image.cpp index d9f07d30b2..1d39aeff5c 100644 --- a/src/common/image.cpp +++ b/src/common/image.cpp @@ -219,6 +219,11 @@ wxImage wxImage::Copy() const memcpy( data, GetData(), M_IMGDATA->m_width*M_IMGDATA->m_height*3 ); + // also copy the image options + wxImageRefData *imgData = (wxImageRefData *)image.m_refData; + imgData->m_optionNames = M_IMGDATA->m_optionNames; + imgData->m_optionValues = M_IMGDATA->m_optionValues; + return image; } -- 2.45.2