LibreOffice Module sfx2 (master) 1
appbaslib.hxx
Go to the documentation of this file.
1/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
2/*
3 * This file is part of the LibreOffice project.
4 *
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/.
8 *
9 * This file incorporates work covered by the following license notice:
10 *
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 .
18 */
19
20#ifndef INCLUDED_SFX2_SOURCE_INC_APPBASLIB_HXX
21#define INCLUDED_SFX2_SOURCE_INC_APPBASLIB_HXX
22
23#include <svl/lstner.hxx>
24
25#include <com/sun/star/script/XStorageBasedLibraryContainer.hpp>
26#include <com/sun/star/embed/XStorage.hpp>
27#include <vector>
28
29class BasicManager;
30
34 : public SfxListener
35{
36private:
38 css::uno::Reference< css::script::XStorageBasedLibraryContainer >
40 css::uno::Reference< css::script::XStorageBasedLibraryContainer >
42
43public:
45
47 {
49 };
50
54 bool isValid() const { return mpBasicManager != nullptr; }
55
59 get() const { return mpBasicManager; }
60
63 void reset( BasicManager* _pBasicManager );
64
65 css::script::XLibraryContainer *
67
70 void storeAllLibraries();
71
74 void setStorage(
75 const css::uno::Reference< css::embed::XStorage >& _rxStorage
76 );
77
81 const css::uno::Reference< css::embed::XStorage >& _rxStorage
82 );
83
84
88 bool ImgVersion12PsswdBinaryLimitExceeded( std::vector< OUString >& sModules );
89
90 virtual void Notify(SfxBroadcaster& rBC, SfxHint const& rHint) override;
91
92private:
94};
95
96#endif // INCLUDED_SFX2_SOURCE_INC_APPBASLIB_HXX
97
98/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
helper class which holds and manipulates a BasicManager
Definition: appbaslib.hxx:35
bool isValid() const
returns <TRUE> if and only if the instance is currently bound to a non-<NULL> BasicManager.
Definition: appbaslib.hxx:54
void storeAllLibraries()
calls the storeLibraries at both our script and basic library container
Definition: appbaslib.cxx:83
void reset(BasicManager *_pBasicManager)
binds the instance to the given BasicManager
Definition: appbaslib.cxx:53
css::uno::Reference< css::script::XStorageBasedLibraryContainer > mxBasicContainer
Definition: appbaslib.hxx:39
BasicManager * get() const
returns the BasicManager which this instance is currently bound to
Definition: appbaslib.hxx:59
void setStorage(const css::uno::Reference< css::embed::XStorage > &_rxStorage)
calls the setStorage at all our XStorageBasedLibraryContainer.
Definition: appbaslib.cxx:101
css::uno::Reference< css::script::XStorageBasedLibraryContainer > mxDialogContainer
Definition: appbaslib.hxx:41
void storeLibrariesToStorage(const css::uno::Reference< css::embed::XStorage > &_rxStorage)
calls the storeLibrariesToStorage at all our XStorageBasedLibraryContainer.
Definition: appbaslib.cxx:120
virtual void Notify(SfxBroadcaster &rBC, SfxHint const &rHint) override
Definition: appbaslib.cxx:41
css::script::XLibraryContainer * getLibraryContainer(ContainerType _eType)
Definition: appbaslib.cxx:134
BasicManager * mpBasicManager
Definition: appbaslib.hxx:37
bool ImgVersion12PsswdBinaryLimitExceeded(std::vector< OUString > &sModules)
checks if any modules in the SfxLibraryContainer exceed the binary limits.
Definition: appbaslib.cxx:153