Commit 6c49dfff authored by Jacek Caban's avatar Jacek Caban Committed by Alexandre Julliard

user32: Use NtUserInternalGetWindowText in GetWindowText.

Instead of get_server_window_text. Signed-off-by: 's avatarJacek Caban <jacek@codeweavers.com> Signed-off-by: 's avatarHuw Davies <huw@codeweavers.com> Signed-off-by: 's avatarAlexandre Julliard <julliard@winehq.org>
parent 90c13be9
...@@ -2927,7 +2927,7 @@ INT WINAPI GetWindowTextA( HWND hwnd, LPSTR lpString, INT nMaxCount ) ...@@ -2927,7 +2927,7 @@ INT WINAPI GetWindowTextA( HWND hwnd, LPSTR lpString, INT nMaxCount )
else if ((buffer = HeapAlloc( GetProcessHeap(), 0, nMaxCount * sizeof(WCHAR) ))) else if ((buffer = HeapAlloc( GetProcessHeap(), 0, nMaxCount * sizeof(WCHAR) )))
{ {
/* when window belongs to other process, don't send a message */ /* when window belongs to other process, don't send a message */
get_server_window_text( hwnd, buffer, nMaxCount ); NtUserInternalGetWindowText( hwnd, buffer, nMaxCount );
if (!WideCharToMultiByte( CP_ACP, 0, buffer, -1, lpString, nMaxCount, NULL, NULL )) if (!WideCharToMultiByte( CP_ACP, 0, buffer, -1, lpString, nMaxCount, NULL, NULL ))
lpString[nMaxCount-1] = 0; lpString[nMaxCount-1] = 0;
HeapFree( GetProcessHeap(), 0, buffer ); HeapFree( GetProcessHeap(), 0, buffer );
...@@ -2964,8 +2964,7 @@ INT WINAPI GetWindowTextW( HWND hwnd, LPWSTR lpString, INT nMaxCount ) ...@@ -2964,8 +2964,7 @@ INT WINAPI GetWindowTextW( HWND hwnd, LPWSTR lpString, INT nMaxCount )
else else
{ {
/* when window belongs to other process, don't send a message */ /* when window belongs to other process, don't send a message */
get_server_window_text( hwnd, lpString, nMaxCount ); ret = NtUserInternalGetWindowText( hwnd, lpString, nMaxCount );
ret = lstrlenW(lpString);
} }
} }
__EXCEPT_PAGE_FAULT __EXCEPT_PAGE_FAULT
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment