Remove support for Win9x from wxMSW.
Most importantly, this allows us to remove all MSLU-related stuff. Some functions which were previously loaded dynamically can now be just used directly, too. git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76535 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
@@ -154,27 +154,12 @@ bool wxTextMeasure::DoGetPartialTextExtents(const wxString& text,
|
||||
if ( !m_hdc )
|
||||
return wxTextMeasureBase::DoGetPartialTextExtents(text, widths, scaleX);
|
||||
|
||||
static int maxLenText = -1;
|
||||
static int maxWidth = -1;
|
||||
|
||||
if (maxLenText == -1)
|
||||
{
|
||||
// Win9x and WinNT+ have different limits
|
||||
int version = wxGetOsVersion();
|
||||
maxLenText = version == wxOS_WINDOWS_NT ? 65535 : 8192;
|
||||
maxWidth = version == wxOS_WINDOWS_NT ? INT_MAX : 32767;
|
||||
}
|
||||
|
||||
int len = text.length();
|
||||
if ( len > maxLenText )
|
||||
len = maxLenText;
|
||||
|
||||
int fit = 0;
|
||||
SIZE sz = {0,0};
|
||||
if ( !::GetTextExtentExPoint(m_hdc,
|
||||
text.t_str(), // string to check
|
||||
len,
|
||||
maxWidth,
|
||||
text.length(),
|
||||
INT_MAX, // max allowable width
|
||||
&fit, // [out] count of chars
|
||||
// that will fit
|
||||
&widths[0], // array to fill
|
||||
|
Reference in New Issue
Block a user