Ejemplo n.º 1
0
        public CalendarViewPage()
        {
            this.InitializeComponent();

            List <string> calendarIdentifiers = new List <string>()
            {
                CalendarIdentifiers.Gregorian,
                CalendarIdentifiers.Hebrew,
                CalendarIdentifiers.Hijri,
                CalendarIdentifiers.Japanese,
                CalendarIdentifiers.Julian,
                CalendarIdentifiers.Korean,
                CalendarIdentifiers.Persian,
                CalendarIdentifiers.Taiwan,
                CalendarIdentifiers.Thai,
                CalendarIdentifiers.UmAlQura,
            };

            calendarIdentifier.ItemsSource  = calendarIdentifiers;
            calendarIdentifier.SelectedItem = CalendarIdentifiers.Gregorian;

            var langs = new LanguageList();

            calendarLanguages.ItemsSource = langs.Languages;
        }
Ejemplo n.º 2
0
        /// <summary>
        /// Load localized strings to the memory.
        /// </summary>
        public static void Load()
        {
            var sheet = SheetParser.LoadFromPath(PathProvider.SheetPath, SheetParser.Delimiter.Tab);

            LocalizedStrings.Clear();
            for (var i = 1; i < sheet.Count; i++)
            {
                var id = sheet[i][0];
                if (string.IsNullOrEmpty(id))
                {
                    continue;
                }
                if (LocalizedStrings.ContainsKey(id))
                {
                    throw new Exception($"<b>[Localizer]</b> Text ID \"<b>{id}</b>\" is duplicated. Please check your localization sheet.");
                }

                var strings = sheet[i].ToList();
                strings.RemoveAt(0);
                strings = strings.Select(s => s.Replace("\\n", "\n"))
                          .Select(s => s.Replace("\r", ""))
                          .ToList();
                LocalizedStrings.Add(id, strings);
            }

            LanguageList = sheet[0].Select(s => s.Replace("\r", "")).ToList();
            LanguageList.RemoveAt(0);

            Settings.LoadLanguageSettings();
            ChangeLanguage(CurrentLanguageName ?? "");
        }
Ejemplo n.º 3
0
        public void testBackwardsLanguage()
        {
            LanguageList list = getLanguageList();

            Assert.NotNull(list);
            Assert.IsTrue(list.languages.Count > 0);

            TransfluentLanguage englishLanguage = list.getLangaugeByCode("en-us");
            TransfluentLanguage lang            = list.getLangaugeByCode(TransfluentLanguage.BACKWARDS_LANGUAGE_NAME);

            Assert.AreNotEqual(englishLanguage.code, 0);
            Assert.NotNull(lang);

            //post text key
            string textToSave = "this is sample text" + Random.value;
            var    saveOp     = new SaveTextKey
                                (
                language: englishLanguage.id,
                text: textToSave,
                text_id: HELLO_WORLD_TEXT_KEY
                                );
            bool saved = saveOp.Parse(justCall(saveOp));

            Debug.Log("Saved successfullly:" + saved);

            var testForExistance = new GetTextKey
                                   (
                languageID: englishLanguage.id,
                text_id: HELLO_WORLD_TEXT_KEY
                                   );
            string keyFromDB = testForExistance.Parse(justCall(testForExistance));

            Assert.IsFalse(string.IsNullOrEmpty(keyFromDB));
            Assert.AreEqual(textToSave, keyFromDB);
        }
Ejemplo n.º 4
0
        public static void BuildLanguageList(DataRow inputRow, DataTable dataTable, DataObjectStore store)
        {
            LanguageList lang = new LanguageList();

            dataTable.BeginLoadData();
            Array.ForEach <string>(HygieneUtils.antispamFilterableLanguages, delegate(string code)
            {
                string text     = code.ToUpper().ToString();
                DataRow dataRow = dataTable.NewRow();
                try
                {
                    dataRow["LanguageCode"] = text;
                    dataRow["LanguageName"] = RtlUtil.ConvertToDecodedBidiString(lang.GetDisplayValue(code), RtlUtil.IsRtl);
                    dataRow["Identity"]     = new Identity(text, dataRow["LanguageName"].ToString());
                }
                catch
                {
                    dataRow["LanguageCode"] = text;
                    dataRow["LanguageName"] = text;
                    dataRow["Identity"]     = new Identity(text, text);
                }
                dataTable.Rows.Add(dataRow);
            });
            dataTable.EndLoadData();
        }
Ejemplo n.º 5
0
        public virtual async Task Setup()
        {
            //LOGIN
            await UserPrincipal.LoginAsync("user", "password");

            //SET OUR LANGUAGES
            _ServerEnglishLang = await LanguageEdit.GetLanguageEditAsync("English");

            _ServerSpanishLang = await LanguageEdit.GetLanguageEditAsync("Spanish");

            if (_AllLanguages == null)
            {
                _AllLanguages = await LanguageList.GetAllAsync();
            }

            _EnglishId = (from language in _AllLanguages
                          where language.Text == SeedData.Ton.EnglishText
                          select language.Id).First();

            _SpanishId = (from language in _AllLanguages
                          where language.Text == SeedData.Ton.SpanishText
                          select language.Id).First();


            await InitializeClientSeedDataSingleton();
        }
Ejemplo n.º 6
0
 public AppModule(SmartAppInfo smartApp) : base(smartApp)
 {
     if (smartApp.Languages != null)
     {
         _languages = smartApp.Languages;
     }
 }
        public IHttpActionResult PutLanguageList(int id, LanguageList languageList)
        {
            if (!ModelState.IsValid)
            {
                return(BadRequest(ModelState));
            }

            if (id != languageList.id)
            {
                return(BadRequest());
            }

            db.Entry(languageList).State = EntityState.Modified;

            try
            {
                db.SaveChanges();
            }
            catch (DbUpdateConcurrencyException)
            {
                if (!LanguageListExists(id))
                {
                    return(NotFound());
                }
                else
                {
                    throw;
                }
            }

            return(StatusCode(HttpStatusCode.NoContent));
        }
Ejemplo n.º 8
0
        public void RefreshTranslation()
        {
            SetResources();

            language.SelectedIndex = LanguageList.GetLanguageList()
                                     .FindLanguageInfoByUICulture(ApplicationContext.UICulture).Index;
        }
Ejemplo n.º 9
0
 public override object EditValue(ITypeDescriptorContext context, IServiceProvider provider, object value)
 {
     if (context != null && context.Instance != null && provider != null)
     {
         IWindowsFormsEditorService service = (IWindowsFormsEditorService)provider.GetService(typeof(IWindowsFormsEditorService));
         if (service != null)
         {
             ILimnorProject   p  = null;
             IProjectAccessor pa = context.Instance as IProjectAccessor;
             if (pa != null)
             {
                 p = pa.Project;
             }
             else
             {
                 IWithProject wp = context.Instance as IWithProject;
                 if (wp != null)
                 {
                     p = wp.Project;
                 }
             }
             if (p != null)
             {
                 LanguageList ctl = new LanguageList(service, p);
                 service.DropDownControl(ctl);
                 if (ctl.SelectedLanguage != null)
                 {
                     value = ctl.SelectedLanguage;
                 }
             }
         }
     }
     return(value);
 }
Ejemplo n.º 10
0
        public SettingsViewModel(INavigator navigator)
        {
            this.navigator = navigator;
            var wantLangs = App.Settings.WantedLanguages;

            foreach (var x in SubtitleLanguage.AllLanguages)
            {
                LanguageList.Add(x);
            }

            if (wantLangs != null)
            {
                foreach (var x in wantLangs)
                {
                    WantedLanguageList.Add(x);
                }
            }

            selectedLanguage          = null;
            selectedWantedLanguage    = null;
            alwaysOnTop               = App.Settings.KeepWindowOnTop;
            downloadToSubsFolder      = App.Settings.DownloadToSubsFolder;
            allowMultipleDownloads    = App.Settings.AllowMultipleDownloads;
            overwriteSameLanguageSubs = App.Settings.OverwriteSameLanguageSub;
        }
        internal void LoadNewList(List <LanguageInfo> languageList)
        {
            if (languageList.Count >= 1)
            {
                foreach (LanguageInfo remoteLang in languageList)
                {
                    int oldIndex = LanguageList.IndexOf(remoteLang);
                    if (oldIndex >= 0)
                    {
                        remoteLang.IsLocal   = LanguageList.ElementAt(oldIndex).IsLocal;
                        remoteLang.ItemState = LanguageList.ElementAt(oldIndex).ItemState;
                    }
                }

                LanguageList.Clear();
                LanguageList.Add(defaultLanguageInfo());

                foreach (LanguageInfo remoteLang in languageList)
                {
                    LanguageList.Add(remoteLang);
                }

                Save(true);
            }

            LanguageList.First().SetCurrentInternal(true);
        }
