diff options
author | Tor Lillqvist <tml@collabora.com> | 2019-02-13 14:41:46 +0200 |
---|---|---|
committer | Tor Lillqvist <tml@collabora.com> | 2019-09-20 11:16:38 +0200 |
commit | 0b059abfaa27c55af789e13d73f7046f752c4636 (patch) | |
tree | 438fbc6fa3b5bbc48b4d46fa808b9c16f2fb4dda | |
parent | 3a58f51767b409a9807aed582e5c00fbac43d6de (diff) |
Interpret the parameter of WordBasic.FileClose() more correctly
In particular, the value 2 means "do not save".
Change-Id: I9788d201f8ecfcc016a12aa2088552ee994e1c17
(cherry picked from commit fb797eb41bf9b26261c4d9fe7a38ba635b80a20c)
Reviewed-on: https://gerrit.libreoffice.org/79164
Reviewed-by: Tor Lillqvist <tml@collabora.com>
Tested-by: Tor Lillqvist <tml@collabora.com>
-rw-r--r-- | sw/source/ui/vba/vbaapplication.cxx | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/sw/source/ui/vba/vbaapplication.cxx b/sw/source/ui/vba/vbaapplication.cxx index 133a83b0ce1b..033b2cdb4432 100644 --- a/sw/source/ui/vba/vbaapplication.cxx +++ b/sw/source/ui/vba/vbaapplication.cxx @@ -557,8 +557,8 @@ SwWordBasic::FileClose( const css::uno::Any& Save ) { uno::Reference< frame::XModel > xModel( mpApp->getCurrentDocument(), uno::UNO_SET_THROW ); - bool bSave = false; - if (Save.hasValue() && (Save >>= bSave) && bSave) + sal_Int16 nSave = false; + if (Save.hasValue() && (Save >>= nSave) && (nSave == 0 || nSave == 1)) FileSave(); // FIXME: Here I would much prefer to call VbaDocumentBase::Close() but not sure how to get at |