Commit 9332bfeb authored by cblu's avatar cblu

Fixed: 3020720 - dropping a folder in the page address makes the folder open...

	Fixed: 3020720 - dropping a folder in the page address makes the folder open in Finder, empties the field

        * Misc.subproj/WebNSPasteboardExtras.m:
        (-[NSPasteboard _web_bestURL]): Don't accept directories.


git-svn-id: http://svn.webkit.org/repository/webkit/trunk@2767 268f45cc-cd09-0410-ab3c-d52691b4dbfc
parent d0ba328e
2002-11-19 Chris Blumenberg <cblu@apple.com>
Fixed: 3020720 - dropping a folder in the page address makes the folder open in Finder, empties the field
* Misc.subproj/WebNSPasteboardExtras.m:
(-[NSPasteboard _web_bestURL]): Don't accept directories.
2002-11-19 Chris Blumenberg <cblu@apple.com>
Fixed: 3068112 - extra line breaks when copying from source window
......
2002-11-19 Chris Blumenberg <cblu@apple.com>
Fixed: 3020720 - dropping a folder in the page address makes the folder open in Finder, empties the field
* Misc.subproj/WebNSPasteboardExtras.m:
(-[NSPasteboard _web_bestURL]): Don't accept directories.
2002-11-19 Chris Blumenberg <cblu@apple.com>
Fixed: 3068112 - extra line breaks when copying from source window
......
......@@ -55,8 +55,11 @@ -(NSURL *)_web_bestURL
NSArray *files = [self propertyListForType:NSFilenamesPboardType];
if ([files count] == 1) {
NSString *file = [files objectAtIndex:0];
if ([WebController canShowFile:file]) {
return [[NSURL fileURLWithPath:file] _web_canonicalize];
BOOL isDirectory;
if([[NSFileManager defaultManager] fileExistsAtPath:file isDirectory:&isDirectory] && !isDirectory){
if ([WebController canShowFile:file]) {
return [[NSURL fileURLWithPath:file] _web_canonicalize];
}
}
}
}
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment