// Used to create Json for new version
        public static void Export()
        {
            Base = new LocalizationBase();
            var serialized = JsonConvert.SerializeObject(LocalizationHelper.Base);

            File.WriteAllText("export.json", serialized);
        }
Ejemplo n.º 2
0
        public static void Update()
        {
            var settings = Settings.LoadSettings();

            if (!string.IsNullOrEmpty(settings.Language))
            {
                Load(settings.Language);
            }
            else
            {
                Base = new LocalizationBase();
            }
        }
        public static void Load(string path)
        {
            var context = File.ReadAllText(path);

            Base = JsonConvert.DeserializeObject <LocalizationBase>(context);
        }