X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/32d4c30a13f65b7c8cb66f813a0b8c606ad8480b..7d6a4d96961eac84d05db8bb24c64d39003f6e54:/src/cocoa/fontutil.cpp?ds=sidebyside diff --git a/src/cocoa/fontutil.cpp b/src/cocoa/fontutil.cpp index dbb6d544aa..7d3eb844ae 100644 --- a/src/cocoa/fontutil.cpp +++ b/src/cocoa/fontutil.cpp @@ -6,7 +6,7 @@ // Created: 05.11.99 // RCS-ID: $Id$ // Copyright: (c) Vadim Zeitlin -// Licence: wxWindows license +// Licence: wxWindows licence ///////////////////////////////////////////////////////////////////////////// // ============================================================================ @@ -24,14 +24,16 @@ #pragma hdrstop #endif +#include "wx/fontutil.h" + #ifndef WX_PRECOMP #include "wx/hash.h" + #include "wx/utils.h" + #include "wx/module.h" #endif // PCH -#include "wx/fontutil.h" #include "wx/fontmap.h" #include "wx/tokenzr.h" -#include "wx/module.h" #include "wx/encinfo.h" #ifdef __WXGTK20__ @@ -162,7 +164,6 @@ bool wxGetNativeFontEncoding(wxFontEncoding encoding, #pragma message enable nosimpint #endif - #include "wx/utils.h" // for wxGetDisplay() #elif defined(__WXGTK__) // we have to declare struct tm to avoid problems with first forward // declaring it in C code (glib.h included from gdk.h does it) and then @@ -178,7 +179,7 @@ bool wxGetNativeFontEncoding(wxFontEncoding encoding, // private data // ---------------------------------------------------------------------------- -static wxHashTable *g_fontHash = (wxHashTable*) NULL; +static wxHashTable *g_fontHash = NULL; // ---------------------------------------------------------------------------- // private functions @@ -248,9 +249,7 @@ bool wxFontModule::OnInit() void wxFontModule::OnExit() { - delete g_fontHash; - - g_fontHash = (wxHashTable *)NULL; + wxDELETE(g_fontHash); } #endif