1 /* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
3 * This file is part of the LibreOffice project.
5 * This Source Code Form is subject to the terms of the Mozilla Public
6 * License, v. 2.0. If a copy of the MPL was not distributed with this
7 * file, You can obtain one at http://mozilla.org/MPL/2.0/.
9 * This file incorporates work covered by the following license notice:
11 * Licensed to the Apache Software Foundation (ASF) under one or more
12 * contributor license agreements. See the NOTICE file distributed
13 * with this work for additional information regarding copyright
14 * ownership. The ASF licenses this file to you under the Apache
15 * License, Version 2.0 (the "License"); you may not use this file
16 * except in compliance with the License. You may obtain a copy of
17 * the License at http://www.apache.org/licenses/LICENSE-2.0 .
20 #ifndef INCLUDED_SDEXT_SOURCE_MINIMIZER_PPPOPTIMIZER_HXX
21 #define INCLUDED_SDEXT_SOURCE_MINIMIZER_PPPOPTIMIZER_HXX
23 #include <cppuhelper/implbase2.hxx>
24 #include <com/sun/star/frame/XDispatch.hpp>
25 #include <com/sun/star/frame/XDispatchProvider.hpp>
26 #include <com/sun/star/lang/XMultiComponentFactory.hpp>
27 #include <com/sun/star/uno/XComponentContext.hpp>
28 #include <com/sun/star/frame/XController.hpp>
34 class PPPOptimizer
: public cppu::WeakImplHelper2
<
35 css::frame::XDispatchProvider
,
36 css::frame::XDispatch
>
38 css::uno::Reference
< css::uno::XComponentContext
> mxContext
;
39 css::uno::Reference
< css::frame::XController
> mxController
;
44 css::uno::Reference
<css::uno::XComponentContext
> const & xContext
,
45 css::uno::Reference
< css::frame::XFrame
> const & xFrame
);
46 virtual ~PPPOptimizer();
49 virtual css::uno::Reference
< css::frame::XDispatch
> SAL_CALL
queryDispatch(
50 const css::util::URL
& aURL
, const OUString
& aTargetFrameName
, sal_Int32 nSearchFlags
)
51 throw(css::uno::RuntimeException
, std::exception
) SAL_OVERRIDE
;
53 virtual css::uno::Sequence
< css::uno::Reference
< css::frame::XDispatch
> > SAL_CALL
queryDispatches(
54 const css::uno::Sequence
< css::frame::DispatchDescriptor
>& aDescripts
) throw( css::uno::RuntimeException
, std::exception
) SAL_OVERRIDE
;
57 virtual void SAL_CALL
dispatch( const css::util::URL
& aURL
,
58 const css::uno::Sequence
< css::beans::PropertyValue
>& lArguments
)
59 throw( css::uno::RuntimeException
, std::exception
) SAL_OVERRIDE
;
61 virtual void SAL_CALL
addStatusListener( const css::uno::Reference
< css::frame::XStatusListener
>& xListener
,
62 const css::util::URL
& aURL
)
63 throw( css::uno::RuntimeException
, std::exception
) SAL_OVERRIDE
;
64 virtual void SAL_CALL
removeStatusListener( const css::uno::Reference
< css::frame::XStatusListener
>& xListener
,
65 const css::util::URL
& aURL
)
66 throw( css::uno::RuntimeException
, std::exception
) SAL_OVERRIDE
;
68 static sal_Int64
GetFileSize( const OUString
& rURL
);
71 #endif // INCLUDED_SDEXT_SOURCE_MINIMIZER_PPPOPTIMIZER_HXX
73 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */