|
@@ -1868,18 +1868,7 @@ extension KMBrowserWindowController: KMSystemToolMenuProtocol {
|
|
|
}
|
|
|
}
|
|
|
}
|
|
|
- @IBAction func addHeaderFooter(_ sender: Any?) {
|
|
|
- KMPrint("addHeaderFooter ...")
|
|
|
- }
|
|
|
- @IBAction func removeHeaderFooter(_ sender: Any?) {
|
|
|
- KMPrint("removeHeaderFooter ...")
|
|
|
- }
|
|
|
- @IBAction func addHeaderFooterBates(_ sender: Any?) {
|
|
|
- KMPrint("addHeaderFooterBates ...")
|
|
|
- }
|
|
|
- @IBAction func removeHeaderFooterBates(_ sender: Any?) {
|
|
|
- KMPrint("removeHeaderFooterBates ...")
|
|
|
- }
|
|
|
+
|
|
|
@IBAction func addWatermark(_ sender: Any?) {
|
|
|
if (self.canResponseDocumentAction() == false) {
|
|
|
return
|
|
@@ -1972,14 +1961,66 @@ extension KMBrowserWindowController: KMSystemToolMenuProtocol {
|
|
|
}
|
|
|
}
|
|
|
|
|
|
+ @IBAction func addHeaderFooter(_ sender: Any?) {
|
|
|
+ if (self.canResponseDocumentAction() == false) {
|
|
|
+ return
|
|
|
+ }
|
|
|
+ if let document = self.browser.activeTabContents() as? KMMainDocument {
|
|
|
+ if (document.isHome) {
|
|
|
+ } else {
|
|
|
+ document.mainViewController?.addHeaderFooter(sender)
|
|
|
+ }
|
|
|
+ }
|
|
|
+ }
|
|
|
+ @IBAction func removeHeaderFooter(_ sender: Any?) {
|
|
|
+ if (self.canResponseDocumentAction() == false) {
|
|
|
+ return
|
|
|
+ }
|
|
|
+ if let document = self.browser.activeTabContents() as? KMMainDocument {
|
|
|
+ if (document.isHome) {
|
|
|
+ } else {
|
|
|
+ document.mainViewController?.removeHeaderFooter(sender)
|
|
|
+ }
|
|
|
+ }
|
|
|
+ }
|
|
|
@IBAction func batchAddHeaderFooter(_ sender: Any?) {
|
|
|
- KMPrint("batchAddHeaderFooter ...")
|
|
|
+ if (self.canResponseDocumentAction() == false) {
|
|
|
+ return
|
|
|
+ }
|
|
|
+ if let document = self.browser.activeTabContents() as? KMMainDocument {
|
|
|
+ if (document.isHome) {
|
|
|
+ } else {
|
|
|
+ document.mainViewController?.batchAddHeaderFooter(sender)
|
|
|
+ }
|
|
|
+ }
|
|
|
}
|
|
|
@IBAction func batchRemoveHeaderFooter(_ sender: Any?) {
|
|
|
- KMPrint("batchRemoveHeaderFooter ...")
|
|
|
+ if (self.canResponseDocumentAction() == false) {
|
|
|
+ return
|
|
|
+ }
|
|
|
+ if let document = self.browser.activeTabContents() as? KMMainDocument {
|
|
|
+ if (document.isHome) {
|
|
|
+ } else {
|
|
|
+ document.mainViewController?.batchRemoveHeaderFooter(sender)
|
|
|
+ }
|
|
|
+ }
|
|
|
}
|
|
|
@IBAction func templateHeaderFooter(_ sender: Any?) {
|
|
|
- KMPrint("templateHeaderFooter ...")
|
|
|
+ if (self.canResponseDocumentAction() == false) {
|
|
|
+ return
|
|
|
+ }
|
|
|
+ if let document = self.browser.activeTabContents() as? KMMainDocument {
|
|
|
+ if (document.isHome) {
|
|
|
+ } else {
|
|
|
+ document.mainViewController?.templateHeaderFooter(sender)
|
|
|
+ }
|
|
|
+ }
|
|
|
+ }
|
|
|
+ @IBAction func addHeaderFooterBates(_ sender: Any?) {
|
|
|
+ KMPrint("addHeaderFooterBates ...")
|
|
|
+ }
|
|
|
+ @IBAction func removeHeaderFooterBates(_ sender: Any?) {
|
|
|
+ KMPrint("removeHeaderFooterBates ...")
|
|
|
}
|
|
|
@IBAction func batchAddBates(_ sender: Any?) {
|
|
|
KMPrint("batchAddBates ...")
|