From 957f03699b05057de4d75af2f19e08f38ade03ff Mon Sep 17 00:00:00 2001 From: Chris Elliott Date: Tue, 6 May 2003 15:08:52 +0000 Subject: [PATCH] possible fix for templates with digitalmars git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@20502 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775 --- include/wx/platform.h | 2 +- include/wx/rawbmp.h | 31 +++++++++++++++++++++++++++++++ 2 files changed, 32 insertions(+), 1 deletion(-) diff --git a/include/wx/platform.h b/include/wx/platform.h index dfcbfb2329..24d8e5a99f 100644 --- a/include/wx/platform.h +++ b/include/wx/platform.h @@ -306,7 +306,7 @@ #endif #if defined (__WXMSW__) - #if !defined(__DIGITALMARS__) && !defined(__WATCOMC__) + #if !defined(__WATCOMC__) #define wxHAVE_RAW_BITMAP #endif #endif diff --git a/include/wx/rawbmp.h b/include/wx/rawbmp.h index 2d43d81e29..a9199e541c 100644 --- a/include/wx/rawbmp.h +++ b/include/wx/rawbmp.h @@ -100,9 +100,17 @@ - index of the alpha component or -1 if none - type which can contain the full pixel value (all channels) */ + +#ifdef __DIGITALMARS__ +template +#else template +#endif + struct WXDLLEXPORT wxPixelFormat { // iterator over pixels is usually of type "ChannelType *" @@ -621,6 +629,28 @@ struct WXDLLEXPORT wxPixelDataOut }; }; +#ifdef __DIGITALMARS__ +template > +class wxPixelData : + public wxPixelDataOut:: wxPixelDataIn +{ +public: + wxPixelData(Image& image) + : wxPixelDataOut:: wxPixelDataIn(image) + { + } + + wxPixelData(Image& i, const wxPoint& pt, const wxSize& sz) + : wxPixelDataOut:: wxPixelDataIn(i, pt, sz) + { + } + + wxPixelData(Image& i, const wxRect& rect) + : wxPixelDataOut:: wxPixelDataIn(i, rect) + { + } +}; +#else // not __DIGITALMARS__ template > class wxPixelData : public wxPixelDataOut::template wxPixelDataIn @@ -641,6 +671,7 @@ public: { } }; +#endif // __DIGITALMARS__ // some "predefined" pixel data classes typedef wxPixelData wxImagePixelData; -- 2.45.2