Ejemplo n.º 12
0
        internal static ArchivingLanguage GetOneLanguage(string languageKey)
        {
            ArchivingLanguage returnValue = null;
            var language = LanguageList.FindByEnglishName(languageKey);

            if (language == null || language.Iso3Code == "und")
            {
                if (!string.IsNullOrEmpty(languageKey) && languageKey.Length == 3)
                {
                    language = LanguageList.FindByISO3Code(languageKey);
                }
            }
            if (language != null && language.Iso3Code != "und" && !string.IsNullOrEmpty(language.EnglishName))
            {
                returnValue = new ArchivingLanguage(ForceIso639ThreeChar(language.Iso3Code), language.Definition)
                {
                    EnglishName = language.EnglishName
                }
            }
            ;
            else if (Project != null)
            {
                var archivingLanguage = ParseLanguage(ForceIso639ThreeChar(Project.VernacularISO3CodeAndName), null);
                returnValue = new ArchivingLanguage(ForceIso639ThreeChar(archivingLanguage.Iso3Code), archivingLanguage.LanguageName)
                {
                    EnglishName = archivingLanguage.EnglishName
                };
            }
            return(returnValue);
        }
Ejemplo n.º 13
0
        public LanguageList GetLanguageList()
        {
            // = new LanguageDetails();
            LanguageList objlst = new LanguageList();
            DataSet      ds     = objServices.GetLanguageList();

            if (ds != null && ds.Tables.Count > 0)
            {
                int tblIndx = -1;
                tblIndx++;
                if (ds.Tables.Count > tblIndx && ds.Tables[tblIndx] != null && ds.Tables[tblIndx].Rows.Count > 0)
                {
                    List <LanguageDetails> LanguageList = new List <LanguageDetails>();
                    foreach (DataRow dr in ds.Tables[tblIndx].Rows)
                    {
                        LanguageDetails obj = new LanguageDetails();
                        obj.LanguageId = Convert.ToInt64(dr["LanguageId"]);
                        obj.Language   = Convert.ToString(dr["Language"]);
                        obj.Status     = Convert.ToInt16(dr["IsActive"]);
                        LanguageList.Add(obj);
                    }
                    objlst.languagelist = LanguageList;
                }
                tblIndx++;
                if (ds.Tables.Count > tblIndx && ds.Tables[tblIndx] != null && ds.Tables[tblIndx].Rows.Count > 0)
                {
                    objlst.TotalCount = Convert.ToInt64(ds.Tables[tblIndx].Rows[0]["TotalCount"]);
                }
            }
            return(objlst);
        }
Ejemplo n.º 14
0
        private static ArchivingLanguage ParseLanguage(string languageDesignator, IArchivingPackage package)
        {
            ArchivingLanguage archivingLanguage = null;
            var parts = languageDesignator.SplitTrimmed(':').ToArray();

            if (parts.Length == 2)
            {
                var language = LanguageList.FindByISO3Code(parts[0]);

                // SP-765:  Allow codes from Ethnologue that are not in the Arbil list
                archivingLanguage = string.IsNullOrEmpty(language?.EnglishName)
                                        ? new ArchivingLanguage(ForceIso639ThreeChar(parts[0]), parts[1], parts[1])
                                        : new ArchivingLanguage(ForceIso639ThreeChar(language.Iso3Code), parts[1], language.EnglishName);
                package?.MetadataIso3Languages.Add(archivingLanguage);
            }
            else if (parts.Length == 1)
            {
                var language = LanguageList.FindByISO3Code(parts[0]);
                if (!string.IsNullOrEmpty(language?.EnglishName))
                {
                    archivingLanguage = new ArchivingLanguage(ForceIso639ThreeChar(language.Iso3Code), parts[1], language.EnglishName);
                    package?.MetadataIso3Languages.Add(archivingLanguage);
                }
            }

            return(archivingLanguage);
        }
Ejemplo n.º 15
0
        /// <summary>
        /// Retrieves list of Language objects from SqlCommand, after database query
        /// number of rows retrieved and returned depends upon the rows field value
        /// </summary>
        /// <param name="cmd">The command object to use for query</param>
        /// <param name="rows">Number of rows to process</param>
        /// <returns>A list of Language objects</returns>
        private LanguageList GetList(SqlCommand cmd, long rows)
        {
            // Select multiple records
            SqlDataReader reader;
            long          result = SelectRecords(cmd, out reader);

            //Language list
            LanguageList list = new LanguageList();

            using ( reader )
            {
                // Read rows until end of result or number of rows specified is reached
                while (reader.Read() && rows-- != 0)
                {
                    Language languageObject = new Language();
                    FillObject(languageObject, reader);

                    list.Add(languageObject);
                }

                // Close the reader in order to receive output parameters
                // Output parameters are not available until reader is closed.
                reader.Close();
            }

            return(list);
        }
Ejemplo n.º 16
0
        internal LanguageViewModel(UIElement element, Action <int> Command, bool IsAllLanguage = false)
        {
            this._element      = element;
            this.Command       = Command;
            this.IsAllLanguage = IsAllLanguage;


            if (IsAllLanguage)
            {
                LanguageList.Clear();

                foreach (var item in Resources.GetRes().AllLangList.OrderBy(x => x.Value.LangOrder))
                {
                    LanguageList.Add(new LangItemModel()
                    {
                        LanguageMode = item.Value.LangIndex, LanguageName = item.Value.LangName, Command = this.Command
                    });
                }
            }
            else
            {
                LanguageList.Clear();

                foreach (var item in Resources.GetRes().MainLangList)
                {
                    LanguageList.Add(new LangItemModel()
                    {
                        LanguageMode = item.Value.LangIndex, LanguageName = item.Value.LangName, Command = this.Command
                    });
                }
            }
        }
Ejemplo n.º 17
0
        private void button_modify_Click(object sender, RoutedEventArgs e)
        {
            string        LanguageName     = (listview_locallabel.SelectedItem as label).lang;
            string        ElementNameValue = (listview_locallabel.SelectedItem as label).Text[0];
            List <string> ExistList        = new List <string>();

            foreach (label Item in LanguageList)
            {
                ExistList.Add(Item.lang);
            }

            LocalizationWizard LWizard = new LocalizationWizard("Name", LanguageName, ElementNameValue, ExistList: ExistList);

            if (LWizard.ShowDialog() == true)
            {
                if (LanguageList.Contains((listview_locallabel.SelectedItem as label)))
                {
                    LanguageList.Remove((listview_locallabel.SelectedItem as label));
                }

                var label = new label();
                label.lang = LWizard.LangComboBox.Text;
                label.Text = LWizard.ElementNameTextBox.Text.Trim().Split('\n');
                LanguageList.Add(label);
            }

            if (listview_locallabel.Items.Count == 0 || listview_locallabel.SelectedItem == null)
            {
                LangListBtnEnable(false);
            }
        }
Ejemplo n.º 18
0
        /// <summary>
        /// Load all language files (*.lng) found in the exe directory, replace default language definitions (de/en)
        /// </summary>
        public void LoadAllLanguageFiles()
        {
            string        path    = Helper.GetExePath();
            DirectoryInfo dirInfo = new DirectoryInfo(path);

            FileInfo[] files = dirInfo.GetFiles("*.lng");
            foreach (FileInfo file in files)
            {
                Language newLng = LoadLanguage(file.FullName);
                if (newLng == null)
                {
                    // not a valid language file
                    continue;
                }

                // replace or add
                Language oldLng = GetLanguage(newLng.Key);
                if (oldLng == null)
                {                       // add
                    LanguageList.Add(newLng);
                }
                else
                {
                    // replace existing
                    LanguageList.Remove(oldLng);
                    LanguageList.Add(newLng);
                }
            }
        }
