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 .
21 #include <MutexContainer.hxx>
22 #include <OPropertySet.hxx>
23 #include <cppuhelper/implbase.hxx>
24 #include <comphelper/uno3.hxx>
26 #include <com/sun/star/lang/XServiceInfo.hpp>
27 #include <com/sun/star/chart2/XAxis.hpp>
28 #include <com/sun/star/chart2/XTitled.hpp>
29 #include <com/sun/star/util/XCloneable.hpp>
30 #include <com/sun/star/util/XModifyBroadcaster.hpp>
31 #include <com/sun/star/util/XModifyListener.hpp>
38 typedef ::cppu::WeakImplHelper
<
41 css::lang::XServiceInfo
,
42 css::util::XCloneable
,
43 css::util::XModifyBroadcaster
,
44 css::util::XModifyListener
>
49 public MutexContainer
,
50 public impl::Axis_Base
,
51 public ::property::OPropertySet
55 virtual ~Axis() override
;
57 /// XServiceInfo declarations
58 virtual OUString SAL_CALL
getImplementationName() override
;
59 virtual sal_Bool SAL_CALL
supportsService( const OUString
& ServiceName
) override
;
60 virtual css::uno::Sequence
< OUString
> SAL_CALL
getSupportedServiceNames() override
;
62 /// merge XInterface implementations
64 /// merge XTypeProvider implementations
65 DECLARE_XTYPEPROVIDER()
68 explicit Axis( const Axis
& rOther
);
70 // late initialization to call after copy-constructing
73 // ____ OPropertySet ____
74 virtual css::uno::Any
GetDefaultValue( sal_Int32 nHandle
) const override
;
76 // ____ OPropertySet ____
77 virtual ::cppu::IPropertyArrayHelper
& SAL_CALL
getInfoHelper() override
;
79 // ____ XPropertySet ____
80 virtual css::uno::Reference
< css::beans::XPropertySetInfo
> SAL_CALL
81 getPropertySetInfo() override
;
84 virtual void SAL_CALL
setScaleData( const css::chart2::ScaleData
& rScaleData
) override
;
85 virtual css::chart2::ScaleData SAL_CALL
getScaleData() override
;
86 virtual css::uno::Reference
< css::beans::XPropertySet
> SAL_CALL
getGridProperties() override
;
87 virtual css::uno::Sequence
< css::uno::Reference
< css::beans::XPropertySet
> > SAL_CALL
getSubGridProperties() override
;
88 virtual css::uno::Sequence
< css::uno::Reference
< css::beans::XPropertySet
> > SAL_CALL
getSubTickProperties() override
;
91 virtual css::uno::Reference
< css::chart2::XTitle
> SAL_CALL
getTitleObject() override
;
92 virtual void SAL_CALL
setTitleObject(
93 const css::uno::Reference
< css::chart2::XTitle
>& Title
) override
;
95 // ____ XCloneable ____
96 // Note: the coordinate systems are not cloned!
97 virtual css::uno::Reference
< css::util::XCloneable
> SAL_CALL
createClone() override
;
99 // ____ XModifyBroadcaster ____
100 virtual void SAL_CALL
addModifyListener(
101 const css::uno::Reference
< css::util::XModifyListener
>& aListener
) override
;
102 virtual void SAL_CALL
removeModifyListener(
103 const css::uno::Reference
< css::util::XModifyListener
>& aListener
) override
;
105 // ____ XModifyListener ____
106 virtual void SAL_CALL
modified(
107 const css::lang::EventObject
& aEvent
) override
;
109 // ____ XEventListener (base of XModifyListener) ____
110 virtual void SAL_CALL
disposing(
111 const css::lang::EventObject
& Source
) override
;
113 // ____ OPropertySet ____
114 virtual void firePropertyChangeEvent() override
;
115 using OPropertySet::disposing
;
117 void fireModifyEvent();
119 void AllocateSubGrids();
121 css::uno::Reference
< css::util::XModifyListener
> m_xModifyEventForwarder
;
123 css::chart2::ScaleData m_aScaleData
;
125 css::uno::Reference
< css::beans::XPropertySet
> m_xGrid
;
127 css::uno::Sequence
< css::uno::Reference
< css::beans::XPropertySet
> > m_aSubGridProperties
;
129 css::uno::Reference
< css::chart2::XTitle
> m_xTitle
;
134 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */