diff options
Diffstat (limited to 'dbaccess/source/ui/misc/linkeddocuments.cxx')
-rw-r--r-- | dbaccess/source/ui/misc/linkeddocuments.cxx | 83 |
1 files changed, 9 insertions, 74 deletions
diff --git a/dbaccess/source/ui/misc/linkeddocuments.cxx b/dbaccess/source/ui/misc/linkeddocuments.cxx index 38c8f0c65c05..c8b8e6085d20 100644 --- a/dbaccess/source/ui/misc/linkeddocuments.cxx +++ b/dbaccess/source/ui/misc/linkeddocuments.cxx @@ -1,3 +1,4 @@ +/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */ /************************************************************************* * * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. @@ -28,107 +29,42 @@ // MARKER(update_precomp.py): autogen include statement, do not remove #include "precompiled_dbui.hxx" -#ifndef _DBAUI_LINKEDDOCUMENTS_HXX_ #include "linkeddocuments.hxx" -#endif -#ifndef _OSL_DIAGNOSE_H_ #include <osl/diagnose.h> -#endif #include <tools/diagnose_ex.h> #include <unotools/confignode.hxx> -#ifndef DBACCESS_SHARED_DBUSTRINGS_HRC #include "dbustrings.hrc" -#endif #include <comphelper/classids.hxx> -#ifndef COMPHELPER_NAMEDVALUECOLLECTION_HXX #include <comphelper/namedvaluecollection.hxx> -#endif -#ifndef _COM_SUN_STAR_LANG_XSINGLESERVICEFACTORY_HPP_ #include <com/sun/star/lang/XSingleServiceFactory.hpp> -#endif -#ifndef _COM_SUN_STAR_FRAME_XDISPATCHPROVIDER_HPP_ #include <com/sun/star/frame/XDispatchProvider.hpp> -#endif -#ifndef _COM_SUN_STAR_FRAME_XCOMPONENTLOADER_HPP_ #include <com/sun/star/frame/XComponentLoader.hpp> -#endif -#ifndef _COM_SUN_STAR_UTIL_URL_HPP_ #include <com/sun/star/util/URL.hpp> -#endif -#ifndef _COM_SUN_STAR_FRAME_FRAMESEARCHFLAG_HPP_ #include <com/sun/star/frame/FrameSearchFlag.hpp> -#endif -#ifndef _COM_SUN_STAR_CONTAINER_XNAMECONTAINER_HPP_ #include <com/sun/star/container/XNameContainer.hpp> -#endif -#ifndef _COM_SUN_STAR_UCB_XCOMMANDPROCESSOR_HPP_ #include <com/sun/star/ucb/XCommandProcessor.hpp> -#endif -#ifndef _COM_SUN_STAR_UCB_OPENCOMMANDARGUMENT_HPP_ #include <com/sun/star/ucb/OpenCommandArgument.hpp> -#endif -#ifndef _COM_SUN_STAR_UCB_OPENMODE_HPP_ #include <com/sun/star/ucb/OpenMode.hpp> -#endif -#ifndef _COM_SUN_STAR_TASK_XJOBEXECUTOR_HPP_ #include <com/sun/star/task/XJobExecutor.hpp> -#endif -#ifndef _COMPHELPER_EXTRACT_HXX_ #include <comphelper/extract.hxx> -#endif -#ifndef _COMPHELPER_TYPES_HXX_ #include <comphelper/types.hxx> -#endif -#ifndef _SV_MSGBOX_HXX #include <vcl/msgbox.hxx> -#endif -#ifndef _UCBHELPER_CONTENT_HXX #include <ucbhelper/content.hxx> -#endif -#ifndef _DBU_MISC_HRC_ #include "dbu_misc.hrc" -#endif -#ifndef SVTOOLS_FILENOTATION_HXX_ #include <svl/filenotation.hxx> -#endif -#ifndef DBACCESS_UI_BROWSER_ID_HXX #include "browserids.hxx" -#endif -#ifndef _SFXNEW_HXX #include <sfx2/new.hxx> -#endif -#ifndef _SVTOOLS_TEMPLDLG_HXX -#include <svtools/templdlg.hxx> -#endif -#ifndef _DBAUI_MODULE_DBU_HXX_ #include "moduledbu.hxx" -#endif // ----------------- // for calling basic -#ifndef _SFXAPP_HXX #include <sfx2/app.hxx> -#endif -#ifndef _SBXCLASS_HXX #include <basic/sbx.hxx> -#endif -#ifndef _SB_SBUNO_HXX #include <basic/sbuno.hxx> -#endif -#ifndef _EHDL_HXX #include <svtools/ehdl.hxx> -#endif -#ifndef _SVX_DATACCESSDESCRIPTOR_HXX_ #include <svx/dataaccessdescriptor.hxx> -#endif -#ifndef _COM_SUN_STAR_CONTAINER_XHIERARCHICALNAMECONTAINER_HPP_ #include <com/sun/star/container/XHierarchicalNameContainer.hpp> -#endif -#ifndef _SV_WAITOBJ_HXX #include <vcl/waitobj.hxx> -#endif -#ifndef _COMPHELPER_MIMECONFIGHELPER_HXX_ #include <comphelper/mimeconfighelper.hxx> -#endif #include <cppuhelper/exc_hlp.hxx> #include <connectivity/dbtools.hxx> @@ -235,7 +171,7 @@ namespace dbaui break; default: - OSL_ENSURE( false, "OLinkedDocumentsAccess::implOpen: invalid open mode!" ); + OSL_FAIL( "OLinkedDocumentsAccess::implOpen: invalid open mode!" ); break; } aArguments.put( "OpenMode", sOpenMode ); @@ -253,9 +189,8 @@ namespace dbaui xRet = xComponentLoader->loadComponentFromURL( _rLinkName, ::rtl::OUString(), 0, aArguments.getPropertyValues() ); } - catch(Exception& e) + catch(const Exception&) { - (void)e; throw; } @@ -293,7 +228,7 @@ namespace dbaui xWizard->trigger( ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "start" ) ) ); ::comphelper::disposeComponent( xWizard ); } - catch(const Exception& e) + catch(const Exception&) { DBG_UNHANDLED_EXCEPTION(); } @@ -351,7 +286,7 @@ namespace dbaui break; default: - OSL_ENSURE( sal_False, "OLinkedDocumentsAccess::newDocument: please use newFormWithPilot!" ); + OSL_FAIL( "OLinkedDocumentsAccess::newDocument: please use newFormWithPilot!" ); return Reference< XComponent >(); } @@ -398,7 +333,7 @@ namespace dbaui xNewDocument.set( xContent->execute( aCommand, xContent->createCommandIdentifier(), NULL ), UNO_QUERY ); } } - catch(const Exception& ) + catch(const Exception&) { DBG_UNHANDLED_EXCEPTION(); } @@ -422,12 +357,11 @@ namespace dbaui com::sun::star::sdbc::SQLException aSQLException; aSQLException.Message = sMessage; - // aSQLException.Context = e.Context; aInfo = dbtools::SQLExceptionInfo(aSQLException); } return xRet; } - catch (com::sun::star::io::WrongFormatException e) + catch(const com::sun::star::io::WrongFormatException &e) { com::sun::star::sdbc::SQLException aSQLException; aSQLException.Message = e.Message; @@ -443,7 +377,7 @@ namespace dbaui sMessage.SearchAndReplaceAscii("$file$",_rLinkName); aInfo.prepend(sMessage); } - catch(Exception& e) + catch(const Exception& e) { Any aAny = ::cppu::getCaughtException(); com::sun::star::sdbc::SQLException a; @@ -474,3 +408,4 @@ namespace dbaui } // namespace dbaui //...................................................................... +/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ |