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 .
22 #include <com/sun/star/lang/XInitialization.hpp>
23 #include <com/sun/star/drawing/framework/XResourceFactory.hpp>
24 #include <comphelper/compbase.hxx>
25 #include <rtl/ref.hxx>
27 namespace com::sun::star::frame
{ class XController
; }
28 namespace com::sun::star::drawing::framework
{ class XResourceId
; }
29 namespace com::sun::star::drawing::framework
{ class XConfigurationController
; }
30 namespace sd
{ class DrawController
; }
32 namespace sd::framework
{
34 typedef comphelper::WeakComponentImplHelper
<
35 css::drawing::framework::XResourceFactory
,
36 css::lang::XEventListener
37 > BasicToolBarFactoryInterfaceBase
;
39 /** This factory provides some of the frequently used tool bars:
40 private:resource/toolbar/ViewTabBar
42 class BasicToolBarFactory final
43 : public BasicToolBarFactoryInterfaceBase
46 BasicToolBarFactory (const rtl::Reference
<::sd::DrawController
>& rxController
);
47 virtual ~BasicToolBarFactory() override
;
49 virtual void disposing(std::unique_lock
<std::mutex
>&) override
;
53 virtual css::uno::Reference
<css::drawing::framework::XResource
> SAL_CALL
55 const css::uno::Reference
<
56 css::drawing::framework::XResourceId
>& rxToolBarId
) override
;
60 const css::uno::Reference
<css::drawing::framework::XResource
>&
63 // lang::XEventListener
65 virtual void SAL_CALL
disposing (
66 const css::lang::EventObject
& rEventObject
) override
;
69 css::uno::Reference
<css::drawing::framework::XConfigurationController
> mxConfigurationController
;
70 rtl::Reference
<::sd::DrawController
> mxController
;
74 /// @throws css::lang::DisposedException
75 void ThrowIfDisposed() const;
78 } // end of namespace sd::framework
80 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */