|
@@ -302,6 +302,7 @@ namespace Compdfkit_Tools.PDFControl
|
|
|
if (PdfViewControl != null && PdfViewControl.PDFViewTool != null)
|
|
|
{
|
|
|
PdfViewControl.PDFViewTool.GetCPDFViewer()?.UndoManager?.Undo();
|
|
|
+ //PdfViewControl.PDFToolManager.ClearSelect();
|
|
|
PdfViewControl.PDFViewTool.GetCPDFViewer().UpDateRenderFrame();
|
|
|
}
|
|
|
}
|
|
@@ -311,6 +312,7 @@ namespace Compdfkit_Tools.PDFControl
|
|
|
if (PdfViewControl != null && PdfViewControl.PDFViewTool != null)
|
|
|
{
|
|
|
PdfViewControl.PDFViewTool.GetCPDFViewer()?.UndoManager?.Redo();
|
|
|
+ //PdfViewControl.PDFToolManager.ClearSelect();
|
|
|
PdfViewControl.PDFViewTool.GetCPDFViewer().UpDateRenderFrame();
|
|
|
}
|
|
|
}
|
|
@@ -375,17 +377,16 @@ namespace Compdfkit_Tools.PDFControl
|
|
|
switch (e.hitTestType)
|
|
|
{
|
|
|
case MouseHitTestType.kTextEdit:
|
|
|
- CreateEditTextMenu(sender, ref ContextMenu);
|
|
|
- break;
|
|
|
case MouseHitTestType.kImageEdit:
|
|
|
+ CreateEditMenu(sender, ref ContextMenu);
|
|
|
break;
|
|
|
default:
|
|
|
- ContextMenu = null;
|
|
|
+ ContextMenu.Items.Add(new MenuItem() { Header = "Paste", Command = ApplicationCommands.Paste, CommandTarget = (UIElement)sender });
|
|
|
break;
|
|
|
}
|
|
|
PdfViewControl.SetRightMenu(ContextMenu);
|
|
|
}
|
|
|
- private void CreateEditTextMenu(object sender, ref ContextMenu menu)
|
|
|
+ private void CreateEditMenu(object sender, ref ContextMenu menu)
|
|
|
{
|
|
|
menu.Items.Add(new MenuItem() { Header = "Delete", Command = ApplicationCommands.Delete, CommandTarget = (UIElement)sender });
|
|
|
menu.Items.Add(new MenuItem() { Header = "Copy", Command = ApplicationCommands.Copy, CommandTarget = (UIElement)sender });
|