1 /* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
2 /*************************************************************************
4 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
6 * Copyright 2000, 2010 Oracle and/or its affiliates.
8 * OpenOffice.org - a multi-platform office productivity suite
10 * This file is part of OpenOffice.org.
12 * OpenOffice.org is free software: you can redistribute it and/or modify
13 * it under the terms of the GNU Lesser General Public License version 3
14 * only, as published by the Free Software Foundation.
16 * OpenOffice.org is distributed in the hope that it will be useful,
17 * but WITHOUT ANY WARRANTY; without even the implied warranty of
18 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
19 * GNU Lesser General Public License version 3 for more details
20 * (a copy is included in the LICENSE file that accompanied this code).
22 * You should have received a copy of the GNU Lesser General Public License
23 * version 3 along with OpenOffice.org. If not, see
24 * <http://www.openoffice.org/license.html>
25 * for a copy of the LGPLv3 License.
27 ************************************************************************/
31 #include <tools/resmgr.hxx>
32 #include <svl/urihelper.hxx>
33 #include <com/sun/star/container/XNameAccess.hpp>
34 #include <com/sun/star/util/XLocalizedAliases.hpp>
35 #include <com/sun/star/lang/XLocalizable.hpp>
38 #include "bibresid.hxx"
40 #include "bibconfig.hxx"
41 static PtrBibModul pBibModul
=NULL
;
42 static sal_uInt32 nBibModulCount
=0;
43 #include <ucbhelper/content.hxx>
45 using namespace ::rtl
;
46 using namespace ::com::sun::star
;
47 using namespace ::com::sun::star::uno
;
48 using namespace ::com::sun::star::util
;
49 using namespace ::com::sun::star::lang
;
50 using namespace ::com::sun::star::ucb
;
52 #define C2U(cChar) OUString::createFromAscii(cChar)
53 #define C2S(cChar) String::CreateFromAscii(cChar)
55 HdlBibModul
OpenBibModul()
59 pBibModul
=new BibModul();
65 void CloseBibModul(HdlBibModul ppBibModul
)
68 if(nBibModulCount
==0 && ppBibModul
!=NULL
)
75 BibResId::BibResId( sal_uInt16 nId
) :
76 ResId( nId
, *pBibModul
->GetResMgr() )
79 BibConfig
* BibModul::pBibConfig
= 0;
82 pResMgr
= ResMgr::CreateResMgr( "bib" );
92 BibDataManager
* BibModul::createDataManager()
94 return new BibDataManager();
96 //-----------------------------------------------------------------------------
97 BibConfig
* BibModul::GetConfig()
100 pBibConfig
= new BibConfig
;
106 #define STATIC_USTRING(a,b) rtl::OUString a(b)
107 STATIC_USTRING(FM_PROP_LABEL
,C2U("Label"));
108 STATIC_USTRING(FM_PROP_CONTROLSOURCE
,C2U("DataField"));
109 STATIC_USTRING(FM_PROP_NAME
,C2U("Name"));
110 STATIC_USTRING(FM_PROP_FORMATKEY
,C2U("FormatKey"));
111 STATIC_USTRING(FM_PROP_EDITMODE
,C2U("RecordMode"));
112 STATIC_USTRING(FM_PROP_CURSORSOURCETYPE
,C2U("DataSelectionType"));
113 STATIC_USTRING(FM_PROP_CURSORSOURCE
,C2U("DataSelection"));
114 STATIC_USTRING(FM_PROP_DATASOURCE
, C2U("DataSource"));
115 STATIC_USTRING(FM_PROP_VALUE
,C2U("Value"));
116 STATIC_USTRING(FM_PROP_TEXT
,C2U("Text"));
118 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */