From 88fe14c06ffc86ce7911a526d3bb2561690511f0 Mon Sep 17 00:00:00 2001 From: Gilles Depeyrot Date: Sun, 6 Jan 2002 15:48:16 +0000 Subject: [PATCH 1/1] removing dependancy on mac headers from public wx headers (eventually adding wx/ mac/private and typecasts) git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@13415 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775 --- src/mac/carbon/pnghand.cpp | 9 +++++---- src/mac/pnghand.cpp | 9 +++++---- 2 files changed, 10 insertions(+), 8 deletions(-) diff --git a/src/mac/carbon/pnghand.cpp b/src/mac/carbon/pnghand.cpp index 193676f195..1ebf612f17 100644 --- a/src/mac/carbon/pnghand.cpp +++ b/src/mac/carbon/pnghand.cpp @@ -39,6 +39,7 @@ #include "wx/bitmap.h" #include "wx/mac/pnghand.h" #include "wx/mac/pngread.h" +#include "wx/mac/private.h" extern "C" { #include "png.h" @@ -116,7 +117,7 @@ wxPNGReader::Create(int width, int height, int depth, int colortype) if (lpbi) { - wxMacDestroyGWorld( lpbi ) ; + wxMacDestroyGWorld( (GWorldPtr) lpbi ) ; } lpbi = wxMacCreateGWorld( Width , Height , Depth); if (lpbi) @@ -135,7 +136,7 @@ wxPNGReader::~wxPNGReader ( ) { delete[] RawImage ; if (lpbi) { - wxMacDestroyGWorld( lpbi ) ; + wxMacDestroyGWorld( (GWorldPtr) lpbi ) ; } delete m_palette; } @@ -258,7 +259,7 @@ wxPNGReader::SetPalette(int n, rgb_color_struct *rgb_struct) void wxPNGReader::NullData() { if (lpbi) { - wxMacDestroyGWorld( lpbi ) ; + wxMacDestroyGWorld( (GWorldPtr) lpbi ) ; } delete m_palette; lpbi = NULL; @@ -512,7 +513,7 @@ bool wxPNGReader::ReadFile(char * ImageFileName) GetGWorld( &origPort , &origDevice ) ; // ignore shapedc - SetGWorld( lpbi , NULL ) ; + SetGWorld( (GWorldPtr) lpbi , NULL ) ; do { // (unsigned char *)iter.GetRow(); diff --git a/src/mac/pnghand.cpp b/src/mac/pnghand.cpp index 193676f195..1ebf612f17 100644 --- a/src/mac/pnghand.cpp +++ b/src/mac/pnghand.cpp @@ -39,6 +39,7 @@ #include "wx/bitmap.h" #include "wx/mac/pnghand.h" #include "wx/mac/pngread.h" +#include "wx/mac/private.h" extern "C" { #include "png.h" @@ -116,7 +117,7 @@ wxPNGReader::Create(int width, int height, int depth, int colortype) if (lpbi) { - wxMacDestroyGWorld( lpbi ) ; + wxMacDestroyGWorld( (GWorldPtr) lpbi ) ; } lpbi = wxMacCreateGWorld( Width , Height , Depth); if (lpbi) @@ -135,7 +136,7 @@ wxPNGReader::~wxPNGReader ( ) { delete[] RawImage ; if (lpbi) { - wxMacDestroyGWorld( lpbi ) ; + wxMacDestroyGWorld( (GWorldPtr) lpbi ) ; } delete m_palette; } @@ -258,7 +259,7 @@ wxPNGReader::SetPalette(int n, rgb_color_struct *rgb_struct) void wxPNGReader::NullData() { if (lpbi) { - wxMacDestroyGWorld( lpbi ) ; + wxMacDestroyGWorld( (GWorldPtr) lpbi ) ; } delete m_palette; lpbi = NULL; @@ -512,7 +513,7 @@ bool wxPNGReader::ReadFile(char * ImageFileName) GetGWorld( &origPort , &origDevice ) ; // ignore shapedc - SetGWorld( lpbi , NULL ) ; + SetGWorld( (GWorldPtr) lpbi , NULL ) ; do { // (unsigned char *)iter.GetRow(); -- 2.45.2