[SCM] WebKit Debian packaging branch, debian/unstable, updated. debian/1.1.15-1-40151-g37bb677
cblu
cblu at 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Sat Sep 26 07:07:50 UTC 2009
The following commit has been merged in the debian/unstable branch:
commit 8187a4666914ecd7d31798fa0557f862dba1e888
Author: cblu <cblu at 268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Date: Mon Nov 25 00:26:04 2002 +0000
Fixed: 3109945 - Assertion failure in -[WebIconDatabase_largestIconFromDictionary:]
Added error strings for download decoding errors.
* English.lproj/Localizable.strings: Added error strings for download decoding errors
* English.lproj/StringsNotToBeLocalized.txt:
* Misc.subproj/WebIconDatabase.m:
(-[WebIconDatabase _loadIconDictionaries]): tweak
(-[WebIconDatabase _updateFileDatabase]): more error checking to prevent assert
(-[WebIconDatabase _setIconURL:forSiteURL:]): added asserts to prevent a site URL <-> icon URL mapping without a icon URL -> icon mapping
(-[WebIconDatabase _largestIconFromDictionary:]): tweak
* Misc.subproj/WebNSPasteboardExtras.m:
(-[NSPasteboard _web_writeURL:andTitle:withOwner:]): declare pboard types if none have been declared, else append types
* WebView.subproj/WebView.m:
(+[WebView initialize]): Added error strings for download decoding errors
git-svn-id: http://svn.webkit.org/repository/webkit/trunk@2852 268f45cc-cd09-0410-ab3c-d52691b4dbfc
diff --git a/WebKit/ChangeLog b/WebKit/ChangeLog
index e1e0a38..1f14247 100644
--- a/WebKit/ChangeLog
+++ b/WebKit/ChangeLog
@@ -1,3 +1,20 @@
+2002-11-24 Chris Blumenberg <cblu at apple.com>
+
+ Fixed: 3109945 - Assertion failure in -[WebIconDatabase_largestIconFromDictionary:]
+ Added error strings for download decoding errors.
+
+ * English.lproj/Localizable.strings: Added error strings for download decoding errors
+ * English.lproj/StringsNotToBeLocalized.txt:
+ * Misc.subproj/WebIconDatabase.m:
+ (-[WebIconDatabase _loadIconDictionaries]): tweak
+ (-[WebIconDatabase _updateFileDatabase]): more error checking to prevent assert
+ (-[WebIconDatabase _setIconURL:forSiteURL:]): added asserts to prevent a site URL <-> icon URL mapping without a icon URL -> icon mapping
+ (-[WebIconDatabase _largestIconFromDictionary:]): tweak
+ * Misc.subproj/WebNSPasteboardExtras.m:
+ (-[NSPasteboard _web_writeURL:andTitle:withOwner:]): declare pboard types if none have been declared, else append types
+ * WebView.subproj/WebView.m:
+ (+[WebView initialize]): Added error strings for download decoding errors
+
2002-11-24 Maciej Stachowiak <mjs at apple.com>
- fixed 3067939 - no support for window.document.lastModified
diff --git a/WebKit/ChangeLog-2002-12-03 b/WebKit/ChangeLog-2002-12-03
index e1e0a38..1f14247 100644
--- a/WebKit/ChangeLog-2002-12-03
+++ b/WebKit/ChangeLog-2002-12-03
@@ -1,3 +1,20 @@
+2002-11-24 Chris Blumenberg <cblu at apple.com>
+
+ Fixed: 3109945 - Assertion failure in -[WebIconDatabase_largestIconFromDictionary:]
+ Added error strings for download decoding errors.
+
+ * English.lproj/Localizable.strings: Added error strings for download decoding errors
+ * English.lproj/StringsNotToBeLocalized.txt:
+ * Misc.subproj/WebIconDatabase.m:
+ (-[WebIconDatabase _loadIconDictionaries]): tweak
+ (-[WebIconDatabase _updateFileDatabase]): more error checking to prevent assert
+ (-[WebIconDatabase _setIconURL:forSiteURL:]): added asserts to prevent a site URL <-> icon URL mapping without a icon URL -> icon mapping
+ (-[WebIconDatabase _largestIconFromDictionary:]): tweak
+ * Misc.subproj/WebNSPasteboardExtras.m:
+ (-[NSPasteboard _web_writeURL:andTitle:withOwner:]): declare pboard types if none have been declared, else append types
+ * WebView.subproj/WebView.m:
+ (+[WebView initialize]): Added error strings for download decoding errors
+
2002-11-24 Maciej Stachowiak <mjs at apple.com>
- fixed 3067939 - no support for window.document.lastModified
diff --git a/WebKit/English.lproj/Localizable.strings b/WebKit/English.lproj/Localizable.strings
index 548eabd..98b2fef 100644
Binary files a/WebKit/English.lproj/Localizable.strings and b/WebKit/English.lproj/Localizable.strings differ
diff --git a/WebKit/English.lproj/StringsNotToBeLocalized.txt b/WebKit/English.lproj/StringsNotToBeLocalized.txt
index 5d73b6f..b10a467 100644
--- a/WebKit/English.lproj/StringsNotToBeLocalized.txt
+++ b/WebKit/English.lproj/StringsNotToBeLocalized.txt
@@ -116,8 +116,8 @@
"WebHistoryEntriesRemovedNotification"
"WebHistoryLoadedNotification"
"WebHostToSiteURLs"
+"WebIconDatabaseDidAddIconNotification"
"WebIconDatabaseDirectory"
-"WebIconDidChangeNotification"
"WebIconNotificationUserInfoSiteURLKey"
"WebIconURLToSiteURLs"
"WebIconsOnDisk"
@@ -212,8 +212,6 @@ History.subproj/WebHistoryItem.m:"NO"
History.subproj/WebHistoryItem.m:"YES"
History.subproj/WebHistoryItem.m:"children"
History.subproj/WebHistoryItem.m:"title"
-Misc.subproj/WebIconDatabase.m:"Experiments"
-Misc.subproj/WebIconDatabase.m:"icon:%@"
Misc.subproj/WebKitLogging.m
Plugins.subproj/WebBasePluginPackage.m:"name: %@\npath: %@\nmimeTypes:\n%@\npluginDescription:%@"
Plugins.subproj/WebNetscapePluginPackage.m:"main"
diff --git a/WebKit/Misc.subproj/WebIconDatabase.m b/WebKit/Misc.subproj/WebIconDatabase.m
index 083427e..091e8e1 100644
--- a/WebKit/Misc.subproj/WebIconDatabase.m
+++ b/WebKit/Misc.subproj/WebIconDatabase.m
@@ -268,14 +268,14 @@ NSSize WebIconLargeSize = {128, 128};
{
WebFileDatabase *fileDB = _private->fileDatabase;
- _private->iconsOnDiskWithURLs = [fileDB objectForKey:WebIconsOnDiskKey];
- _private->siteURLToIconURL = [fileDB objectForKey:WebSiteURLToIconURLKey];
- _private->iconURLToSiteURLs = [fileDB objectForKey:WebIconURLToSiteURLsKey];
+ _private->iconsOnDiskWithURLs = [fileDB objectForKey:WebIconsOnDiskKey];
+ _private->siteURLToIconURL = [fileDB objectForKey:WebSiteURLToIconURLKey];
+ _private->iconURLToSiteURLs = [fileDB objectForKey:WebIconURLToSiteURLsKey];
if (![self _iconDictionariesAreGood]) {
_private->iconsOnDiskWithURLs = [NSMutableSet set];
- _private->siteURLToIconURL = [NSMutableDictionary dictionary];
- _private->iconURLToSiteURLs = [NSMutableDictionary dictionary];
+ _private->siteURLToIconURL = [NSMutableDictionary dictionary];
+ _private->iconURLToSiteURLs = [NSMutableDictionary dictionary];
}
[_private->iconsOnDiskWithURLs retain];
@@ -306,12 +306,14 @@ NSSize WebIconLargeSize = {128, 128};
while ((iconURLString = [enumerator nextObject]) != nil) {
NSMutableDictionary *icons = [_private->iconURLToIcons objectForKey:iconURLString];
- NSImage *icon = [self _largestIconFromDictionary:icons];
- NSData *iconData = [icon TIFFRepresentation];
- if(iconData){
- //NSLog(@"Writing icon: %@", iconURLString);
- [fileDB setObject:iconData forKey:iconURLString];
- [_private->iconsOnDiskWithURLs addObject:iconURLString];
+ if(icons){
+ NSImage *icon = [self _largestIconFromDictionary:icons];
+ NSData *iconData = [icon TIFFRepresentation];
+ if(iconData){
+ //NSLog(@"Writing icon: %@", iconURLString);
+ [fileDB setObject:iconData forKey:iconURLString];
+ [_private->iconsOnDiskWithURLs addObject:iconURLString];
+ }
}
}
@@ -326,7 +328,9 @@ NSSize WebIconLargeSize = {128, 128};
- (BOOL)_hasIconForIconURL:(NSURL *)iconURL;
{
- return ([_private->iconURLToSiteURLs objectForKey:[iconURL absoluteString]] != nil);
+ NSString *iconURLString = [iconURL absoluteString];
+ return ([_private->iconURLToIcons objectForKey:iconURLString] ||
+ [_private->iconsOnDiskWithURLs containsObject:iconURLString]);
}
- (NSMutableDictionary *)_iconsForIconURLString:(NSString *)iconURLString
@@ -410,12 +414,14 @@ NSSize WebIconLargeSize = {128, 128};
{
ASSERT(iconURL);
ASSERT(siteURL);
+ ASSERT([self _hasIconForIconURL:iconURL]);
+ ASSERT([_private->iconURLToRetainCount objectForKey:[iconURL absoluteString]]);
NSString *siteURLString = [siteURL absoluteString];
NSString *iconURLString = [iconURL absoluteString];
if([[_private->siteURLToIconURL objectForKey:siteURLString] isEqualToString:iconURLString]){
- // Don't do any work if the iconURL is already bound to the site URL
+ // Don't do any work if the icon URL is already bound to the site URL
return;
}
@@ -433,8 +439,6 @@ NSSize WebIconLargeSize = {128, 128};
if(futureRetainCount){
NSNumber *retainCount = [_private->iconURLToRetainCount objectForKey:iconURLString];
- ASSERT(retainCount);
-
int newRetainCount = [retainCount intValue] + [futureRetainCount intValue];
[_private->iconURLToRetainCount setObject:[NSNumber numberWithInt:newRetainCount] forKey:iconURLString];
[_private->futureSiteURLToRetainCount removeObjectForKey:siteURLString];
@@ -585,6 +589,7 @@ NSSize WebIconLargeSize = {128, 128};
- (NSImage *)_largestIconFromDictionary:(NSMutableDictionary *)icons
{
ASSERT(icons);
+
NSEnumerator *enumerator = [icons keyEnumerator];
NSValue *currentSize, *largestSize=nil;
float largestSizeArea=0;
diff --git a/WebKit/Misc.subproj/WebNSPasteboardExtras.m b/WebKit/Misc.subproj/WebNSPasteboardExtras.m
index 781e704..745213f 100644
--- a/WebKit/Misc.subproj/WebNSPasteboardExtras.m
+++ b/WebKit/Misc.subproj/WebNSPasteboardExtras.m
@@ -72,7 +72,11 @@ NSString *WebURLNamePboardType = nil;
ASSERT(URL);
NSArray *types = [NSArray arrayWithObjects:WebURLsWithTitlesPboardType, NSURLPboardType, NSStringPboardType, nil];
- [self declareTypes:types owner:owner];
+ if([self types] && [[self types] count] > 0){
+ [self addTypes:types owner:owner];
+ }else{
+ [self declareTypes:types owner:owner];
+ }
[URL writeToPasteboard:self];
[self setString:[URL absoluteString] forType:NSStringPboardType];
diff --git a/WebKit/WebView.subproj/WebFrameView.m b/WebKit/WebView.subproj/WebFrameView.m
index 639c0db..f392cdc 100644
--- a/WebKit/WebView.subproj/WebFrameView.m
+++ b/WebKit/WebView.subproj/WebFrameView.m
@@ -52,6 +52,8 @@ NSString *WebErrorDomainWebKit = @"WebErrorDomainWebKit";
#define WebErrorDescriptionWebErrorCannotFindPlugin UI_STRING("Cannot find plug-in", "WebErrorCannotFindPlugin description")
#define WebErrorDescriptionWebErrorCannotLoadPlugin UI_STRING("Cannot load plug-in", "WebErrorCannotLoadPlugin description")
#define WebErrorDescriptionWebErrorJavaUnavailable UI_STRING("Java is unavailable", "WebErrorJavaUnavailable description")
+#define WebErrorDescriptionDownloadDecodingFailedToComplete UI_STRING("Download decoding failed", "WebErrorDownloadDecodingFailedToComplete description")
+#define WebErrorDescriptionDownloadDecodingFailedMidStream UI_STRING("Download decoding failed", "WebErrorDownloadDecodingFailedMidStream description")
+ (void)initialize
{
@@ -69,6 +71,8 @@ NSString *WebErrorDomainWebKit = @"WebErrorDomainWebKit";
WebErrorDescriptionWebErrorCannotFindPlugin, [NSNumber numberWithInt: WebErrorCannotFindPlugin],
WebErrorDescriptionWebErrorCannotLoadPlugin, [NSNumber numberWithInt: WebErrorCannotLoadPlugin],
WebErrorDescriptionWebErrorJavaUnavailable, [NSNumber numberWithInt: WebErrorJavaUnavailable],
+ WebErrorDescriptionDownloadDecodingFailedToComplete,[NSNumber numberWithInt: WebErrorDownloadDecodingFailedToComplete],
+ WebErrorDescriptionDownloadDecodingFailedMidStream, [NSNumber numberWithInt: WebErrorDownloadDecodingFailedMidStream],
nil];
[WebError addErrorsWithCodesAndDescriptions:dict inDomain:WebErrorDomainWebKit];
--
WebKit Debian packaging
More information about the Pkg-webkit-commits
mailing list