static void Main()
{
Application.EnableVisualStyles();
Application.SetCompatibleTextRenderingDefault(false);
LocalizationKeys.LocalizeString += LocalizationKeys_LocalizeString;
Application.Run(new FormMain());
}
static void LocalizationKeys_LocalizeString(object sender, LocalizeEventArgs e)
{
if (e.Key == DevComponents.DotNetBar.LocalizationKeys.MessageBoxCancelButton)
{
e.LocalizedValue = "取消";
e.Handled = true;
}
if (e.Key == DevComponents.DotNetBar.LocalizationKeys.MessageBoxNoButton)
{
e.LocalizedValue = "取消";
e.Handled = true;
}
if (e.Key == DevComponents.DotNetBar.LocalizationKeys.MessageBoxOkButton)
{
e.LocalizedValue = "确定";
e.Handled = true;
}
if (e.Key == DevComponents.DotNetBar.LocalizationKeys.MessageBoxYesButton)
{
e.LocalizedValue = "确定";
e.Handled = true;
}
if (e.Key == DevComponents.DotNetBar.LocalizationKeys.MonthCalendarClearButtonText)
{
e.LocalizedValue = "清除";
e.Handled = true;
}
if (e.Key == DevComponents.DotNetBar.LocalizationKeys.MonthCalendarTodayButtonText)
{
e.LocalizedValue = "今天";
e.Handled = true;
}
if (e.Key == DevComponents.DotNetBar.LocalizationKeys.TimeSelectorHourLabel)
{
e.LocalizedValue = "时";
e.Handled = true;
}
if (e.Key == DevComponents.DotNetBar.LocalizationKeys.TimeSelectorMinuteLabel)
{
e.LocalizedValue = "分";
e.Handled = true;
}
if (e.Key == DevComponents.DotNetBar.LocalizationKeys.TimeSelectorClearButton)
{
e.LocalizedValue = "清除";
e.Handled = true;
}
if (e.Key == DevComponents.DotNetBar.LocalizationKeys.TimeSelectorOkButton)
{
e.LocalizedValue = "确定";
e.Handled = true;
}
}
|