Simplify ExtTextOut a bit. Should be a nop.
This commit is contained in:
parent
523fef0c77
commit
85cd13506d
|
@ -1718,6 +1718,8 @@ BOOL WINAPI ExtTextOutW( HDC hdc, INT x, INT y, UINT flags,
|
||||||
const RECT *lprect, LPCWSTR str, UINT count, const INT *lpDx )
|
const RECT *lprect, LPCWSTR str, UINT count, const INT *lpDx )
|
||||||
{
|
{
|
||||||
BOOL ret = FALSE;
|
BOOL ret = FALSE;
|
||||||
|
LPWSTR reordered_string = (LPWSTR)str;
|
||||||
|
|
||||||
DC * dc = DC_GetDCUpdate( hdc );
|
DC * dc = DC_GetDCUpdate( hdc );
|
||||||
if (dc)
|
if (dc)
|
||||||
{
|
{
|
||||||
|
@ -1732,19 +1734,20 @@ BOOL WINAPI ExtTextOutW( HDC hdc, INT x, INT y, UINT flags,
|
||||||
{
|
{
|
||||||
/* The caller did not specify that language processing was already done.
|
/* The caller did not specify that language processing was already done.
|
||||||
*/
|
*/
|
||||||
LPWSTR lpReorderedString=HeapAlloc(GetProcessHeap(), 0, count*sizeof(WCHAR));
|
reordered_string = HeapAlloc(GetProcessHeap(), 0, count*sizeof(WCHAR));
|
||||||
|
|
||||||
BIDI_Reorder( str, count, GCP_REORDER,
|
BIDI_Reorder( str, count, GCP_REORDER,
|
||||||
((flags&ETO_RTLREADING)!=0 || (GetTextAlign(hdc)&TA_RTLREADING)!=0)?
|
((flags&ETO_RTLREADING)!=0 || (GetTextAlign(hdc)&TA_RTLREADING)!=0)?
|
||||||
WINE_GCPW_FORCE_RTL:WINE_GCPW_FORCE_LTR,
|
WINE_GCPW_FORCE_RTL:WINE_GCPW_FORCE_LTR,
|
||||||
lpReorderedString, count, NULL );
|
reordered_string, count, NULL );
|
||||||
|
|
||||||
ret = dc->funcs->pExtTextOut(dc->physDev,x,y,flags|ETO_IGNORELANGUAGE,
|
flags |= ETO_IGNORELANGUAGE;
|
||||||
lprect,lpReorderedString,count,lpDx,dc->breakExtra);
|
}
|
||||||
HeapFree(GetProcessHeap(), 0, lpReorderedString);
|
ret = dc->funcs->pExtTextOut(dc->physDev,x,y,flags,lprect,reordered_string,count,
|
||||||
} else
|
lpDx,dc->breakExtra);
|
||||||
ret = dc->funcs->pExtTextOut(dc->physDev,x,y,flags,lprect,str,count,
|
|
||||||
lpDx,dc->breakExtra);
|
if(reordered_string != str)
|
||||||
|
HeapFree(GetProcessHeap(), 0, reordered_string);
|
||||||
}
|
}
|
||||||
GDI_ReleaseObj( hdc );
|
GDI_ReleaseObj( hdc );
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue