HomeDevCentral

Refactoring: $smarty, $Config in Context, lang_* in Language class.
a6c65bc775a0Unpublished

Unpublished Commit · Learn More

Repository Importing: This repository is still importing.

Description

Refactoring: $smarty, $Config in Context, lang_* in Language class.

[ Previous state ]

  • $smarty is already in context but still were initialized in index.php
  • $Config are global variables
  • L10n code uses lang_* global functions
  • The default message fallback language were MESSAGE_FALLBACK_LANG

[ New state ]

  • Smarty init code is now in Context::initializeTemplateEngine()
  • The configuration is Context::$config.
  • A language class contains the L10n logic and lang_* are moved here
  • The default message fallback language is Language::FALLBACK

[ Notes ]

  • As we don't have a loader for the context, we're keeping temporarily the $Config global variable array, so we can refactor static methods depending of the configuration to ask a context.

[ Feature description ]

Current

Details

Provenance
derecksonAuthored on
Parents
rOBSIDIAN7694ef427d08: New interface: LoadableWithContext
Branches
Unknown
Tags
Unknown