Mac OS X: Speedup of Fl::set_fonts() if called repeatedly.

Fixes STR 2383

git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@7681 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
This commit is contained in:
Manolo Gouy 2010-08-20 13:07:13 +00:00
parent 55c20361dd
commit 68cecd9025
1 changed files with 2 additions and 0 deletions

View File

@ -60,6 +60,8 @@ static int fl_free_font = FL_FREE_FONT;
Fl_Font Fl::set_fonts(const char* xstarname) {
#pragma unused ( xstarname )
if (fl_free_font > FL_FREE_FONT) return (Fl_Font)fl_free_font; // if already called
#if MAC_OS_X_VERSION_MAX_ALLOWED >= MAC_OS_X_VERSION_10_5
static SInt32 MACsystemVersion = 0;
if(MACsystemVersion == 0) Gestalt(gestaltSystemVersion, &MACsystemVersion);