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 .
23 #include <tools/solar.h>
25 class SvMetaSlot
: public SvMetaAttribute
28 SvIdentifier aGroupId
;
29 SvIdentifier aExecMethod
;
30 SvIdentifier aStateMethod
;
37 SvBOOL aRecordPerItem
;// exclusive
40 SvBOOL aRecordAbsolute
;
43 SvBOOL aToolBoxConfig
;
47 OString aDisableFlags
;
48 SvMetaSlot
* pNextSlot
;
52 void WriteSlot( std::string_view rShellName
,
53 sal_uInt16 nCount
, std::string_view rSlotId
,
54 SvSlotElementList
&rList
,
56 SvIdlDataBase
& rBase
, SvStream
& rOutStm
);
58 bool IsVariable() const;
59 bool IsMethod() const;
61 void SetRecordPerItem( bool bSet
)
63 aRecordPerItem
= bSet
;
65 aRecordPerSet
= aNoRecord
= false;
67 void SetRecordPerSet( bool bSet
)
71 aRecordPerItem
= aNoRecord
= false;
73 void SetNoRecord( bool bSet
)
77 aRecordPerItem
= aRecordPerSet
= false;
82 SvMetaSlot( SvMetaType
* pType
);
84 const OString
& GetGroupId() const;
85 const OString
& GetExecMethod() const;
86 const OString
& GetStateMethod() const;
87 const OString
& GetDisableFlags() const;
88 bool GetToggle() const;
89 bool GetAutoUpdate() const;
91 bool GetAsynchron() const;
93 bool GetRecordPerItem() const;
94 bool GetRecordPerSet() const;
95 bool GetNoRecord() const;
96 bool GetRecordAbsolute() const;
98 bool GetMenuConfig() const;
99 bool GetToolBoxConfig() const;
100 bool GetAccelConfig() const;
101 bool GetFastCall() const;
102 bool GetContainer() const;
103 bool GetReadOnlyDoc() const;
105 sal_uInt32
GetListPos() const
107 void SetListPos(sal_uInt32 n
)
109 void ResetSlotPointer()
110 { pNextSlot
= nullptr; }
112 virtual bool Test( SvTokenStream
& rInStm
) override
;
113 virtual void ReadAttributesSvIdl( SvIdlDataBase
& rBase
,
114 SvTokenStream
& rInStm
) override
;
115 virtual bool ReadSvIdl( SvIdlDataBase
&, SvTokenStream
& rInStm
) override
;
116 virtual void Insert( SvSlotElementList
& ) override
;
117 void WriteSlotStubs( std::string_view rShellName
,
118 std::vector
<OString
> & rList
,
119 SvStream
& rOutStm
) const;
120 sal_uInt16
WriteSlotMap( std::string_view rShellName
,
124 SvIdlDataBase
& rBase
,
125 SvStream
& rOutStm
);
126 sal_uInt16
WriteSlotParamArray( SvIdlDataBase
& rBase
,
127 SvStream
& rOutStm
) const;
130 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */