[SCM] WebKit Debian packaging branch, debian/unstable, updated. debian/1.1.15-1-40151-g37bb677
trey
trey at 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Sat Sep 26 07:24:13 UTC 2009
The following commit has been merged in the debian/unstable branch:
commit 3f01c6624011ab96c3892c13a55bc0fa5e4c165d
Author: trey <trey at 268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Date: Mon Feb 10 18:02:10 2003 +0000
Make sure we have a FormsDelegate installed with NOP behavior if our client
does not set one. Editing forms was broken for Ed by the introduction
of the new FormDelegate.
Reviewed by Darin.
* WebKit.pbproj/project.pbxproj: Added new header file.
* WebView.subproj/WebControllerPrivate.m:
(-[WebController _formDelegate]): Use shared delegate if none set yet.
* WebView.subproj/WebFormDelegatePrivate.h: New header.
* WebView.subproj/WebFormDelegate.h: Nit cleanup.
* WebView.subproj/WebFormDelegate.m:
(+[WebFormDelegate _sharedWebFormDelegate]): New method to return a shared
NOP implementation.
git-svn-id: http://svn.webkit.org/repository/webkit/trunk@3616 268f45cc-cd09-0410-ab3c-d52691b4dbfc
diff --git a/WebKit/ChangeLog b/WebKit/ChangeLog
index 5ccb2d0..d339501 100644
--- a/WebKit/ChangeLog
+++ b/WebKit/ChangeLog
@@ -1,3 +1,20 @@
+2003-02-10 Trey Matteson <trey at apple.com>
+
+ Make sure we have a FormsDelegate installed with NOP behavior if our client
+ does not set one. Editing forms was broken for Ed by the introduction
+ of the new FormDelegate.
+
+ Reviewed by Darin.
+
+ * WebKit.pbproj/project.pbxproj: Added new header file.
+ * WebView.subproj/WebControllerPrivate.m:
+ (-[WebController _formDelegate]): Use shared delegate if none set yet.
+ * WebView.subproj/WebFormDelegatePrivate.h: New header.
+ * WebView.subproj/WebFormDelegate.h: Nit cleanup.
+ * WebView.subproj/WebFormDelegate.m:
+ (+[WebFormDelegate _sharedWebFormDelegate]): New method to return a shared
+ NOP implementation.
+
2003-02-07 Richard Williamson <rjw at apple.com>
Changes to support per WebController preferences.
diff --git a/WebKit/WebKit.pbproj/project.pbxproj b/WebKit/WebKit.pbproj/project.pbxproj
index 8f48182..a4264bf 100644
--- a/WebKit/WebKit.pbproj/project.pbxproj
+++ b/WebKit/WebKit.pbproj/project.pbxproj
@@ -300,6 +300,7 @@
84A992C403CE696800CA2ACA,
8466AEDE03F1F82100CA2ACA,
8324709A03F32305003026AC,
+ 2D36FD5F03F78F9E00A80166,
);
isa = PBXHeadersBuildPhase;
runOnlyForDeploymentPostprocessing = 0;
@@ -578,6 +579,18 @@
//2D2
//2D3
//2D4
+ 2D36FD5E03F78F9E00A80166 = {
+ fileEncoding = 4;
+ isa = PBXFileReference;
+ path = WebFormDelegatePrivate.h;
+ refType = 4;
+ };
+ 2D36FD5F03F78F9E00A80166 = {
+ fileRef = 2D36FD5E03F78F9E00A80166;
+ isa = PBXBuildFile;
+ settings = {
+ };
+ };
2D81DAB203EB0B2D00A80166 = {
fileEncoding = 30;
isa = PBXFileReference;
@@ -2380,6 +2393,7 @@
3944606B020F50ED0ECA1767,
3944606C020F50ED0ECA1767,
2D81DAB203EB0B2D00A80166,
+ 2D36FD5E03F78F9E00A80166,
2D81DAB303EB0B2D00A80166,
39446074020F50ED0ECA1767,
F5143A370221DCCE01A80181,
diff --git a/WebKit/WebView.subproj/WebControllerPrivate.m b/WebKit/WebView.subproj/WebControllerPrivate.m
index c9cc10a..ed91cf6 100644
--- a/WebKit/WebView.subproj/WebControllerPrivate.m
+++ b/WebKit/WebView.subproj/WebControllerPrivate.m
@@ -5,7 +5,7 @@
#import <WebKit/WebBackForwardList.h>
#import <WebKit/WebContextMenuDelegate.h>
-#import <WebKit/WebFormDelegate.h>
+#import <WebKit/WebFormDelegatePrivate.h>
#import <WebKit/WebControllerPrivate.h>
#import <WebKit/WebControllerSets.h>
#import <WebKit/WebDataSourcePrivate.h>
@@ -353,6 +353,10 @@
- (id<WebFormDelegate>)_formDelegate
{
+ if (!_private->formDelegate) {
+ // create lazily, to give the client a chance to set one before we bother to alloc the shared one
+ _private->formDelegate = [WebFormDelegate _sharedWebFormDelegate];
+ }
return _private->formDelegate;
}
diff --git a/WebKit/WebView.subproj/WebFormDelegate.h b/WebKit/WebView.subproj/WebFormDelegate.h
index 7e5aa38..0dbb921 100644
--- a/WebKit/WebView.subproj/WebFormDelegate.h
+++ b/WebKit/WebView.subproj/WebFormDelegate.h
@@ -1,6 +1,6 @@
/*
WebFormDelegate.h
- Copyright 2001, 2002, Apple Computer, Inc.
+ Copyright 2003, Apple Computer, Inc.
Public header file.
*/
@@ -8,7 +8,6 @@
#import <AppKit/AppKit.h>
@class WebFrame;
- at protocol WebDOMElement;
/*!
@protocol WebFormDelegate
diff --git a/WebKit/WebView.subproj/WebFormDelegate.m b/WebKit/WebView.subproj/WebFormDelegate.m
index 7108018..9a9a381 100644
--- a/WebKit/WebView.subproj/WebFormDelegate.m
+++ b/WebKit/WebView.subproj/WebFormDelegate.m
@@ -3,10 +3,22 @@
Copyright 2003, Apple, Inc. All rights reserved.
*/
-#import "WebFormDelegate.h"
+#import "WebFormDelegatePrivate.h"
@implementation WebFormDelegate
+static WebFormDelegate *SharedDelegate = nil;
+
+// Return a object with NOP implementations of the protocol's methods
+// Note this feature relies on our default delegate being stateless
++ (WebFormDelegate *)_sharedWebFormDelegate
+{
+ if (!SharedDelegate) {
+ SharedDelegate = [[WebFormDelegate alloc] init];
+ }
+ return SharedDelegate;
+}
+
- (void)controlTextDidBeginEditing:(NSNotification *)obj inFrame:(WebFrame *)frame { }
- (void)controlTextDidEndEditing:(NSNotification *)obj inFrame:(WebFrame *)frame { }
diff --git a/WebKit/WebView.subproj/WebFormDelegatePrivate.h b/WebKit/WebView.subproj/WebFormDelegatePrivate.h
new file mode 100644
index 0000000..b51545e
--- /dev/null
+++ b/WebKit/WebView.subproj/WebFormDelegatePrivate.h
@@ -0,0 +1,11 @@
+/*
+ WebFormDelegatePrivate.h
+ Copyright 2003, Apple Computer, Inc.
+ */
+
+#import "WebFormDelegate.h"
+
+ at interface WebFormDelegate (WebPrivate)
++ (WebFormDelegate *)_sharedWebFormDelegate;
+ at end
+
diff --git a/WebKit/WebView.subproj/WebViewPrivate.m b/WebKit/WebView.subproj/WebViewPrivate.m
index c9cc10a..ed91cf6 100644
--- a/WebKit/WebView.subproj/WebViewPrivate.m
+++ b/WebKit/WebView.subproj/WebViewPrivate.m
@@ -5,7 +5,7 @@
#import <WebKit/WebBackForwardList.h>
#import <WebKit/WebContextMenuDelegate.h>
-#import <WebKit/WebFormDelegate.h>
+#import <WebKit/WebFormDelegatePrivate.h>
#import <WebKit/WebControllerPrivate.h>
#import <WebKit/WebControllerSets.h>
#import <WebKit/WebDataSourcePrivate.h>
@@ -353,6 +353,10 @@
- (id<WebFormDelegate>)_formDelegate
{
+ if (!_private->formDelegate) {
+ // create lazily, to give the client a chance to set one before we bother to alloc the shared one
+ _private->formDelegate = [WebFormDelegate _sharedWebFormDelegate];
+ }
return _private->formDelegate;
}
--
WebKit Debian packaging
More information about the Pkg-webkit-commits
mailing list