[SCM] WebKit Debian packaging branch, debian/unstable, updated. debian/1.1.15-1-40151-g37bb677
darin
darin at 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Sat Sep 26 07:41:57 UTC 2009
The following commit has been merged in the debian/unstable branch:
commit d37186b9ecb7d570457626844529c8a7316c748c
Author: darin <darin at 268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Date: Tue May 13 20:15:55 2003 +0000
WebCore:
Reviewed by Ken.
- fixed 3120355 -- importing IE favorites garbles non-ASCII characters (esp. bad for non-Roman languages)
* kwq/WebCoreEncodings.h: Added decodeData:, removed all other (unused) methods.
* kwq/WebCoreEncodings.mm: (+[WebCoreEncodings decodeData:]): Added. Calls the same
decoder used to decode web pages.
WebKit:
Reviewed by Ken.
- fixed 3120355 -- importing IE favorites garbles non-ASCII characters (esp. bad for non-Roman languages)
* WebView.subproj/WebViewPrivate.h: Added _decodeData:.
* WebView.subproj/WebViewPrivate.m: (+[WebView _decodeData:]): Added. Calls through to WebCore.
WebBrowser:
Reviewed by Ken.
- fixed 3120355 -- importing IE favorites garbles non-ASCII characters (esp. bad for non-Roman languages)
* WebBookmarkImporter.m: (-[WebBookmarkImporter initWithPath:]):
Use new SPI call that decodes taking encoding into account, since the bookmarks
file uses the same kinds of encoding techniques as web pages.
git-svn-id: http://svn.webkit.org/repository/webkit/trunk@4361 268f45cc-cd09-0410-ab3c-d52691b4dbfc
diff --git a/WebCore/ChangeLog-2003-10-25 b/WebCore/ChangeLog-2003-10-25
index 417c023..bcc8ee2 100644
--- a/WebCore/ChangeLog-2003-10-25
+++ b/WebCore/ChangeLog-2003-10-25
@@ -1,5 +1,15 @@
2003-05-13 Darin Adler <darin at apple.com>
+ Reviewed by Ken.
+
+ - fixed 3120355 -- importing IE favorites garbles non-ASCII characters (esp. bad for non-Roman languages)
+
+ * kwq/WebCoreEncodings.h: Added decodeData:, removed all other (unused) methods.
+ * kwq/WebCoreEncodings.mm: (+[WebCoreEncodings decodeData:]): Added. Calls the same
+ decoder used to decode web pages.
+
+2003-05-13 Darin Adler <darin at apple.com>
+
Reviewed by John.
- fixed 3228186 -- REGRESSION: crash walking parent tree at housingscc.org in DOM::StyleBaseImpl::stylesheet()
diff --git a/WebCore/ChangeLog-2005-08-23 b/WebCore/ChangeLog-2005-08-23
index 417c023..bcc8ee2 100644
--- a/WebCore/ChangeLog-2005-08-23
+++ b/WebCore/ChangeLog-2005-08-23
@@ -1,5 +1,15 @@
2003-05-13 Darin Adler <darin at apple.com>
+ Reviewed by Ken.
+
+ - fixed 3120355 -- importing IE favorites garbles non-ASCII characters (esp. bad for non-Roman languages)
+
+ * kwq/WebCoreEncodings.h: Added decodeData:, removed all other (unused) methods.
+ * kwq/WebCoreEncodings.mm: (+[WebCoreEncodings decodeData:]): Added. Calls the same
+ decoder used to decode web pages.
+
+2003-05-13 Darin Adler <darin at apple.com>
+
Reviewed by John.
- fixed 3228186 -- REGRESSION: crash walking parent tree at housingscc.org in DOM::StyleBaseImpl::stylesheet()
diff --git a/WebCore/kwq/WebCoreEncodings.h b/WebCore/kwq/WebCoreEncodings.h
index 00c97cc..1e22b7b 100644
--- a/WebCore/kwq/WebCoreEncodings.h
+++ b/WebCore/kwq/WebCoreEncodings.h
@@ -25,8 +25,6 @@
#import <Foundation/Foundation.h>
-
@interface WebCoreEncodings : NSObject
-+ (NSString *)charsetNameForEncoding:(CFStringEncoding)encoding;
-+ (CFStringEncoding)encodingForCharsetName:(NSString *)charsetName;
++ (NSString *)decodeData:(NSData *)encoding;
@end
diff --git a/WebCore/kwq/WebCoreEncodings.mm b/WebCore/kwq/WebCoreEncodings.mm
index bfb729b..ab7dd70 100644
--- a/WebCore/kwq/WebCoreEncodings.mm
+++ b/WebCore/kwq/WebCoreEncodings.mm
@@ -24,18 +24,17 @@
*/
#import "WebCoreEncodings.h"
-#import "KWQCharsets.h"
- at implementation WebCoreEncodings
+#import "decoder.h"
-+ (NSString *)charsetNameForEncoding:(CFStringEncoding)encoding
-{
- return [NSString stringWithCString:KWQCFStringEncodingToIANACharsetName(encoding)];
-}
+ at implementation WebCoreEncodings
-+ (CFStringEncoding)encodingForCharsetName:(NSString *)charsetName
++ (NSString *)decodeData:(NSData *)data
{
- return KWQCFStringEncodingFromIANACharsetName([charsetName lossyCString]);
+ khtml::Decoder decoder;
+ QString result = decoder.decode(static_cast<const char *>([data bytes]), [data length]);
+ result += decoder.flush();
+ return result.getNSString();
}
@end
diff --git a/WebKit/ChangeLog b/WebKit/ChangeLog
index 3c31d1d..41c0f0b 100644
--- a/WebKit/ChangeLog
+++ b/WebKit/ChangeLog
@@ -1,3 +1,12 @@
+2003-05-13 Darin Adler <darin at apple.com>
+
+ Reviewed by Ken.
+
+ - fixed 3120355 -- importing IE favorites garbles non-ASCII characters (esp. bad for non-Roman languages)
+
+ * WebView.subproj/WebViewPrivate.h: Added _decodeData:.
+ * WebView.subproj/WebViewPrivate.m: (+[WebView _decodeData:]): Added. Calls through to WebCore.
+
2003-05-13 Maciej Stachowiak <mjs at apple.com>
Reviewed by Darin.
diff --git a/WebKit/WebView.subproj/WebViewPrivate.h b/WebKit/WebView.subproj/WebViewPrivate.h
index f783f69..63b9314 100644
--- a/WebKit/WebView.subproj/WebViewPrivate.h
+++ b/WebKit/WebView.subproj/WebViewPrivate.h
@@ -193,6 +193,8 @@ Could be worth adding to the API.
*/
+ (BOOL)_canHandleRequest:(NSURLRequest *)request;
++ (NSString *)_decodeData:(NSData *)data;
+
@end
@interface _WebSafeForwarder : NSObject
diff --git a/WebKit/WebView.subproj/WebViewPrivate.m b/WebKit/WebView.subproj/WebViewPrivate.m
index 7235c42..6176b17 100644
--- a/WebKit/WebView.subproj/WebViewPrivate.m
+++ b/WebKit/WebView.subproj/WebViewPrivate.m
@@ -3,6 +3,8 @@
Copyright (c) 2001, 2002, Apple, Inc. All rights reserved.
*/
+#import <WebKit/WebViewPrivate.h>
+
#import <WebKit/WebBackForwardList.h>
#import <WebKit/WebControllerSets.h>
#import <WebKit/WebDataSourcePrivate.h>
@@ -19,7 +21,6 @@
#import <WebKit/WebNSPasteboardExtras.h>
#import <WebKit/WebPreferencesPrivate.h>
#import <WebKit/WebResourceLoadDelegate.h>
-#import <WebKit/WebViewPrivate.h>
#import <WebKit/WebUIDelegate.h>
#import <WebFoundation/WebAssertions.h>
@@ -31,6 +32,7 @@
#import <WebFoundation/NSURLDownloadPrivate.h>
#import <WebFoundation/NSURLRequest.h>
+#import <WebCore/WebCoreEncodings.h>
#import <WebCore/WebCoreSettings.h>
static NSMutableSet *schemesWithRepresentationsSet;
@@ -597,6 +599,11 @@ static NSMutableSet *schemesWithRepresentationsSet;
return [self _representationExistsForURLScheme:[[request URL] scheme]];
}
++ (NSString *)_decodeData:(NSData *)data
+{
+ return [WebCoreEncodings decodeData:data];
+}
+
@end
--
WebKit Debian packaging
More information about the Pkg-webkit-commits
mailing list