2 Copyright © 1995-2004, The AROS Development Team. All rights reserved.
5 Desc: LocStrToDateGetCharFunc - locale.library's private replacement
6 of dos.library/DosGetLocalizedString function. IPrefs will install
12 #include <exec/types.h>
13 #include <proto/exec.h>
14 #include <proto/dos.h>
15 #include <proto/locale.h>
16 #include "locale_intern.h"
18 /*****************************************************************************
21 #include <proto/locale.h>
23 AROS_PLH1(CONST_STRPTR
, LocDosGetLocalizedString
,
26 AROS_LHA(LONG
, stringNum
, D1
),
29 struct DosLibrary
*, DOSBase
, 38, Locale
)
32 See dos.library/DosGetLocalizedString
35 See dos.library/DosGetLocalizedString
40 This function is not called by apps directly. Instead dos.library/DosGet-
41 LocalizedString is patched to use this function. This means, that the
42 LocaleBase parameter above actually points to DOSBase, so we make use of
43 the global LocaleBase variable. This function is marked as private,
44 thus the headers generator won't mind the different basename in the header.
51 dos.library/DosGetString(), dos.library/DosGetLocalizedString()
57 *****************************************************************************/
62 LONG
*p
= DOSBase
->dl_Errors
->estr_Nums
;
63 UBYTE
*q
= DOSBase
->dl_Errors
->estr_Strings
;
66 /* We should really call the original DosGetString(), but ahwell... */
87 return GetCatalogStr(IntLB(LocaleBase
)->lb_CurrentLocale
->il_DosCatalog
, stringNum
, defstr
);
89 struct Catalog
*catalog
= (struct Catalog
*)DOSBase
->dl_Errors
;
91 return GetCatalogStr(catalog
, ((stringNum
>= 0) ? stringNum
: -stringNum
), NULL
);
96 } /* LocDosGetLocalizedString */