[Libreoffice-commits] core.git: Branch 'distro/collabora/cp-6.2' - sw/source
Tor Lillqvist (via logerrit)
logerrit at kemper.freedesktop.org
Fri Sep 20 09:16:10 UTC 2019
sw/source/ui/vba/vbaapplication.cxx | 16 +++++++++++-----
1 file changed, 11 insertions(+), 5 deletions(-)
New commits:
commit e6cefbb2683bf6d2d0bb727c4691586e89c56e60
Author: Tor Lillqvist <tml at collabora.com>
AuthorDate: Wed Feb 6 12:32:35 2019 +0200
Commit: Tor Lillqvist <tml at collabora.com>
CommitDate: Fri Sep 20 11:15:09 2019 +0200
Ignore RuntimeException in Application.WindowState setter
Probably helps VB6 clients.
Change-Id: I3a1072e6ededbd0322c4b0dcd0ef4b16ace215d1
(cherry picked from commit e9f87f7b8e33352b66d52b37c459a52a6737eb80)
Reviewed-on: https://gerrit.libreoffice.org/79161
Reviewed-by: Tor Lillqvist <tml at collabora.com>
Tested-by: Tor Lillqvist <tml at collabora.com>
diff --git a/sw/source/ui/vba/vbaapplication.cxx b/sw/source/ui/vba/vbaapplication.cxx
index 73a0c5394ff8..5a4ff94896c1 100644
--- a/sw/source/ui/vba/vbaapplication.cxx
+++ b/sw/source/ui/vba/vbaapplication.cxx
@@ -291,12 +291,18 @@ sal_Int32 SAL_CALL SwVbaApplication::getWindowState()
void SAL_CALL SwVbaApplication::setWindowState( sal_Int32 _windowstate )
{
- auto xWindow = getActiveWindow();
- if (xWindow.is())
+ try
+ {
+ auto xWindow = getActiveWindow();
+ if (xWindow.is())
+ {
+ uno::Any aState;
+ aState <<= _windowstate;
+ xWindow->setWindowState( aState );
+ }
+ }
+ catch (const uno::RuntimeException&)
{
- uno::Any aState;
- aState <<= _windowstate;
- xWindow->setWindowState( aState );
}
}
More information about the Libreoffice-commits
mailing list