Ver código fonte

【加密】设置权限加密后,将图片粘贴到文档,右键图片-剪切,提示要输入密码,点击取消后,图片仍会同步消失(已修复)

tangchao 1 ano atrás
pai
commit
e554af11b7

+ 9 - 0
PDF Office/PDF Master/Class/PDFWindowController/PDFListView/CPDFListViewExtension/CPDFListView+Event.m

@@ -3401,6 +3401,15 @@ static inline CPDFAreaOfInterest CAreaOfInterestForResizeHandle(CRectEdges mask,
 }
 
 - (IBAction)cut:(id)sender {
+    BOOL isContinue = YES;
+    if([self.pdfListViewDelegate respondsToSelector:@selector(PDFListViewHaveDocumentAttribute)]) {
+        isContinue = [self.pdfListViewDelegate PDFListViewHaveDocumentAttribute];
+    }
+    
+    if(!isContinue) {
+        return NSBeep();
+    }
+    
     [self copy:sender];
     [self delete:sender];
 }