[4/5] ddraw: Get rid of ICOM_INTERFACE.

Stefan Dösinger stefan at codeweavers.com
Wed Jan 21 05:30:17 CST 2009


> -----Original Message-----
> From: wine-patches-bounces at winehq.org [mailto:wine-patches-
> bounces at winehq.org] On Behalf Of Henri Verbeet
> Sent: Wednesday, January 21, 2009 10:01 AM
> To: wine-patches at winehq.org
> Subject: [4/5] ddraw: Get rid of ICOM_INTERFACE.
> 

> -        *obj = ICOM_INTERFACE(This, IDirect3DDevice3);
> +        *obj = &This->IDirect3DDevice3_vtbl;

> -        *obj = ICOM_INTERFACE(This, IDirect3DDevice7);
> +        *obj = This;

> -    return IDirect3DDevice7_AddRef(ICOM_INTERFACE(This,
IDirect3DDevice7));
> +    return IDirect3DDevice7_AddRef((IDirect3DDevice7 *)This);

I think it would be better to access IDirect3DDevice7 via explicit
specifying the vtable, or an inline function for consistency and to avoid
hardwiring the assumption that the IDirect3DDevice7 vtable is the first
member of the object





More information about the wine-devel mailing list