LanguageTool: don't crash if REST protocol isn't set
[LibreOffice.git] / forms / source / component / navigationbar.hxx
blobceb84dbe8ecd5fb74cef85b20aaa3e064a8041cc
1 /* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
2 /*
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 #pragma once
22 #include <FormComponent.hxx>
23 #include <comphelper/propertycontainerhelper.hxx>
24 #include <cppuhelper/implbase1.hxx>
25 #include <formcontrolfont.hxx>
28 using namespace comphelper;
30 namespace frm
33 typedef ::cppu::ImplHelper1 < css::awt::XControlModel
34 > ONavigationBarModel_BASE;
36 class ONavigationBarModel
37 :public OControlModel
38 ,public FontControlModel
39 ,public OPropertyContainerHelper
40 ,public ONavigationBarModel_BASE
42 // <properties>
43 css::uno::Any m_aTabStop;
44 css::uno::Any m_aBackgroundColor;
45 OUString m_sDefaultControl;
46 OUString m_sHelpText;
47 OUString m_sHelpURL;
48 sal_Int16 m_nIconSize;
49 sal_Int16 m_nBorder;
50 sal_Int32 m_nDelay;
51 bool m_bEnabled;
52 bool m_bEnableVisible;
53 bool m_bShowPosition;
54 bool m_bShowNavigation;
55 bool m_bShowActions;
56 bool m_bShowFilterSort;
57 sal_Int16 m_nWritingMode;
58 sal_Int16 m_nContextWritingMode;
59 // </properties>
61 public:
62 ONavigationBarModel(
63 const css::uno::Reference< css::uno::XComponentContext>& _rxFactory
65 ONavigationBarModel(
66 const ONavigationBarModel* _pOriginal,
67 const css::uno::Reference< css::uno::XComponentContext>& _rxFactory
69 virtual ~ONavigationBarModel() override;
71 // UNO
72 DECLARE_UNO3_AGG_DEFAULTS( ONavigationBarModel, OControlModel )
73 virtual css::uno::Any SAL_CALL queryAggregation( const css::uno::Type& _rType ) override;
75 // XServiceInfo
76 virtual OUString SAL_CALL getImplementationName() override;
77 virtual css::uno::Sequence< OUString > SAL_CALL getSupportedServiceNames() override;
79 // XTypeProvider
80 DECLARE_XTYPEPROVIDER()
82 // XPersistObject
83 virtual OUString SAL_CALL getServiceName() override;
84 virtual void SAL_CALL write(const css::uno::Reference< css::io::XObjectOutputStream>& _rxOutStream) override;
85 virtual void SAL_CALL read(const css::uno::Reference< css::io::XObjectInputStream>& _rxInStream) override;
87 // XPropertySet
88 virtual void SAL_CALL getFastPropertyValue(css::uno::Any& rValue, sal_Int32 nHandle ) const override;
89 virtual sal_Bool SAL_CALL convertFastPropertyValue(css::uno::Any& rConvertedValue, css::uno::Any& rOldValue,
90 sal_Int32 nHandle, const css::uno::Any& rValue ) override;
91 virtual void SAL_CALL setFastPropertyValue_NoBroadcast(sal_Int32 nHandle, const css::uno::Any& rValue) override;
93 // XPropertyState
94 virtual css::uno::Any getPropertyDefaultByHandle( sal_Int32 nHandle ) const override;
96 // OControlModel's property handling
97 virtual void describeFixedProperties(
98 css::uno::Sequence< css::beans::Property >& /* [out] */ _rProps
99 ) const override;
101 // prevent method hiding
102 using OControlModel::disposing;
103 using OControlModel::getFastPropertyValue;
105 protected:
106 virtual css::uno::Reference< css::util::XCloneable > SAL_CALL createClone( ) override;
108 private:
109 void implInitPropertyContainer();
113 } // namespace frm
116 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */