mirror of
https://github.com/qvacua/vimr.git
synced 2024-11-25 06:06:21 +03:00
Add small improvements
This commit is contained in:
parent
feb9395fd5
commit
1811d131a3
@ -185,15 +185,15 @@ extension Workspace {
|
||||
self.proxyBar.removeFromSuperview()
|
||||
}
|
||||
|
||||
fileprivate func isFile(sender: NSDraggingInfo?) -> Bool! {
|
||||
return (sender?.draggingPasteboard().types?.contains(String(kUTTypeFileURL)))!
|
||||
fileprivate func isFile(sender: NSDraggingInfo?) -> Bool {
|
||||
return (sender?.draggingPasteboard().types?.contains(String(kUTTypeFileURL))) ?? false
|
||||
}
|
||||
|
||||
override func performDragOperation(_ sender: NSDraggingInfo) -> Bool {
|
||||
if isFile(sender: sender) {
|
||||
let paths = sender
|
||||
.draggingPasteboard()
|
||||
.propertyList(forType: "NSFilenamesPboardType") as? [String]
|
||||
.propertyList(forType: NSFilenamesPboardType) as? [String]
|
||||
self.open(filePaths: paths!)
|
||||
return true;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user