Get rid of a use of WXSTRINGCAST from src/msw/metafile.cpp

WXSTRINGCAST is a const-removing cast and should be avoided unless necessary.

Here, wxString::c_str() is sufficient because GetTextExtentPoint32 takes
a const pointer.
This commit is contained in:
ARATA Mizuki
2016-02-17 23:41:13 +09:00
parent 86dd0cd2a2
commit 381ab333b9

View File

@@ -236,7 +236,7 @@ void wxMetafileDCImpl::DoGetTextExtent(const wxString& string,
SIZE sizeRect;
TEXTMETRIC tm;
::GetTextExtentPoint32(dc, WXSTRINGCAST string, wxStrlen(WXSTRINGCAST string), &sizeRect);
::GetTextExtentPoint32(dc, string.c_str(), string.length(), &sizeRect);
::GetTextMetrics(dc, &tm);
if ( x )