Ejemplo n.º 19
0
        protected void cargaddw()
        {
            ListItem kk;

            // fisrt priority
            ddwPiority.Items.Clear();
            kk      = new ListItem();
            kk.Text = "None"; ddwPiority.Items.Add(kk);
            for (int i = 1; i <= 5; i++)
            {
                kk      = new ListItem();
                kk.Text = i.ToString(); ddwPiority.Items.Add(kk);
            }
            //
            ddwWorkFlow.Items.Clear();
            kk = new ListItem(); kk.Text = "None"; ddwWorkFlow.Items.Add(kk);
            kk = new ListItem(); kk.Text = "TRANSLATION"; ddwWorkFlow.Items.Add(kk);
            kk = new ListItem(); kk.Text = "TRANSLATION_REVIEW"; ddwWorkFlow.Items.Add(kk);
            kk = new ListItem(); kk.Text = "TRANSLATION_REVIEW_VALIDATION"; ddwWorkFlow.Items.Add(kk);
            kk = new ListItem(); kk.Text = "TRANSLATION_VALIDATION"; ddwWorkFlow.Items.Add(kk);
            // languages
            var DL = new LanguageList(Session["host"].ToString());

            // DL.ObtenLista2(); // retreives only spa and eng
            DL.ObtenLista();
            if (!DL.todoOK)
            {
                lblOut.Text = string.Format("<font color='red'>[{0}]</font>", DL.info);
                return;
            }
            // we have de list
            ddwSource.Items.Clear();
            ddwTarget.Items.Clear();
            foreach (Language l in DL.RootLanguages.languages)
            {
                kk = new ListItem(); kk.Text = l.name; kk.Value = l.code; ddwSource.Items.Add(kk);
                kk = new ListItem(); kk.Text = l.name; kk.Value = l.code; ddwTarget.Items.Add(kk);
                // seleccionar inglés y spa
            }
            int posi = 0;

            foreach (ListItem i in ddwSource.Items)
            {
                if (i.Value == "English")
                {
                    ddwSource.SelectedIndex = posi;
                }
                posi++;
            }
            posi = 0;
            foreach (ListItem ii in ddwTarget.Items)
            {
                if (ii.Value == "Spanish")
                {
                    ddwTarget.SelectedIndex = posi;
                }
                posi++;
            }
        }
Ejemplo n.º 20
0
        public void testLanguages()
        {
            LanguageList language = getLanguageList();

            Assert.IsNotNull(language);
            Assert.IsNotNull(language.languages);
            Assert.IsTrue(language.languages.Count > 0);
        }
Ejemplo n.º 21
0
 public LayoutViewTemplate(string smartAppTitle, ConcernInfo concern, LayoutInfo layout, LanguageList languages)
 {
     _smartAppTitle = smartAppTitle;
     _concern       = concern;
     _layout        = layout;
     _languages     = languages;
     _menu          = getMenu(_concern);
 }
 protected virtual void UnhookFrom(LanguageList modelList)
 {
     if (modelList != null)
     {
         modelList.CollectionChanged += HandleCollectionChanged;
         modelList.ChildChanged      += HandleChildChanged;
     }
 }
Ejemplo n.º 23
0
        public void Load()
        {
            LanguageList languages = new LanguageList();

            languages.Load();

            Assert.IsTrue(languages.Count > 0);
        }
 public LayoutModuleTemplate(string concernId, LayoutInfo layout, LanguageList languages, ApiList api)
 {
     _concernId         = concernId;
     _layout            = layout;
     _languages         = languages;
     _api               = api;
     _apiDomainServices = getApiDomainServices(api, layout.Actions);
 }
Ejemplo n.º 25
0
        public ActionResult LanguageListDeleteConfirmed(int id)
        {
            LanguageList languageList = db.LanguageLists.Find(id);

            db.LanguageLists.Remove(languageList);
            db.SaveChanges();
            DisplaySuccessMessage("Has delete a LanguageList record");
            return(RedirectToAction("LanguageListIndex"));
        }
Ejemplo n.º 26
0
        public void FindByISO3Code_CodeNotFoundTest()
        {
            var result = LanguageList.FindByISO3Code("tru");

            Assert.IsNullOrEmpty(result.EnglishName);
            Assert.AreEqual("tru", result.Iso3Code);
            Assert.IsNullOrEmpty(result.OtherName);
            Assert.AreEqual("ISO639-3:tru", result.Id);
        }
