зеркало из https://github.com/mozilla/gecko-dev.git
fallback to the pasteboard string if we can't get the title string from the
core pasteboard url drag flavor. (bug 294001)
This commit is contained in:
Родитель
47608aa319
Коммит
a662f88884
|
@ -170,8 +170,13 @@ NSString* const kWebURLsWithTitlesPboardType = @"WebURLsWithTitlesPboardType";
|
|||
}
|
||||
} else if ([types containsObject:NSURLPboardType]) {
|
||||
*outUrls = [NSArray arrayWithObject:[[NSURL URLFromPasteboard:self] absoluteString]];
|
||||
if ([types containsObject:kCorePasteboardFlavorType_urld])
|
||||
*outTitles = [NSArray arrayWithObject:[self stringForType:kCorePasteboardFlavorType_urld]];
|
||||
if ([types containsObject:kCorePasteboardFlavorType_urld]) {
|
||||
NSString* title = [self stringForType:kCorePasteboardFlavorType_urld];
|
||||
if (!title)
|
||||
title = [self stringForType:NSStringPboardType];
|
||||
if (title)
|
||||
*outTitles = [NSArray arrayWithObject:title];
|
||||
}
|
||||
else
|
||||
*outTitles = [NSArray arrayWithObject:@""];
|
||||
} else if ([types containsObject:NSStringPboardType]) {
|
||||
|
|
Загрузка…
Ссылка в новой задаче