|
@@ -34,6 +34,8 @@ import Cocoa
|
|
|
|
|
|
var typeString: String = ""
|
|
|
|
|
|
+ @IBOutlet weak var listHeaderItemHConst: NSLayoutConstraint!
|
|
|
+
|
|
|
private var fileFormats_: [String] = ["jpg", "jpeg", "png", "gif", "bmp", "tiff", "tif", "psd", "svg", "pdf", "mp4", "mov", "avi", "mkv", "wmv", "flv", "mpg", "3gp", "doc", "docx", "xls" ,"xlsx", "ppt", "pptx", "txt", "rtf", "nfo"]
|
|
|
private var fileFormatsString = "jpg, jpeg, png, gif, bmp, tiff, tif, psd, svg, pdf, mp4, mov, avi, mkv, wmv, flv, mpg, 3gp, doc, docx, xls,xlsx, ppt, pptx, txt, rtf, nfo"
|
|
|
|
|
@@ -70,6 +72,10 @@ import Cocoa
|
|
|
self.listHeaderBox.borderWidth = 0
|
|
|
self.listBox.borderWidth = 0
|
|
|
|
|
|
+#if !VERSION_DMG
|
|
|
+ self.listHeaderItemHConst.constant = 44
|
|
|
+#endif
|
|
|
+
|
|
|
let email = VerificationManager.default()?.email ?? ""
|
|
|
self.emailItemView_?.textfiled.stringValue = email
|
|
|
|
|
@@ -206,6 +212,7 @@ import Cocoa
|
|
|
}
|
|
|
|
|
|
@objc private func _comfirmButtonAction() {
|
|
|
+#if VERSION_DMG
|
|
|
if let data = self.listHeaderItemView_?.checkButton.state, data == .on {
|
|
|
let fileaccess = AppSandboxFileAccess()
|
|
|
// /Users/kdanmobile/Library/Logs/DiagnosticReports
|
|
@@ -243,6 +250,7 @@ import Cocoa
|
|
|
} else {
|
|
|
self.logPath_ = nil
|
|
|
}
|
|
|
+#endif
|
|
|
|
|
|
self.window?.makeFirstResponder(nil)
|
|
|
let state = self._isConnectionAvailable()
|
|
@@ -271,11 +279,13 @@ import Cocoa
|
|
|
self.window?.contentView?.beginLoading()
|
|
|
self.comfirmButton.isEnabled = false
|
|
|
var filePaths: [String] = self.filePaths_
|
|
|
+#if VERSION_DMG
|
|
|
if let data = self.listHeaderItemView_?.checkButton.state, data == .on {
|
|
|
if let filePath = self.logPath_, filePath.isEmpty == false {
|
|
|
filePaths.append(filePath)
|
|
|
}
|
|
|
}
|
|
|
+#endif
|
|
|
|
|
|
self._feekbackAction(filePaths: filePaths) { [weak self] wrapper in
|
|
|
self?.window?.contentView?.endLoading()
|
|
@@ -384,6 +394,7 @@ import Cocoa
|
|
|
}
|
|
|
}
|
|
|
|
|
|
+#if VERSION_DMG
|
|
|
private func _getLog() -> String {
|
|
|
let url = FileManager.default.urls(for: .libraryDirectory, in: .userDomainMask).first
|
|
|
let coms = url?.pathComponents ?? []
|
|
@@ -435,6 +446,7 @@ import Cocoa
|
|
|
}
|
|
|
return ""
|
|
|
}
|
|
|
+#endif
|
|
|
|
|
|
private func _runShellCommand(_ command: String) -> String {
|
|
|
let task = Process()
|