Ejemplo n.º 27
0
        public void FindByEnglishNameTest()
        {
            var result = LanguageList.FindByEnglishName("French");

            Assert.AreEqual("French", result.EnglishName);
            Assert.AreEqual("fra", result.Iso3Code);
            Assert.IsNullOrEmpty(result.OtherName);
            Assert.AreEqual("ISO639-3:fra", result.Id);
        }
Ejemplo n.º 28
0
        public void FindByEnglishName_NameNotFoundTest()
        {
            var result = LanguageList.FindByEnglishName("Turoyo");

            Assert.AreEqual("Turoyo", result.EnglishName);
            Assert.AreEqual("und", result.Iso3Code);
            Assert.AreEqual("Turoyo", result.OtherName);
            Assert.AreEqual("ISO639-3:und", result.Id);
        }
    public void DetectLanguage()
    {
        switch (Application.systemLanguage)
        {
        case SystemLanguage.English:
            language = LanguageList.English;
            break;

        case SystemLanguage.Turkish:
            language = LanguageList.Turkish;
            break;

        case SystemLanguage.ChineseSimplified:
            language = LanguageList.ChinesSimplified;
            break;

        case SystemLanguage.Arabic:
            language = LanguageList.Arabic;
            break;

        case SystemLanguage.French:
            language = LanguageList.French;
            break;

        case SystemLanguage.Italian:
            language = LanguageList.Italian;
            break;

        case SystemLanguage.German:
            language = LanguageList.German;
            break;

        case SystemLanguage.Spanish:
            language = LanguageList.Spanish;
            break;

        case SystemLanguage.Russian:
            language = LanguageList.Russian;
            break;

        case SystemLanguage.Portuguese:
            language = LanguageList.Portuguese;
            break;

        case SystemLanguage.Japanese:
            language = LanguageList.Japanese;
            break;

        case SystemLanguage.Korean:
            language = LanguageList.Korean;
            break;

        default:
            language = LanguageList.English;
            break;
        }
    }
Ejemplo n.º 30
0
        private Language LoadLanguage(string langName)
        {
            LanguageList languages = new LanguageList();

            languages.Load();
            Language language = languages.FirstOrDefault(l => l.Description == langName);

            return(language);
        }
Ejemplo n.º 31
0
        public void getLanguages()
        {
            var language = new RequestAllLanguages();
            var requester = new SyncronousEditorWebRequest();

            LanguageList list = language.Parse(requester.request(language).text);
            Assert.NotNull(list);

            englishLanguage = list.getLangaugeByCode("en-us");
            backwardsLanguage = list.getLangaugeByCode(TransfluentLanguage.BACKWARDS_LANGUAGE_NAME);
            languageCache = list;
            Assert.AreNotEqual(englishLanguage.code, 0);
            Assert.NotNull(backwardsLanguage);
        }
 public LanguageList GetLanguageListFromRawReturn(List<Dictionary<string, TransfluentLanguage>> rawReturn)
 {
     var languages = new List<TransfluentLanguage>();
     foreach(var listitem in rawReturn)
     {
         foreach(var kvp in listitem)
         {
             languages.Add(kvp.Value);
         }
     }
     var retrieved = new LanguageList
     {
         languages = languages
     };
     return retrieved;
 }
 public void requestAllLanguagesInEditorSynchronous()
 {
     try
     {
         var languageRequest = new RequestAllLanguages();
         allLanguagesSupported = languageRequest.Parse(makeCall(languageRequest));
     }
     catch(CallException e)
     {
         Debug.LogError("error getting all languages:" + e.Message);
     }
 }
 internal LanguageManager()
 {
     m_languageList = CurrentLogic.GetAllLanguage();
 }
