/// <summary>
        /// Регистрация словаря ресурсов
        /// </summary>
        /// <param name="dictionaryInfo">Информация о словаре ресурсов</param>
        /// <exception cref="OtherDictionaryAlreadyRegisteredWithSameNameException">Другой словарь уже зарегистрирован под таким именем.</exception>
        public void RegisterDictionary(ResourceDictionaryInfo dictionaryInfo)
        {
            if (_resourceDictionaryInfos.TryGetValue(dictionaryInfo.Name, out ResourceDictionaryInfo di))
            {
                if (di == dictionaryInfo)
                {
                    return;
                }

                throw new OtherDictionaryAlreadyRegisteredWithSameNameException(dictionaryInfo.Name);
            }

            _resourceDictionaryInfos.Add(dictionaryInfo.Name, dictionaryInfo);
            UpdateRegisteredDictionary(dictionaryInfo, CultureInfo);
        }
        /// <summary>
        /// Обновить словарь зарегистрированных словарей
        /// </summary>
        /// <param name="dictionaryInfo">Информация о словаре</param>
        /// <param name="cultureInfo">Культура</param>
        private void UpdateRegisteredDictionary(ResourceDictionaryInfo dictionaryInfo, CultureInfo cultureInfo)
        {
            var source = new Uri(dictionaryInfo.GetPath(cultureInfo));

            if (_registeredDictionaries.TryGetValue(dictionaryInfo.Name, out ResourceDictionary d))
            {
                if (d.Source == source)
                {
                    return;
                }

                _registeredDictionaries.Remove(dictionaryInfo.Name);
            }
            var dictionary = new ResourceDictionary {
                Source = source
            };

            _registeredDictionaries.Add(dictionaryInfo.Name, dictionary);
        }