diff options
author | Thomas Arnhold <thomas@arnhold.org> | 2013-06-29 21:24:12 +0200 |
---|---|---|
committer | Thomas Arnhold <thomas@arnhold.org> | 2013-06-29 21:52:54 +0000 |
commit | ba0a57702cdef7a0389c06841711d7e3079d471c (patch) | |
tree | 223c0dd50de4b71cf7df9d0073f7cacca1f18c8d /extensions/source/ole | |
parent | 8a7ede404ca4980f169c4ce634805ea5c1b6b56e (diff) |
remove OUString wrap for string literals
For some functions and all kinds of Exceptions.
CannotConvertException
CloseVetoException
DisposedException
EmptyUndoStackException
ErrorCodeIOException
Exception
GridInvalidDataException
GridInvalidModelException
IOException
IllegalAccessException
IllegalArgumentException
IllegalTypeException
IndexOutOfBoundsException
NoMasterException
NoSuchElementException
NoSupportException
PropertyVetoException
RuntimeException
SAXException
ScannerException
StorageWrappedTargetException
UnsupportedFlavorException
VetoException
WrappedTargetException
ZipIOException
throwGenericSQLException
throwIllegallArgumentException
createInstance
createInstanceWithContext
forName
getByName
getPackageManager
getPropertyValue
getUnpackedValueOrDefault
getValueByName
hasPropertyByName
openKey
setName
setPropertyValue
supportsService
bash command:
for i in `cat list`; do git grep "$i\s*(\s*OUString(\s*\"" -- '*.[hc]xx'
| cut -d ':' -f1 | sort -u
| xargs sed -i
-e "s/\(\<$i\s*(\)\s*OUString(\s*\(\"[^\")\\]*\"\)\s*)\s*/\1\2/g"
-e "s/\($i.*\)\"+ /\1\" + /g";
done
Change-Id: Iaf8e641b0abf28c082906014f87a183517630535
Reviewed-on: https://gerrit.libreoffice.org/4624
Tested-by: LibreOffice gerrit bot <gerrit@libreoffice.org>
Reviewed-by: Thomas Arnhold <thomas@arnhold.org>
Tested-by: Thomas Arnhold <thomas@arnhold.org>
Diffstat (limited to 'extensions/source/ole')
-rw-r--r-- | extensions/source/ole/oleobjw.cxx | 22 |
1 files changed, 11 insertions, 11 deletions
diff --git a/extensions/source/ole/oleobjw.cxx b/extensions/source/ole/oleobjw.cxx index b3b7b525ed40..0ef5557213f8 100644 --- a/extensions/source/ole/oleobjw.cxx +++ b/extensions/source/ole/oleobjw.cxx @@ -405,15 +405,15 @@ void SAL_CALL IUnknownWrapper_Impl::setValue( const OUString& aPropertyName, throw RuntimeException(); break; case DISP_E_OVERFLOW: - throw CannotConvertException(OUString("call to OLE object failed"), static_cast<XInterface*>( + throw CannotConvertException("call to OLE object failed", static_cast<XInterface*>( static_cast<XWeak*>(this)), TypeClass_UNKNOWN, FailReason::OUT_OF_RANGE, uArgErr); break; case DISP_E_PARAMNOTFOUND: - throw IllegalArgumentException(OUString("call to OLE object failed"), static_cast<XInterface*>( + throw IllegalArgumentException("call to OLE object failed", static_cast<XInterface*>( static_cast<XWeak*>(this)), ::sal::static_int_cast< sal_Int16, unsigned int >( uArgErr )) ; break; case DISP_E_TYPEMISMATCH: - throw CannotConvertException(OUString("call to OLE object failed"), static_cast<XInterface*>( + throw CannotConvertException("call to OLE object failed", static_cast<XInterface*>( static_cast<XWeak*>(this)), TypeClass_UNKNOWN, FailReason::UNKNOWN, ::sal::static_int_cast< sal_Int16, unsigned int >( uArgErr )); break; case DISP_E_UNKNOWNINTERFACE: @@ -423,7 +423,7 @@ void SAL_CALL IUnknownWrapper_Impl::setValue( const OUString& aPropertyName, throw RuntimeException(); break; case DISP_E_PARAMNOTOPTIONAL: - throw CannotConvertException(OUString("call to OLE object failed"),static_cast<XInterface*>( + throw CannotConvertException("call to OLE object failed",static_cast<XInterface*>( static_cast<XWeak*>(this)) , TypeClass_UNKNOWN, FailReason::NO_DEFAULT_AVAILABLE, uArgErr); break; default: @@ -1174,7 +1174,7 @@ Any IUnknownWrapper_Impl::invokeWithDispIdUnoTlb(const OUString& sFunctionName, } if( !bConvRet) // conversion of return or out parameter failed - throw CannotConvertException( OUString("Call to COM object failed. Conversion of return or out value failed"), + throw CannotConvertException("Call to COM object failed. Conversion of return or out value failed", Reference<XInterface>( static_cast<XWeak*>(this), UNO_QUERY ), TypeClass_UNKNOWN, FailReason::UNKNOWN, 0);// lookup error code // conversion of return or out parameter failed @@ -1198,15 +1198,15 @@ Any IUnknownWrapper_Impl::invokeWithDispIdUnoTlb(const OUString& sFunctionName, throw IllegalArgumentException(); break; case DISP_E_OVERFLOW: - throw CannotConvertException(OUString("call to OLE object failed"), static_cast<XInterface*>( + throw CannotConvertException("call to OLE object failed", static_cast<XInterface*>( static_cast<XWeak*>(this)), TypeClass_UNKNOWN, FailReason::OUT_OF_RANGE, uArgErr); break; case DISP_E_PARAMNOTFOUND: - throw IllegalArgumentException(OUString("call to OLE object failed"), static_cast<XInterface*>( + throw IllegalArgumentException("call to OLE object failed", static_cast<XInterface*>( static_cast<XWeak*>(this)), ::sal::static_int_cast< sal_Int16, unsigned int >( uArgErr )); break; case DISP_E_TYPEMISMATCH: - throw CannotConvertException(OUString("call to OLE object failed"),static_cast<XInterface*>( + throw CannotConvertException("call to OLE object failed",static_cast<XInterface*>( static_cast<XWeak*>(this)) , TypeClass_UNKNOWN, FailReason::UNKNOWN, uArgErr); break; case DISP_E_UNKNOWNINTERFACE: @@ -1216,7 +1216,7 @@ Any IUnknownWrapper_Impl::invokeWithDispIdUnoTlb(const OUString& sFunctionName, throw RuntimeException() ; break; case DISP_E_PARAMNOTOPTIONAL: - throw CannotConvertException(OUString("call to OLE object failed"), static_cast<XInterface*>( + throw CannotConvertException("call to OLE object failed", static_cast<XInterface*>( static_cast<XWeak*>(this)), TypeClass_UNKNOWN, FailReason::NO_DEFAULT_AVAILABLE, uArgErr); break; default: @@ -1525,7 +1525,7 @@ uno::Any SAL_CALL IUnknownWrapper_Impl::directInvoke( const OUString& aName, con "returned DISP_E_NONAMEDARGS",0, ::sal::static_int_cast< sal_Int16, unsigned int >( uArgErr )); break; case DISP_E_OVERFLOW: - throw CannotConvertException(OUString("[automation bridge] Call failed."), + throw CannotConvertException("[automation bridge] Call failed.", static_cast<XInterface*>( static_cast<XWeak*>(this)), TypeClass_UNKNOWN, FailReason::OUT_OF_RANGE, uArgErr); break; @@ -2157,7 +2157,7 @@ Any IUnknownWrapper_Impl::invokeWithDispIdComTlb(FuncDesc& aFuncDesc, "returned DISP_E_NONAMEDARGS",0, ::sal::static_int_cast< sal_Int16, unsigned int >( uArgErr )); break; case DISP_E_OVERFLOW: - throw CannotConvertException(OUString("[automation bridge] Call failed."), + throw CannotConvertException("[automation bridge] Call failed.", static_cast<XInterface*>( static_cast<XWeak*>(this)), TypeClass_UNKNOWN, FailReason::OUT_OF_RANGE, uArgErr); break; |