win32: Fix int/long type mismatches.

This commit is contained in:
Alexandre Julliard 2022-11-23 12:02:27 +01:00
parent b00a831d3d
commit 7eb1e94299
6 changed files with 11 additions and 9 deletions

View file

@ -241,9 +241,9 @@ DLGPROC get_dialog_proc( DLGPROC ret, BOOL ansi )
{
WINDOWPROC *proc;
if (!(proc = get_winproc_ptr( ret ))) return ret;
if (!(proc = get_winproc_ptr( (WNDPROC)ret ))) return ret;
if (proc == WINPROC_PROC16) return WINPROC_PROC16;
return ansi ? proc->procA : proc->procW;
return (DLGPROC)(ansi ? proc->procA : proc->procW);
}
static void init_user(void)

View file

@ -570,6 +570,7 @@ void release_clipboard_owner( HWND hwnd )
NTSTATUS WINAPI NtUserSetClipboardData( UINT format, HANDLE data, struct set_clipboard_params *params )
{
struct cached_format *cache = NULL, *prev = NULL;
LCID lcid;
void *ptr = NULL;
data_size_t size = 0;
NTSTATUS status = STATUS_SUCCESS;
@ -603,13 +604,14 @@ NTSTATUS WINAPI NtUserSetClipboardData( UINT format, HANDLE data, struct set_cli
make_gdi_object_system( cache->handle, TRUE );
}
}
NtQueryDefaultLocale( TRUE, &lcid );
pthread_mutex_lock( &clipboard_mutex );
SERVER_START_REQ( set_clipboard_data )
{
req->format = format;
NtQueryDefaultLocale( TRUE, &req->lcid );
req->lcid = lcid;
wine_server_add_data( req, ptr, size );
if (!(status = wine_server_call( req )))
{

View file

@ -1111,8 +1111,8 @@ update_format:
*/
static DWORD calc_1d_stretch_params( INT dst_start, INT dst_length, INT dst_vis_start, INT dst_vis_end,
INT src_start, INT src_length, INT src_vis_start, INT src_vis_end,
INT *dst_clipped_start, INT *src_clipped_start,
INT *dst_clipped_end, INT *src_clipped_end,
LONG *dst_clipped_start, LONG *src_clipped_start,
LONG *dst_clipped_end, LONG *src_clipped_end,
struct stretch_params *stretch_params, BOOL *stretch )
{
bres_params bres_params;

View file

@ -229,11 +229,11 @@ static inline void get_color_masks( DC *dc, const dib_info *dib, UINT rop, COLOR
calc_rop_masks( rop, color, bg_mask );
}
static inline void order_end_points(int *s, int *e)
static inline void order_end_points(LONG *s, LONG *e)
{
if(*s > *e)
{
int tmp;
LONG tmp;
tmp = *s + 1;
*s = *e + 1;
*e = tmp;

View file

@ -5337,7 +5337,7 @@ BOOL WINAPI NtUserSetSysColors( INT count, const INT *colors, const COLORREF *va
}
static DPI_AWARENESS dpi_awareness;
static LONG dpi_awareness;
/***********************************************************************
* NtUserSetProcessDpiAwarenessContext (win32u.@)

View file

@ -138,7 +138,7 @@ struct unix_funcs
INT width, INT height, HBITMAP mask, INT x_mask, INT y_mask,
DWORD bk_color );
BOOL (WINAPI *pNtGdiPolyDraw)(HDC hdc, const POINT *points, const BYTE *types, DWORD count );
ULONG (WINAPI *pNtGdiPolyPolyDraw)( HDC hdc, const POINT *points, const UINT *counts,
ULONG (WINAPI *pNtGdiPolyPolyDraw)( HDC hdc, const POINT *points, const ULONG *counts,
DWORD count, UINT function );
BOOL (WINAPI *pNtGdiPtVisible)( HDC hdc, INT x, INT y );
BOOL (WINAPI *pNtGdiRectVisible)( HDC hdc, const RECT *rect );