/[opental]/opental/PlacelessTranslationService/__init__.py
ViewVC logotype

Diff of /opental/PlacelessTranslationService/__init__.py

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1.4 by lalo, Tue Feb 18 22:31:56 2003 UTC revision 1.5 by lalo, Fri Feb 21 23:29:40 2003 UTC
# Line 19  __version__ = ''' Line 19  __version__ = '''
19  $Id$  $Id$
20  '''.strip()  '''.strip()
21    
22    from AccessControl import ModuleSecurityInfo, allow_module, allow_class, allow_type
23  from PlacelessTranslationService import PlacelessTranslationService, log  from PlacelessTranslationService import PlacelessTranslationService, log
24    from Negotiator import negotiate
25  from GettextMessageCatalog import GettextMessageCatalog  from GettextMessageCatalog import GettextMessageCatalog
26  from Products.PageTemplates.GlobalTranslationService import setGlobalTranslationService  from Products.PageTemplates.GlobalTranslationService import setGlobalTranslationService
27  import os, glob, zLOG, sys  import os, glob, zLOG, sys
# Line 32  translation_service = PlacelessTranslati Line 34  translation_service = PlacelessTranslati
34  # set the translation service  # set the translation service
35  setGlobalTranslationService(translation_service)  setGlobalTranslationService(translation_service)
36    
37    translate = translation_service.translate
38    getLanguages = translation_service.getLanguages
39    getLanguageName = translation_service.getLanguageName
40    
41    security = ModuleSecurityInfo('Products.PlacelessTranslationService')
42    security.declarePublic('negotiate')
43    security.declarePublic('translate')
44    security.declarePublic('getLanguages')
45    security.declarePublic('getLanguageName')
46    
47  # sweep the i18n directory  # sweep the i18n directory
48  basepath = os.path.join(INSTANCE_HOME, 'i18n')  basepath = os.path.join(INSTANCE_HOME, 'i18n')
49  if os.path.isdir(basepath):  if os.path.isdir(basepath):

Legend:
Removed from v.1.4  
changed lines
  Added in v.1.5

savannah-hackers-public@gnu.org
ViewVC Help
Powered by ViewVC 1.1.26