当前位置: 首页>>代码示例>>C#>>正文


C# IResourceResolver.LocalizeString方法代码示例

本文整理汇总了C#中IResourceResolver.LocalizeString方法的典型用法代码示例。如果您正苦于以下问题:C# IResourceResolver.LocalizeString方法的具体用法?C# IResourceResolver.LocalizeString怎么用?C# IResourceResolver.LocalizeString使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在IResourceResolver的用法示例。


在下文中一共展示了IResourceResolver.LocalizeString方法的3个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。

示例1: Item

 internal Item(ImageComparer imageComparer, bool reverse)
 {
     _resourceResolver = new ResourceResolver(imageComparer.GetType(), false);
     _description = imageComparer.Description;
     Name = imageComparer.Name;
     IsReverse = reverse;
     _realDescription = !IsReverse
                            ? _resourceResolver.LocalizeString(_description)
                            : string.Format(SR.FormatSortByReverse, _resourceResolver.LocalizeString(_description));
     
     Comparer = imageComparer.GetComparer(reverse);
 }
开发者ID:m-berkani,项目名称:ClearCanvas,代码行数:12,代码来源:ImageComparerList.cs

示例2: GetLocalizedCustomMessage

		/// <summary>
		/// Gets the custom message localized according to the specified resource resolver.
		/// </summary>
		protected string GetLocalizedCustomMessage(IResourceResolver resourceResolver)
		{
			return string.IsNullOrEmpty(_message) ? null : resourceResolver.LocalizeString(_message);
		}
开发者ID:m-berkani,项目名称:ClearCanvas,代码行数:7,代码来源:ValidationAttribute.cs

示例3: Folder

		/// <summary>
		/// Constructor
		/// </summary>
		protected Folder()
		{
			_resourceResolver = new ResourceResolver(this.GetType(), true);
			
			// Initialize folder Path
			var pathAttrib = AttributeUtils.GetAttribute<FolderPathAttribute>(this.GetType());
			if (pathAttrib != null)
			{
				_folderPath = new Path(pathAttrib.Path, _resourceResolver);
				_startExpanded = pathAttrib.StartExpanded;
			}

			// Initialize tooltip
			var attrib = AttributeUtils.GetAttribute<FolderDescriptionAttribute>(this.GetType());
			if (attrib != null)
			{
				this.Tooltip = _resourceResolver.LocalizeString(attrib.Description);
			}
		}
开发者ID:m-berkani,项目名称:ClearCanvas,代码行数:22,代码来源:Folder.cs


注:本文中的IResourceResolver.LocalizeString方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。