Пример #1
0
		public IAddinLocalizer CreateLocalizer (RuntimeAddin addin, NodeElement element)
		{
			string pkg = element.GetAttribute ("catalog");
			if (pkg.Length == 0)
				pkg = addin.Id;
			string dir = element.GetAttribute ("location");
			if (dir.Length == 0)
				dir = "locale";
			dir = addin.GetFilePath (dir);
			domain = new GettextDomain ();
			domain.Init (pkg, dir);
			return this;
		}
        public IAddinLocalizer CreateLocalizer(RuntimeAddin addin, NodeElement element)
        {
            string pkg = element.GetAttribute("catalog");

            if (pkg.Length == 0)
            {
                pkg = addin.Id;
            }
            string dir = element.GetAttribute("location");

            if (dir.Length == 0)
            {
                dir = "locale";
            }
            dir    = addin.GetFilePath(dir);
            domain = new GettextDomain();
            domain.Init(pkg, dir);
            return(this);
        }