]> git.saurik.com Git - wxWidgets.git/commitdiff
BCC compilation fix
authorVáclav Slavík <vslavik@fastmail.fm>
Fri, 2 Jul 2004 19:38:13 +0000 (19:38 +0000)
committerVáclav Slavík <vslavik@fastmail.fm>
Fri, 2 Jul 2004 19:38:13 +0000 (19:38 +0000)
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@28145 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775

src/msw/window.cpp

index 93bb8f27c8cdd3505e5e5eafdd9993592e30016c..345427d25afd6274ab66ea5ea3cd63c59ef2df6c 100644 (file)
@@ -1671,7 +1671,11 @@ void wxWindowMSW::GetTextExtent(const wxString& string,
     wxASSERT_MSG( !theFont || theFont->Ok(),
                     _T("invalid font in GetTextExtent()") );
 
-    const wxFont fontToUse(theFont ? *theFont : GetFont());
+    wxFont fontToUse;
+    if (theFont)
+        fontToUse = *theFont;
+    else
+        fontToUse = GetFont();
 
     WindowHDC hdc(GetHwnd());
     SelectInHDC selectFont(hdc, GetHfontOf(fontToUse));