|
@@ -1,4 +1,6 @@
|
|
|
-using DevExpress.XtraBars.Docking2010;
|
|
|
+using DevExpress.Data.Localization;
|
|
|
+using DevExpress.Utils.Localization;
|
|
|
+using DevExpress.XtraBars.Docking2010;
|
|
|
using DevExpress.XtraBars.Localization;
|
|
|
using DevExpress.XtraEditors;
|
|
|
using DevExpress.XtraEditors.Controls;
|
|
@@ -33,8 +35,20 @@ namespace XdCxRhDW
|
|
|
|
|
|
//Control
|
|
|
Localizer.Active = new ChsControlLocalizer();
|
|
|
+
|
|
|
+ XtraLocalizer.QueryLocalizedString += XtraLocalizer_QueryLocalizedString;
|
|
|
}
|
|
|
|
|
|
+ private static void XtraLocalizer_QueryLocalizedString(object sender, XtraLocalizer.QueryLocalizedStringEventArgs e)
|
|
|
+ {
|
|
|
+ if (e.StringIDType == typeof(StringId))
|
|
|
+ {
|
|
|
+ if ((StringId)e.StringID == StringId.FilterShowAll)
|
|
|
+ {
|
|
|
+ e.Value = "(全选)";
|
|
|
+ }
|
|
|
+ }
|
|
|
+ }
|
|
|
}
|
|
|
class ChsControlLocalizer : Localizer
|
|
|
{
|
|
@@ -70,6 +84,10 @@ namespace XdCxRhDW
|
|
|
return "输入搜索文本...";
|
|
|
case StringId.TabHeaderButtonClose:
|
|
|
return "关闭选项卡";
|
|
|
+ case StringId.OK:
|
|
|
+ return "确定";
|
|
|
+ case StringId.Cancel:
|
|
|
+ return "取消";
|
|
|
}
|
|
|
var res = base.GetLocalizedString(id);
|
|
|
return res;
|