summaryrefslogtreecommitdiff
path: root/cui/source/dialogs/scriptdlg.cxx
diff options
context:
space:
mode:
authorNoel Grandin <noel.grandin@collabora.co.uk>2019-03-01 14:42:38 +0200
committerNoel Grandin <noel.grandin@collabora.co.uk>2019-03-07 07:12:39 +0100
commit8b5e23eac31cafbd442a3acab5fbcf98bfd0af11 (patch)
treed41feeea533127280e0503d0dc2dd55a4ab83ce8 /cui/source/dialogs/scriptdlg.cxx
parent4f810905fa74128871f2fe924a3d28a79f4e4261 (diff)
log nice exception messages whereever possible
Change-Id: Idd125c18bee1a39b9ea8cc4f8c55cddfd37c33e1 Reviewed-on: https://gerrit.libreoffice.org/68579 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'cui/source/dialogs/scriptdlg.cxx')
-rw-r--r--cui/source/dialogs/scriptdlg.cxx21
1 files changed, 13 insertions, 8 deletions
diff --git a/cui/source/dialogs/scriptdlg.cxx b/cui/source/dialogs/scriptdlg.cxx
index 83724a28d461..2de38a07edc4 100644
--- a/cui/source/dialogs/scriptdlg.cxx
+++ b/cui/source/dialogs/scriptdlg.cxx
@@ -55,6 +55,7 @@
#include <svtools/imagemgr.hxx>
#include <vcl/treelistentry.hxx>
#include <tools/urlobj.hxx>
+#include <tools/diagnose_ex.h>
#include <vector>
#include <algorithm>
@@ -659,9 +660,10 @@ IMPL_LINK(SvxScriptOrgDialog, ButtonHdl, weld::Button&, rButton, void)
// ISSUE need code to run script here
xInv->invoke( "Editable", args, outIndex, outArgs );
}
- catch( Exception& e )
+ catch( Exception const & )
{
- SAL_WARN("cui.dialogs", "Caught exception trying to invoke " << e );
+ css::uno::Any ex( cppu::getCaughtException() );
+ SAL_WARN("cui.dialogs", "Caught exception trying to invoke " << exceptionToString(ex) );
}
}
}
@@ -828,9 +830,10 @@ void SvxScriptOrgDialog::createEntry(weld::TreeIter& rEntry)
aChildNode = newNode;
}
- catch( Exception& e )
+ catch( Exception const & )
{
- SAL_WARN("cui.dialogs", "Caught exception trying to Create " << e );
+ css::uno::Any ex( cppu::getCaughtException() );
+ SAL_WARN("cui.dialogs", "Caught exception trying to Create " << exceptionToString(ex) );
}
}
if ( aChildNode.is() )
@@ -912,9 +915,10 @@ void SvxScriptOrgDialog::renameEntry(weld::TreeIter& rEntry)
aChildNode = newNode;
}
- catch( Exception& e )
+ catch( Exception const & )
{
- SAL_WARN("cui.dialogs", "Caught exception trying to Rename " << e );
+ css::uno::Any ex( cppu::getCaughtException() );
+ SAL_WARN("cui.dialogs", "Caught exception trying to Rename " << exceptionToString(ex) );
}
}
if ( aChildNode.is() )
@@ -961,9 +965,10 @@ void SvxScriptOrgDialog::deleteEntry(weld::TreeIter& rEntry)
aResult = xInv->invoke( "Deletable", args, outIndex, outArgs );
aResult >>= result; // or do we just assume true if no exception ?
}
- catch( Exception& e )
+ catch( Exception const & )
{
- SAL_WARN("cui.dialogs", "Caught exception trying to delete " << e );
+ css::uno::Any ex( cppu::getCaughtException() );
+ SAL_WARN("cui.dialogs", "Caught exception trying to delete " << exceptionToString(ex) );
}
}