- I still can't figure how to implement interface that consist of two
interfaces (I have IDirectMusicLoaderStream which should consist of IStream and IDirectMusicGetLoader). Can someone send me detailed instructions how to do it? (I can't find any examples)
I think what you want to do is implement two interfaces in one object, which is a bit different than putting two interfaces in one interface (every interface has IUnknown in it).
For an example, see the implementation of the StdComponentCategoriesMgr in dlls/comcat, which might be slightly unusual because there is just one static instance rather than potentially many dynamically created instances. The implementation is broken down like this:
comcat_private.h declaration of ComCatMgrImpl struct with three Vtbl pointers manager.c implementation of IUnknown, used by other interface impls too, and static ComCatMgrImpl instance, would normally be alloc'd and init'd information.c implementation of ICatInformation, partially forwards to IUnknown register.c implementation of ICatRegister, partially forwards to IUnknown
There are probably other examples, but that is one I'm familiar with.