dev_split_view_vm
DESKTOP-3BO4HSG\ksat 2 years ago
parent b8c28da3d6
commit 60cc864fa8

@ -142,7 +142,7 @@ namespace STranslate
HotkeysHelper.InitialHook(this);
HotkeysHelper.Register(HotkeysHelper.InputTranslateId, () =>
{
InputTranslateMenuItem_Click(null, null);
vm.InputTranslate();
});
HotkeysHelper.Register(HotkeysHelper.CrosswordTranslateId, () =>

@ -38,8 +38,7 @@ namespace STranslate.ViewModel
//输入翻译
InputTranslateCmd = new RelayCommand((_) => true, (_) =>
{
ClearAll();
OpenMainWin();
InputTranslate();
});
//显示主界面
@ -138,12 +137,21 @@ namespace STranslate.ViewModel
/// <summary>
/// 打开主窗口
/// </summary>
private void OpenMainWin()
public void OpenMainWin()
{
mainwin.Show();
mainwin.Activate();
//TODO: add textbox focus
}
public void InputTranslate()
{
ClearAll();
OpenMainWin();
}
public void CrossWordTranslate()
{
}
/// <summary>
/// 初始化配置文件

Loading…
Cancel
Save