xref: /AOO41X/main/offapi/com/sun/star/document/MacroExecMode.idl (revision 34c958ab2597dc3f66146be0dc1758f0ba5d93f5)
1/**************************************************************
2 *
3 * Licensed to the Apache Software Foundation (ASF) under one
4 * or more contributor license agreements.  See the NOTICE file
5 * distributed with this work for additional information
6 * regarding copyright ownership.  The ASF licenses this file
7 * to you under the Apache License, Version 2.0 (the
8 * "License"); you may not use this file except in compliance
9 * with the License.  You may obtain a copy of the License at
10 *
11 *   http://www.apache.org/licenses/LICENSE-2.0
12 *
13 * Unless required by applicable law or agreed to in writing,
14 * software distributed under the License is distributed on an
15 * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
16 * KIND, either express or implied.  See the License for the
17 * specific language governing permissions and limitations
18 * under the License.
19 *
20 *************************************************************/
21
22
23
24#ifndef __com_sun_star_document_MacroExecMode_idl__
25#define __com_sun_star_document_MacroExecMode_idl__
26
27//=============================================================================
28
29module com { module sun { module star { module document {
30
31//=============================================================================
32/** Specify whether a macro can be executed.
33
34    @since OpenOffice 1.1.2
35*/
36published constants MacroExecMode
37{
38    //-------------------------------------------------------------------------
39    /** A macro should not be executed at all.
40    */
41
42    const short NEVER_EXECUTE = 0;
43
44    //-------------------------------------------------------------------------
45    /** Execute macros from secure list quietly.
46
47        <p>
48        If a macro is not in the list a conformation for it executing will
49        appear.
50        </p>
51    */
52
53    const short FROM_LIST = 1;
54
55    //-------------------------------------------------------------------------
56    /** Execute any macro, macros signed with trusted sertificates and macros
57        from secure list are executed quietly.
58
59        <p>
60            If the macro is neither in secure list nor signed a conformation
61            will be requested.
62        </p>
63    */
64
65    const short ALWAYS_EXECUTE = 2;
66
67    //-------------------------------------------------------------------------
68    /** Use configuration to retrieve macro settings. In case a user
69        confirmation is required a dialog is output.
70    */
71
72    const short USE_CONFIG = 3;
73
74
75    //-------------------------------------------------------------------------
76    /** A macro should be executed always no conformation should be provided.
77    */
78
79    const short ALWAYS_EXECUTE_NO_WARN = 4;
80
81    //-------------------------------------------------------------------------
82    /** Use configuration to retrieve macro settings. Treat cases when user
83        confirmation required as rejected.
84    */
85
86    const short USE_CONFIG_REJECT_CONFIRMATION = 5;
87
88    //-------------------------------------------------------------------------
89    /** Use configuration to retrieve macro settings. Treat cases when user
90        confirmation required as approved.
91    */
92
93    const short USE_CONFIG_APPROVE_CONFIRMATION = 6;
94
95    //-------------------------------------------------------------------------
96    /** Execute only macros from secure list. Macros that are not from the list
97        are not executed.
98    */
99    const short FROM_LIST_NO_WARN = 7;
100
101    //-------------------------------------------------------------------------
102    /** Execute only macros from secure list or macros that are signed by
103        trusted certificates.
104
105        <p> If the macro is neither in secure list nor signed it will not be
106            executed.
107        </p>
108
109        <p> If the macro is signed with unknown certificate a warning will
110            appear. The macro either will not be executed or if the warning
111            allows conformation, it will be executed after user agrees.
112        </p>
113    */
114    const short FROM_LIST_AND_SIGNED_WARN = 8;
115
116    //-------------------------------------------------------------------------
117    /** Execute only macros from secure list or macros that are signed by
118        trusted certificates. No warning/conformation should be shown.
119    */
120    const short FROM_LIST_AND_SIGNED_NO_WARN = 9;
121
122};
123
124//=============================================================================
125
126}; }; }; };
127
128#endif
129