diff options
author | Mike Kaganski <mike.kaganski@collabora.com> | 2018-02-28 03:00:19 +0300 |
---|---|---|
committer | Mike Kaganski <mike.kaganski@collabora.com> | 2018-02-28 06:00:05 +0100 |
commit | 5874c76371562c3e2d8564b1fb04df1997091d27 (patch) | |
tree | 35f690d99979ba52593791e23fde8a1baf91ba41 /shell | |
parent | c2f7759e85f3e5cc9f56aaf03eefa0f1ba834734 (diff) |
tdf#116074: Use modeless dialogs with supporting mailers
When sending mail using MS Outlook, our UI gets locked until user
closes the Outlook's compose message window.
This patch uses Outlook 2013+ option to show modeless window.
Change-Id: Ib99b4440cd20a8bff0c7cd96838b31a2d14bd804
Reviewed-on: https://gerrit.libreoffice.org/50476
Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com>
Tested-by: Mike Kaganski <mike.kaganski@collabora.com>
Diffstat (limited to 'shell')
-rw-r--r-- | shell/source/win32/simplemail/senddoc.cxx | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/shell/source/win32/simplemail/senddoc.cxx b/shell/source/win32/simplemail/senddoc.cxx index f3fe6112b4eb..0e1d0859bcc2 100644 --- a/shell/source/win32/simplemail/senddoc.cxx +++ b/shell/source/win32/simplemail/senddoc.cxx @@ -119,6 +119,9 @@ void initAttachmentList(MapiAttachmentList_t* pMapiAttachmentList) MapiFileDescW mfd; ZeroMemory(&mfd, sizeof(mfd)); mfd.lpszPathName = const_cast<wchar_t*>(attachment.c_str()); + // This is required for Outlook 2013 - otherwise using MAPI_DIALOG_MODELESS results in MAPI_E_FAILURE + // See http://peach.ease.lsoft.com/scripts/wa-PEACH.exe?A2=MAPI-L;d2bf3060.1604 + mfd.lpszFileName = L""; mfd.nPosition = sal::static_int_cast<ULONG>(-1); pMapiAttachmentList->push_back(mfd); } @@ -190,7 +193,8 @@ void initParameter(int argc, wchar_t* argv[]) if (_wcsicmp(argv[i], L"--mapi-dialog") == 0) { - gMapiFlags |= MAPI_DIALOG; + // Outlook 2013+; for earlier versions this equals to MAPI_DIALOG + gMapiFlags |= MAPI_DIALOG_MODELESS; } else if (_wcsicmp(argv[i], L"--mapi-logon-ui") == 0) { |