Owen Rudge : mapi32: Add stub of Extended MAPI wrapper for MAPISendMail.
Module: wine Branch: master Commit: c528e9e8dc50dd4e1d1c8ddf5976da17dc4b45f6 URL: http://source.winehq.org/git/wine.git/?a=commit;h=c528e9e8dc50dd4e1d1c8ddf59... Author: Owen Rudge <orudge(a)codeweavers.com> Date: Thu Oct 1 14:10:50 2009 +0100 mapi32: Add stub of Extended MAPI wrapper for MAPISendMail. --- dlls/mapi32/sendmail.c | 18 ++++++++++++++++-- 1 files changed, 16 insertions(+), 2 deletions(-) diff --git a/dlls/mapi32/sendmail.c b/dlls/mapi32/sendmail.c index 5054be8..d98f8bf 100644 --- a/dlls/mapi32/sendmail.c +++ b/dlls/mapi32/sendmail.c @@ -38,6 +38,19 @@ WINE_DEFAULT_DEBUG_CHANNEL(mapi); +/* + Internal function to send a message via Extended MAPI. Wrapper around the Simple + MAPI function MAPISendMail. +*/ +static ULONG sendmail_extended_mapi(LHANDLE mapi_session, ULONG_PTR uiparam, lpMapiMessage message, + FLAGS flags, ULONG reserved) +{ + TRACE("Using Extended MAPI wrapper for MAPISendMail\n"); + + MAPIUninitialize(); + return MAPI_E_FAILURE; +} + /************************************************************************** * MAPISendMail (MAPI32.211) * @@ -80,8 +93,9 @@ ULONG WINAPI MAPISendMail( LHANDLE session, ULONG_PTR uiparam, if (mapiFunctions.MAPISendMail) return mapiFunctions.MAPISendMail(session, uiparam, message, flags, reserved); - /* TODO: Check if we have an Extended MAPI provider, if so, implement - wrapper around that. */ + /* Check if we have an Extended MAPI provider - if so, use our wrapper */ + if (MAPIInitialize(NULL) == S_OK) + return sendmail_extended_mapi(session, uiparam, message, flags, reserved); /* Fall back on our own implementation */ if (!message) return MAPI_E_FAILURE;
participants (1)
-
Alexandre Julliard