1<?xml version="1.0" encoding="UTF-8"?>
2<!DOCTYPE script:module PUBLIC "-//OpenOffice.org//DTD OfficeDocument 1.0//EN" "module.dtd">
3<!--***********************************************************
4 *
5 * Licensed to the Apache Software Foundation (ASF) under one
6 * or more contributor license agreements.  See the NOTICE file
7 * distributed with this work for additional information
8 * regarding copyright ownership.  The ASF licenses this file
9 * to you under the Apache License, Version 2.0 (the
10 * "License"); you may not use this file except in compliance
11 * with the License.  You may obtain a copy of the License at
12 *
13 *   http://www.apache.org/licenses/LICENSE-2.0
14 *
15 * Unless required by applicable law or agreed to in writing,
16 * software distributed under the License is distributed on an
17 * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
18 * KIND, either express or implied.  See the License for the
19 * specific language governing permissions and limitations
20 * under the License.
21 *
22 ***********************************************************-->
23<script:module xmlns:script="http://openoffice.org/2000/script" script:name="Language" script:language="StarBasic">Option Explicit
24
25
26Public Const cLANGUAGE_SYSTEM = &quot;&quot;, cLANGUAGE_CHINESE = &quot;zh&quot;, cLANGUAGE_DANISH = &quot;da&quot;
27Public Const cLANGUAGE_DUTCH = &quot;nl&quot;, cLANGUAGE_ENGLISH = &quot;en&quot;, cLANGUAGE_FINNISH = &quot;fi&quot;
28Public Const cLANGUAGE_FRENCH = &quot;fr&quot;, cLANGUAGE_GERMAN = &quot;de&quot;, cLANGUAGE_GREEK = &quot;el&quot;
29Public Const cLANGUAGE_ITALIAN = &quot;it&quot;, cLANGUAGE_JAPANESE = &quot;ja&quot;, cLANGUAGE_NORWEGIAN = &quot;no&quot;
30Public Const cLANGUAGE_POLISH = &quot;pl&quot;, cLANGUAGE_PORTUGUESE = &quot;pt&quot;, cLANGUAGE_RUSSIAN = &quot;ru&quot;
31Public Const cLANGUAGE_SPANISH = &quot;es&quot;, cLANGUAGE_SWEDISH = &quot;sv&quot;, cLANGUAGE_TURKISH = &quot;tr&quot;
32
33Public BLNameList(0 To 16) as String
34
35
36&apos; R e s o u r c e   s t r i n g   c o n s t a n t s
37&apos; -------------------------------------------------
38&apos; Dialog labels start at 1000
39
40Sub LoadLanguage%(ByVal LangLocale)
41Dim Dummy$
42Dim i as Integer
43Const dlgMonth = 1200
44&apos; Abreviated months start 1225
45Const dlgShortMonth = 1225
46	If InitResources(&quot;schedule&quot;, &quot;cal&quot;) Then
47		If LangLocale  = cLANGUAGE_GERMAN Then
48
49			&apos; Load all states
50			BLNameList(0) = GetResText(1100)
51			BLNameList(1) = &quot;Bayern&quot;
52			BLNameList(2) = &quot;Baden-Württemberg&quot;
53			BLNameList(3) = &quot;Berlin&quot;
54			BLNameList(4) = &quot;Bremen&quot;
55			BLNameList(5) = &quot;Brandenburg&quot;
56			BLNameList(6) = &quot;Hamburg&quot;
57			BLNameList(7) = &quot;Hessen&quot;
58			BLNameList(8) = &quot;Mecklenburg-Vorpommern&quot;
59			BLNameList(9) = &quot;Niedersachsen&quot;
60			BLNameList(10) = &quot;Nordrhein-Westfalen&quot;
61			BLNameList(11) = &quot;Rheinland-Pfalz&quot;
62			BLNameList(12) = &quot;Saarland&quot;
63			BLNameList(13) = &quot;Sachsen&quot;
64			BLNameList(14) = &quot;Sachsen-Anhalt&quot;
65			BLNameList(15) = &quot;Schleswig Holstein&quot;
66			BLNameList(16) = &quot;Thüringen&quot;
67
68			DlgCalModel.lstHolidays.StringItemList() = BLNameList()
69		End If
70		sWizardTitle$ = GetResText(1300)
71		sError = GetResText(1301)
72		cCalSubcmdDeleteSelect_DeleteSelEntryTitle$ = GetResText(1302)
73		cCalSubcmdDeleteSelect_DeleteSelEntry$ = GetResText(1303)
74		DlgCalendar.Title = GetResText(1000)
75
76		With DlgCalModel
77			cCalSubcmdSwitchOwnDataOrGeneral_OwnData$ = GetResText(1002)
78			cCalSubcmdSwitchOwnDataOrGeneral_Back$ = GetResText(1001)
79			.hlnTime.Label = GetResText(1011)
80			.lblYear.Label = GetResText(1012)
81			.cmdCancel.Label = GetResText(1005)
82			.cmdGoOn.Label = GetResText(1004)
83			.lblHolidays.Label = GetResText(1014)
84			sBitmapFilename = GetResText(1099)
85			sBitmapFilename = ReplaceString(sBitmapFileName, &quot;.gif&quot;, &quot;.bmp&quot;)
86			DlgCalModel.hlnCalendar.Label = GetResText(1006)
87			.optYear.Label = GetResText(1007)
88			.optMonth.Label = GetResText(1008)
89			.lblMonth.Label = GetResText(1013)
90			.cmdOwnData.Label = GetResText(1015)
91			.hlnNewEvent.Label = GetResText(1019)
92			.lblEvent.Label = GetResText(1019)
93			.lblEventDay.Label = GetResText(1021)
94			.lblEventMonth.Label = GetResText(1022)
95&apos;			.lblEventYear.Label = GetResText(1023)
96&apos;			.chkEventOnce.Label = GetResText(1020)
97			.cmdInsert.Label = GetResText(1016)
98			.cmdDelete.Label = GetResText(1017)
99			&apos; Load long month names
100			For i = 0 To 11
101				cCalLongMonthNames(i) = GetResText(dlgMonth+i)
102				cCalShortMonthNames(i)= cCalLongMonthNames(i)
103				&apos;cCalShortMonthNames(i)= Left$(cCalLongMonthNames(i), 3)
104				cCalShortMonthNames(i)= RTrim(cCalShortMonthNames(i))
105			Next
106			&apos; Load sheet names
107			sCalendarTitle = GetResText(1410)
108			sMonthTitle = GetResText(1411)
109			&apos; Load names of styles
110			cCalStyleWorkday$ = GetResText(1400)
111			cCalStyleWeekend$ = GetResText(1401)
112		End With
113	End If
114End Sub
115</script:module>
116