|
@@ -57,6 +57,8 @@ namespace PDF_Office.ViewModels.Tools
|
|
InitPopMenu();
|
|
InitPopMenu();
|
|
SubscribeEvent();
|
|
SubscribeEvent();
|
|
}
|
|
}
|
|
|
|
+
|
|
|
|
+ //事件聚合器
|
|
private void SubscribeEvent()
|
|
private void SubscribeEvent()
|
|
{
|
|
{
|
|
Unicode = App.mainWindowViewModel.SelectedItem.Unicode;
|
|
Unicode = App.mainWindowViewModel.SelectedItem.Unicode;
|
|
@@ -82,8 +84,6 @@ namespace PDF_Office.ViewModels.Tools
|
|
AddBookMarkCommand = new DelegateCommand(AddBookMark_Click);
|
|
AddBookMarkCommand = new DelegateCommand(AddBookMark_Click);
|
|
PropertyRegionName = Guid.NewGuid().ToString();
|
|
PropertyRegionName = Guid.NewGuid().ToString();
|
|
HandCommand = new DelegateCommand<object>(Hand_Click);
|
|
HandCommand = new DelegateCommand<object>(Hand_Click);
|
|
- //ESC
|
|
|
|
- EscCommand = new DelegateCommand(Esc_KeyDown);
|
|
|
|
|
|
|
|
#region 注释 - 右键菜单
|
|
#region 注释 - 右键菜单
|
|
|
|
|
|
@@ -111,37 +111,12 @@ namespace PDF_Office.ViewModels.Tools
|
|
#endregion 注释 - 右键菜单
|
|
#endregion 注释 - 右键菜单
|
|
}
|
|
}
|
|
|
|
|
|
- private void Esc_KeyDown()
|
|
|
|
- {
|
|
|
|
- //PDFViewer.SetMouseMode(MouseModes.None);
|
|
|
|
- }
|
|
|
|
-
|
|
|
|
private void Hand_Click(object obj)
|
|
private void Hand_Click(object obj)
|
|
{
|
|
{
|
|
- if (obj is WrapPanel wrapPanel)
|
|
|
|
|
|
+ HandToolIsCheckedEvent(BtnHandIsChecked);
|
|
|
|
+ if (BtnHandIsChecked)
|
|
{
|
|
{
|
|
- foreach (var item in wrapPanel.Children)
|
|
|
|
- {
|
|
|
|
- if (item is CustomIconToggleBtn customIconToggle)
|
|
|
|
- {
|
|
|
|
- if (customIconToggle.Name == "BtnHand")
|
|
|
|
- {
|
|
|
|
- HandToolIsCheckedEvent((bool)customIconToggle.IsChecked);
|
|
|
|
- }
|
|
|
|
- //if (customIconToggle.Name == "BtnHand")
|
|
|
|
- //{
|
|
|
|
- // BtnHandIsChecked = (bool)customIconToggle.IsChecked;
|
|
|
|
- //}
|
|
|
|
- if (BtnHandIsChecked)
|
|
|
|
- {
|
|
|
|
- if (customIconToggle.Name != "BtnShowAnnot" && customIconToggle.Name != "BtnHand")
|
|
|
|
- {
|
|
|
|
- customIconToggle.IsChecked = false;
|
|
|
|
- }
|
|
|
|
- }
|
|
|
|
- }
|
|
|
|
- }
|
|
|
|
-
|
|
|
|
|
|
+ StrAnnotToolChecked = "";
|
|
viewContentViewModel.SelectedPrpoertyPanel("PropertyPanelContent", null);
|
|
viewContentViewModel.SelectedPrpoertyPanel("PropertyPanelContent", null);
|
|
}
|
|
}
|
|
}
|
|
}
|