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/.
10 #define _XLTOOLBAR_HXX
12 #include <filter/msfilter/mstoolbar.hxx>
15 // hmm I don't normally use these packed structures
16 // but.. hey always good to do something different
17 class TBCCmd
: public TBBase
20 TBCCmd() : cmdID(0), A(0), B(0), cmdType(0), C(0), reserved3(0) {}
26 sal_uInt16 reserved3
:8;
27 bool Read( SvStream
& rS
);
31 class ScTBC
: public TBBase
34 boost::shared_ptr
<TBCCmd
> tbcCmd
; // optional
35 boost::shared_ptr
<TBCData
> tbcd
;
40 bool Read(SvStream
&rS
);
41 bool ImportToolBarControl( ScCTBWrapper
&, const com::sun::star::uno::Reference
< com::sun::star::container::XIndexContainer
>& toolbarcontainer
, CustomToolBarImportHelper
& helper
, bool bIsMenuBar
);
44 class ScCTB
: public TBBase
48 std::vector
<TBVisualData
> rVisualData
;
50 std::vector
< ScTBC
> rTBC
;
51 bool ImportCustomToolBar_Impl( ScCTBWrapper
&, CustomToolBarImportHelper
& );
56 bool Read(SvStream
&rS
);
58 bool ImportCustomToolBar( ScCTBWrapper
&, CustomToolBarImportHelper
& );
59 bool ImportMenuTB( ScCTBWrapper
&, const css::uno::Reference
< css::container::XIndexContainer
>&, CustomToolBarImportHelper
& );
60 OUString
GetName() { return tb
.getName().getString(); }
65 class CTBS
: public TBBase
77 CTBS
& operator = ( const CTBS
&);
81 bool Read(SvStream
&rS
);
84 class ScCTBWrapper
: public TBBase
88 std::vector
< ScCTB
> rCTB
;
93 bool Read(SvStream
&rS
);
95 bool ImportCustomToolBar( SfxObjectShell
& rDocSh
);
96 ScCTB
* GetCustomizationData( const OUString
& name
);
100 #endif //_XLTOOLBAR_HXX
102 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */