xref: /trunk/main/sc/inc/optutil.hxx (revision 38d50f7b)
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 SC_OPTUTIL_HXX
25 #define SC_OPTUTIL_HXX
26 
27 #include <unotools/configitem.hxx>
28 #include <tools/link.hxx>
29 #include "scdllapi.h"
30 
31 
32 class ScOptionsUtil
33 {
34 public:
35 	static sal_Bool		IsMetricSystem();
36 };
37 
38 
39 //	ConfigItem for classes that use items from several sub trees
40 
41 class SC_DLLPUBLIC ScLinkConfigItem : public utl::ConfigItem
42 {
43 	Link	aCommitLink;
44 
45 public:
46             ScLinkConfigItem( const rtl::OUString& rSubTree );
47             ScLinkConfigItem( const rtl::OUString& rSubTree, sal_Int16 nMode );
48 	void	SetCommitLink( const Link& rLink );
49 
50 	virtual void	Notify( const com::sun::star::uno::Sequence<rtl::OUString>& aPropertyNames );
51 	virtual void	Commit();
52 
SetModified()53 	void 	SetModified()	{ ConfigItem::SetModified(); }
54 	com::sun::star::uno::Sequence< com::sun::star::uno::Any>
GetProperties(const com::sun::star::uno::Sequence<rtl::OUString> & rNames)55 			GetProperties(const com::sun::star::uno::Sequence< rtl::OUString >& rNames)
56 							{ return ConfigItem::GetProperties( rNames ); }
PutProperties(const com::sun::star::uno::Sequence<rtl::OUString> & rNames,const com::sun::star::uno::Sequence<com::sun::star::uno::Any> & rValues)57 	sal_Bool PutProperties( const com::sun::star::uno::Sequence< rtl::OUString >& rNames,
58 							const com::sun::star::uno::Sequence< com::sun::star::uno::Any>& rValues)
59 							{ return ConfigItem::PutProperties( rNames, rValues ); }
60 
61     using ConfigItem::EnableNotification;
62     using ConfigItem::GetNodeNames;
63 
64 //	sal_Bool EnableNotification(com::sun::star::uno::Sequence< rtl::OUString >& rNames)
65 //							{ return ConfigItem::EnableNotification( rNames ); }
66 
67 //	com::sun::star::uno::Sequence< rtl::OUString > GetNodeNames(rtl::OUString& rNode)
68 //							{ return ConfigItem::GetNodeNames( rNode ); }
69 };
70 
71 #endif
72 
73 
74