diff options
Diffstat (limited to 'uui/source/interactionhandler.cxx')
-rw-r--r-- | uui/source/interactionhandler.cxx | 64 |
1 files changed, 60 insertions, 4 deletions
diff --git a/uui/source/interactionhandler.cxx b/uui/source/interactionhandler.cxx index dd71174e408a..872bf5251f45 100644 --- a/uui/source/interactionhandler.cxx +++ b/uui/source/interactionhandler.cxx @@ -17,14 +17,68 @@ * the License at http://www.apache.org/licenses/LICENSE-2.0 . */ -#include "iahndl.hxx" -#include "interactionhandler.hxx" -#include "comphelper/namedvaluecollection.hxx" +#include <com/sun/star/awt/XWindow.hpp> +#include <com/sun/star/lang/XInitialization.hpp> +#include <com/sun/star/lang/XServiceInfo.hpp> +#include <com/sun/star/task/XInteractionHandler2.hpp> + +#include <iahndl.hxx> +#include <comphelper/namedvaluecollection.hxx> +#include <cppuhelper/implbase3.hxx> #include <cppuhelper/supportsservice.hxx> -#include "com/sun/star/awt/XWindow.hpp" using namespace com::sun::star; +namespace { + +class UUIInteractionHandler: + public cppu::WeakImplHelper3< com::sun::star::lang::XServiceInfo, + com::sun::star::lang::XInitialization, + com::sun::star::task::XInteractionHandler2 > +{ +private: + UUIInteractionHelper * m_pImpl; + + UUIInteractionHandler(UUIInteractionHandler &); // not implemented + void operator =(UUIInteractionHandler); // not implemented + +public: + UUIInteractionHandler(com::sun::star::uno::Reference< + com::sun::star::uno::XComponentContext > + const & rxContext) + SAL_THROW(()); + + virtual ~UUIInteractionHandler() SAL_THROW(()); + + virtual OUString SAL_CALL getImplementationName() + throw (com::sun::star::uno::RuntimeException); + + virtual sal_Bool SAL_CALL supportsService(OUString const & + rServiceName) + throw (com::sun::star::uno::RuntimeException); + + virtual com::sun::star::uno::Sequence< OUString > SAL_CALL + getSupportedServiceNames() + throw (com::sun::star::uno::RuntimeException); + + virtual void SAL_CALL + initialize( + com::sun::star::uno::Sequence< com::sun::star::uno::Any > const & + rArguments) + throw (com::sun::star::uno::Exception); + + virtual void SAL_CALL + handle(com::sun::star::uno::Reference< + com::sun::star::task::XInteractionRequest > const & + rRequest) + throw (com::sun::star::uno::RuntimeException); + + virtual ::sal_Bool SAL_CALL + handleInteractionRequest( + const ::com::sun::star::uno::Reference< ::com::sun::star::task::XInteractionRequest >& _Request + ) throw ( ::com::sun::star::uno::RuntimeException ); +}; + UUIInteractionHandler::UUIInteractionHandler( uno::Reference< uno::XComponentContext > const & rxContext) @@ -124,6 +178,8 @@ UUIInteractionHandler::handle( } } +} + extern "C" SAL_DLLPUBLIC_EXPORT css::uno::XInterface * SAL_CALL com_sun_star_comp_uui_UUIInteractionHandler_get_implementation( css::uno::XComponentContext *context, |