Ejemplo n.º 35
0
 public static void Set(ILanguageProvider languageProvider)
 {
     var langList = new LanguageList();
     Language language = langList.Search(languageProvider.GetLanguageId());
     Set(language);
 }
 private void Initialize()
 {
     if(EditorApplication.isUpdating || EditorApplication.isCompiling)
         return;
     if(Event.current.type != EventType.Repaint)
         return;
     _languages = _mediator.getLanguageList();
     _allKnownConfigurations = allKnownConfigurations();
     initialized = true;
 }
 public async Task<LanguageList.response> LanguageList(LanguageList.request request, CancellationToken? token = null)
 {
     return await SendAsync<LanguageList.response>(request.ToXmlString(), token.GetValueOrDefault(CancellationToken.None));
 }
        public LanguageList getLanguageList()
        {
            allLanguagesSupported = ResourceLoadFacade.getLanguageList();
            if(allLanguagesSupported == null)
            {
                requestAllLanguagesInEditorSynchronous();
                if(allLanguagesSupported != null)
                {
                    //allLanguagesSupported,
                    var languageListSO = ResourceCreator.CreateSO<LanguageListSO>("LanguageList");
                    languageListSO.list = allLanguagesSupported;
                    //do I need to set this dirty?
                }
            }

            return allLanguagesSupported;
        }
        //public static event Action OnLanguageChanged;
        public static ITranslationUtilityInstance createNewInstance(string destinationLanguageCode = "", string group = "")
        {
            if(_LanguageList == null)
            {
                _LanguageList = ResourceLoadFacade.getLanguageList();
            }

            if(_LanguageList == null)
            {
                Debug.LogError("Could not load new language list");
                return null;
            }
            bool enableCapture = false;
            #if UNITY_EDITOR
            if(Application.isEditor)
            {
                enableCapture = getCaptureMode();
            }
            #endif //UNTIY_EDITOR

            TransfluentLanguage dest = _LanguageList.getLangaugeByCode(destinationLanguageCode);
            if(dest == null)
            {
                TranslationConfigurationSO defaultConfigInfo = ResourceLoadFacade.LoadConfigGroup(group);
                string newDestinationLanguageCode = defaultConfigInfo.sourceLanguage.code;
                /*
                if (string.IsNullOrEmpty(destinationLanguageCode))
                {
                    Debug.Log("Using default destination language code, as was given an empty language code");
                }
                else
                    Debug.Log("Could not load destination language code:" + destinationLanguageCode + " so falling back to source game language code:" + destinationLanguageCode);
                 */
                destinationLanguageCode = newDestinationLanguageCode;

                dest = _LanguageList.getLangaugeByCode(destinationLanguageCode);
                //dest = _LanguageList.getLangaugeByCode
            }
            GameTranslationSet destLangDB = GameTranslationGetter.GetTranslaitonSetFromLanguageCode(destinationLanguageCode);
            Dictionary<string, string> keysInLanguageForGroupSpecified = destLangDB != null
                ? destLangDB.getGroup(group).getDictionaryCopy()
                : new Dictionary<string, string>();
            #if UNITY_EDITOR
            EditorUtility.SetDirty(destLangDB);
            #endif

            var newTranslfuentUtilityInstance = new TranslationUtilityInstance
            {
                allKnownTranslations = keysInLanguageForGroupSpecified,
                destinationLanguage = dest,
                groupBeingShown = group,
            };
            if(enableCapture)
            {
                newTranslfuentUtilityInstance = new AutoCaptureTranslationUtiliityInstance()
                {
                    allKnownTranslations = keysInLanguageForGroupSpecified,
                    destinationLanguage = dest,
                    groupBeingShown = group,
                    doCapture = enableCapture,
                    coreTransltionSet = destLangDB,
                };
            }
            return newTranslfuentUtilityInstance;
        }
 public void invalidateAuth(bool wipeDatastore = false)
 {
     context.removeNamedMapping<string>(NamedInjections.API_TOKEN);
     allLanguagesSupported = null;
     if(wipeDatastore)
         context.manualGetMapping<ICredentialProvider>().save(null, null);
 }
 private bool GetLanguagesGUI()
 {
     if(_languages == null)
     {
         EditorGUILayout.BeginHorizontal();
         GUILayout.Label("Please connect to the internet to initialize properly");
         if(GUILayout.Button("initialize known languages from internet"))
         {
             _languages = _mediator.getLanguageList();
         }
         EditorGUILayout.EndHorizontal();
     }
     return _languages != null;
 }