X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/b59ff3c9c8d59c2c4e0291b964d349c9df839894..cc985face55ed02c310860afefc8e6d656fb849d:/src/common/imagjpeg.cpp diff --git a/src/common/imagjpeg.cpp b/src/common/imagjpeg.cpp index b8f642502f..9a82b1029a 100644 --- a/src/common/imagjpeg.cpp +++ b/src/common/imagjpeg.cpp @@ -10,10 +10,6 @@ /* We don't put pragma implement in this file because it is already present in src/common/image.cpp - -#ifdef __GNUG__ -#pragma implementation "image.h" -#endif */ // For compilers that support precompilation, includes "wx.h". @@ -23,16 +19,18 @@ #pragma hdrstop #endif +#include "wx/defs.h" + +#if wxUSE_LIBJPEG + #include "wx/image.h" #include "wx/bitmap.h" #include "wx/debug.h" #include "wx/log.h" #include "wx/app.h" -#if wxUSE_LIBJPEG -extern "C" { -#include +extern "C" { +#include "jpeglib.h" } -#endif #include "wx/filefn.h" #include "wx/wfstream.h" #include "wx/intl.h" @@ -57,15 +55,12 @@ extern "C" { // wxJPEGHandler //----------------------------------------------------------------------------- -#if wxUSE_LIBJPEG - #if !USE_SHARED_LIBRARIES IMPLEMENT_DYNAMIC_CLASS(wxJPEGHandler,wxImageHandler) #endif #if wxUSE_STREAMS - //------------- JPEG Data Source Manager typedef struct { @@ -76,11 +71,11 @@ typedef struct { typedef my_source_mgr * my_src_ptr; -METHODDEF(void) my_init_source ( j_decompress_ptr cinfo ) +METHODDEF(void) my_init_source ( j_decompress_ptr WXUNUSED(cinfo) ) { } -METHODDEF(boolean) my_fill_input_buffer ( j_decompress_ptr cinfo ) +METHODDEF(boolean) my_fill_input_buffer ( j_decompress_ptr WXUNUSED(cinfo) ) { return TRUE; } @@ -310,12 +305,12 @@ bool wxJPEGHandler::SaveFile( wxImage *image, wxOutputStream& stream ) return TRUE; } -#endif // wxUSE_STREAMS - -#endif -// wxUSE_LIBJPEG +#endif + // wxUSE_STREAMS +#endif + // wxUSE_LIBJPEG