Class: IsoDoc::Iec::I18n

Inherits:
IsoDoc::Iso::I18n
  • Object
show all
Defined in:
lib/isodoc/iec/i18n.rb

Instance Method Summary collapse

Instance Method Details

#load_yaml1(lang, script) ⇒ Object



4
5
6
7
8
9
10
11
12
13
14
15
# File 'lib/isodoc/iec/i18n.rb', line 4

def load_yaml1(lang, script)
  y = if lang == "en"
        YAML.load_file(File.join(File.dirname(__FILE__), "i18n-en.yaml"))
      elsif lang == "fr"
        YAML.load_file(File.join(File.dirname(__FILE__), "i18n-fr.yaml"))
      elsif lang == "zh" && script == "Hans"
        YAML.load_file(File.join(File.dirname(__FILE__), "i18n-zh-Hans.yaml"))
      else
        YAML.load_file(File.join(File.dirname(__FILE__), "i18n-en.yaml"))
      end
  super.deep_merge(y)
end