[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 06:52:15 UTC 2009


The following commit has been merged in the debian/unstable branch:
commit e99987378b15bac0f2fc00c85eb7b7c51cafc96d
Author: darin <darin at 268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Date:   Tue Oct 22 20:57:51 2002 +0000

    	- fixed 3077305 -- js dialog not yet implemented - crash (fatal error)
    
            * WebCoreSupport.subproj/WebViewFactory.m:
            (-[WebViewFactory runJavaScriptTextInputPanelWithPrompt:defaultText:returningText:]):
    	Create a WebJavaScriptTextInputPanel and run it.
    
            * English.lproj/WebJavaScriptTextInputPanel.nib: Added.
            * WebCoreSupport.subproj/WebJavaScriptTextInputPanel.h: Added.
            * WebCoreSupport.subproj/WebJavaScriptTextInputPanel.m: Added.
            * WebKit.pbproj/project.pbxproj: Added
    
    
    git-svn-id: http://svn.webkit.org/repository/webkit/trunk@2411 268f45cc-cd09-0410-ab3c-d52691b4dbfc

diff --git a/WebKit/ChangeLog b/WebKit/ChangeLog
index fc47a74..fa6a9b1 100644
--- a/WebKit/ChangeLog
+++ b/WebKit/ChangeLog
@@ -1,3 +1,16 @@
+2002-10-22  Darin Adler  <darin at apple.com>
+
+	- fixed 3077305 -- js dialog not yet implemented - crash (fatal error)
+
+        * WebCoreSupport.subproj/WebViewFactory.m:
+        (-[WebViewFactory runJavaScriptTextInputPanelWithPrompt:defaultText:returningText:]):
+	Create a WebJavaScriptTextInputPanel and run it.
+
+        * English.lproj/WebJavaScriptTextInputPanel.nib: Added.
+        * WebCoreSupport.subproj/WebJavaScriptTextInputPanel.h: Added.
+        * WebCoreSupport.subproj/WebJavaScriptTextInputPanel.m: Added.
+        * WebKit.pbproj/project.pbxproj: Added 
+
 2002-10-22  Chris Blumenberg  <cblu at apple.com>
 
 	Use the mouseDown point instead of the mouseDragged point to determine the mouseOffset when dragging images. When you drag an image now, the point where you clicked is the point where the cursor is in relation to the drag image.
diff --git a/WebKit/ChangeLog-2002-12-03 b/WebKit/ChangeLog-2002-12-03
index fc47a74..fa6a9b1 100644
--- a/WebKit/ChangeLog-2002-12-03
+++ b/WebKit/ChangeLog-2002-12-03
@@ -1,3 +1,16 @@
+2002-10-22  Darin Adler  <darin at apple.com>
+
+	- fixed 3077305 -- js dialog not yet implemented - crash (fatal error)
+
+        * WebCoreSupport.subproj/WebViewFactory.m:
+        (-[WebViewFactory runJavaScriptTextInputPanelWithPrompt:defaultText:returningText:]):
+	Create a WebJavaScriptTextInputPanel and run it.
+
+        * English.lproj/WebJavaScriptTextInputPanel.nib: Added.
+        * WebCoreSupport.subproj/WebJavaScriptTextInputPanel.h: Added.
+        * WebCoreSupport.subproj/WebJavaScriptTextInputPanel.m: Added.
+        * WebKit.pbproj/project.pbxproj: Added 
+
 2002-10-22  Chris Blumenberg  <cblu at apple.com>
 
 	Use the mouseDown point instead of the mouseDragged point to determine the mouseOffset when dragging images. When you drag an image now, the point where you clicked is the point where the cursor is in relation to the drag image.
diff --git a/WebKit/English.lproj/WebJavaScriptTextInputPanel.nib/classes.nib b/WebKit/English.lproj/WebJavaScriptTextInputPanel.nib/classes.nib
new file mode 100644
index 0000000..baa439b
--- /dev/null
+++ b/WebKit/English.lproj/WebJavaScriptTextInputPanel.nib/classes.nib
@@ -0,0 +1,14 @@
+{
+    IBClasses = (
+        {CLASS = FirstResponder; LANGUAGE = ObjC; SUPERCLASS = NSObject; }, 
+        {
+            ACTIONS = {pressedCancel = id; pressedOK = id; }; 
+            CLASS = WebJavaScriptTextInputPanel; 
+            LANGUAGE = ObjC; 
+            OUTLETS = {prompt = NSTextField; textInput = NSTextField; }; 
+            SUPERCLASS = NSWindowController; 
+        }, 
+        {CLASS = "java.lang.Object"; LANGUAGE = Java; }
+    ); 
+    IBVersion = 1; 
+}
\ No newline at end of file
diff --git a/WebKit/Panels.subproj/English.lproj/WebAuthenticationPanel.nib/info.nib b/WebKit/English.lproj/WebJavaScriptTextInputPanel.nib/info.nib
similarity index 83%
copy from WebKit/Panels.subproj/English.lproj/WebAuthenticationPanel.nib/info.nib
copy to WebKit/English.lproj/WebJavaScriptTextInputPanel.nib/info.nib
index 7904dfe..d775aaf 100644
--- a/WebKit/Panels.subproj/English.lproj/WebAuthenticationPanel.nib/info.nib
+++ b/WebKit/English.lproj/WebJavaScriptTextInputPanel.nib/info.nib
@@ -3,12 +3,12 @@
 <plist version="1.0">
 <dict>
 	<key>IBDocumentLocation</key>
-	<string>194 447 356 240 0 0 1024 746 </string>
+	<string>500 216 460 474 0 0 1600 1002 </string>
 	<key>IBFramework Version</key>
 	<string>283.0</string>
 	<key>IBOpenObjects</key>
 	<array>
-		<integer>5</integer>
+		<integer>10</integer>
 	</array>
 	<key>IBSystem Version</key>
 	<string>6D52</string>
diff --git a/WebKit/English.lproj/WebJavaScriptTextInputPanel.nib/keyedobjects.nib b/WebKit/English.lproj/WebJavaScriptTextInputPanel.nib/keyedobjects.nib
new file mode 100644
index 0000000..0b5d039
Binary files /dev/null and b/WebKit/English.lproj/WebJavaScriptTextInputPanel.nib/keyedobjects.nib differ
diff --git a/WebKit/WebCoreSupport.subproj/WebJavaScriptTextInputPanel.h b/WebKit/WebCoreSupport.subproj/WebJavaScriptTextInputPanel.h
new file mode 100644
index 0000000..df536a2
--- /dev/null
+++ b/WebKit/WebCoreSupport.subproj/WebJavaScriptTextInputPanel.h
@@ -0,0 +1,23 @@
+//
+//  WebJavaScriptTextInputPanel.h
+//  WebKit
+//
+//  Created by Darin Adler on Tue October 22 2002.
+//  Copyright (c) 2002 Apple Computer, Inc. All rights reserved.
+//
+
+#import <Cocoa/Cocoa.h>
+
+ at interface WebJavaScriptTextInputPanel : NSWindowController
+{
+    IBOutlet NSTextField *prompt;
+    IBOutlet NSTextField *textInput;
+}
+
+- (id)initWithPrompt:(NSString *)prompt text:(NSString *)text;
+- (NSString *)text;
+
+- (IBAction)pressedCancel:(id)sender;
+- (IBAction)pressedOK:(id)sender;
+
+ at end
diff --git a/WebKit/WebCoreSupport.subproj/WebJavaScriptTextInputPanel.m b/WebKit/WebCoreSupport.subproj/WebJavaScriptTextInputPanel.m
new file mode 100644
index 0000000..775e20f
--- /dev/null
+++ b/WebKit/WebCoreSupport.subproj/WebJavaScriptTextInputPanel.m
@@ -0,0 +1,54 @@
+//
+//  WebJavaScriptTextInputPanel.m
+//  WebKit
+//
+//  Created by Darin Adler on Tue October 22 2002.
+//  Copyright (c) 2002 Apple Computer, Inc. All rights reserved.
+//
+
+#import "WebJavaScriptTextInputPanel.h"
+
+ at implementation WebJavaScriptTextInputPanel
+
+- (id)initWithPrompt:(NSString *)p text:(NSString *)t
+{
+    [self initWithWindowNibName:@"WebJavaScriptTextInputPanel"];
+    NSWindow *window = [self window];
+    
+    // This must be done after the first call to [self window], because
+    // until then, prompt and textInput will be nil.
+    ASSERT(prompt);
+    ASSERT(textInput);
+    [prompt setStringValue:p];
+    [textInput setStringValue:t];
+
+    // Resize the prompt field, then the window, to account for the prompt text.
+    float promptHeightBefore = [prompt frame].size.height;
+    [prompt sizeToFit];
+    NSRect promptFrame = [prompt frame];
+    float heightDelta = promptFrame.size.height - promptHeightBefore;
+    promptFrame.origin.y -= heightDelta;
+    [prompt setFrame:promptFrame];
+    NSRect windowFrame = [window frame];
+    windowFrame.size.height += heightDelta;
+    [window setFrame:windowFrame display:NO];
+    
+    return self;
+}
+
+- (NSString *)text
+{
+    return [textInput stringValue];
+}
+
+- (IBAction)pressedCancel:(id)sender
+{
+    [NSApp stopModalWithCode:NO];
+}
+
+- (IBAction)pressedOK:(id)sender
+{
+    [NSApp stopModalWithCode:YES];
+}
+
+ at end
diff --git a/WebKit/WebCoreSupport.subproj/WebViewFactory.m b/WebKit/WebCoreSupport.subproj/WebViewFactory.m
index 7ef7208..9c72acb 100644
--- a/WebKit/WebCoreSupport.subproj/WebViewFactory.m
+++ b/WebKit/WebCoreSupport.subproj/WebViewFactory.m
@@ -7,13 +7,15 @@
 //
 
 #import <WebKit/WebBaseNetscapePluginView.h>
+
+#import <WebKit/WebJavaScriptTextInputPanel.h>
 #import <WebKit/WebNetscapePluginEmbeddedView.h>
 #import <WebKit/WebNullPluginView.h>
 #import <WebKit/WebPlugin.h>
 #import <WebKit/WebPluginDatabase.h>
 #import <WebKit/WebViewFactory.h>
-#import <WebFoundation/WebAssertions.h>
 
+#import <WebFoundation/WebAssertions.h>
 #import <WebFoundation/WebNSURLExtras.h>
 
 @implementation WebViewFactory
@@ -90,7 +92,14 @@
 
 - (BOOL)runJavaScriptTextInputPanelWithPrompt:(NSString *)prompt defaultText:(NSString *)defaultText returningText:(NSString **)result
 {
-    return NO;
+    WebJavaScriptTextInputPanel *panel = [[WebJavaScriptTextInputPanel alloc] initWithPrompt:prompt text:defaultText];
+    [panel showWindow:nil];
+    BOOL OK = [NSApp runModalForWindow:[panel window]];
+    if (OK) {
+        *result = [panel text];
+    }
+    [panel release];
+    return OK;
 }
 
 @end
diff --git a/WebKit/WebKit.pbproj/project.pbxproj b/WebKit/WebKit.pbproj/project.pbxproj
index 51b65a5..d7b9dfb 100644
--- a/WebKit/WebKit.pbproj/project.pbxproj
+++ b/WebKit/WebKit.pbproj/project.pbxproj
@@ -284,6 +284,7 @@
 				EDD9133E03576ADA00C1A526,
 				83402EF8035A588900BE770A,
 				83402EFC035A58D100BE770A,
+				9345D4EC0365C5B2008635CE,
 			);
 			isa = PBXHeadersBuildPhase;
 			runOnlyForDeploymentPostprocessing = 0;
@@ -295,7 +296,8 @@
 				35F357800198AAB80ACA1520,
 				F5B67131023EDF8901C1A525,
 				F5883BDF025E5C6A01000102,
-				F8CA15C0029A39FC01000122,
+				9345D17D0365BF35008635CE,
+				9345D4E90365C58D008635CE,
 			);
 			isa = PBXResourcesBuildPhase;
 			runOnlyForDeploymentPostprocessing = 0;
@@ -381,6 +383,7 @@
 				EDD9134003576AFF00C1A526,
 				83402EF9035A588900BE770A,
 				83402EFD035A58D100BE770A,
+				9345D4ED0365C5B2008635CE,
 			);
 			isa = PBXSourcesBuildPhase;
 			runOnlyForDeploymentPostprocessing = 0;
@@ -406,6 +409,7 @@
 				F5B67130023EDF8901C1A525,
 				F5883BDE025E5C6A01000102,
 				F5F732D202FF4D4F01A80180,
+				9345D4E70365C58D008635CE,
 			);
 			isa = PBXGroup;
 			name = Resources;
@@ -1499,6 +1503,72 @@
 			settings = {
 			};
 		};
+		9345D17B0365BF35008635CE = {
+			children = (
+				9345D17C0365BF35008635CE,
+			);
+			isa = PBXVariantGroup;
+			name = WebAuthenticationPanel.nib;
+			path = ..;
+			refType = 4;
+		};
+		9345D17C0365BF35008635CE = {
+			isa = PBXFileReference;
+			name = English;
+			path = Panels.subproj/English.lproj/WebAuthenticationPanel.nib;
+			refType = 4;
+		};
+		9345D17D0365BF35008635CE = {
+			fileRef = 9345D17B0365BF35008635CE;
+			isa = PBXBuildFile;
+			settings = {
+			};
+		};
+		9345D4E70365C58D008635CE = {
+			children = (
+				9345D4E80365C58D008635CE,
+			);
+			isa = PBXVariantGroup;
+			name = WebJavaScriptTextInputPanel.nib;
+			path = "";
+			refType = 4;
+		};
+		9345D4E80365C58D008635CE = {
+			isa = PBXFileReference;
+			name = English;
+			path = English.lproj/WebJavaScriptTextInputPanel.nib;
+			refType = 4;
+		};
+		9345D4E90365C58D008635CE = {
+			fileRef = 9345D4E70365C58D008635CE;
+			isa = PBXBuildFile;
+			settings = {
+			};
+		};
+		9345D4EA0365C5B2008635CE = {
+			fileEncoding = 4;
+			isa = PBXFileReference;
+			path = WebJavaScriptTextInputPanel.h;
+			refType = 4;
+		};
+		9345D4EB0365C5B2008635CE = {
+			fileEncoding = 4;
+			isa = PBXFileReference;
+			path = WebJavaScriptTextInputPanel.m;
+			refType = 4;
+		};
+		9345D4EC0365C5B2008635CE = {
+			fileRef = 9345D4EA0365C5B2008635CE;
+			isa = PBXBuildFile;
+			settings = {
+			};
+		};
+		9345D4ED0365C5B2008635CE = {
+			fileRef = 9345D4EB0365C5B2008635CE;
+			isa = PBXBuildFile;
+			settings = {
+			};
+		};
 		9367C636034E9F00008635C5 = {
 			fileEncoding = 4;
 			isa = PBXFileReference;
@@ -2596,6 +2666,8 @@
 				F5488CF502CB04EE01FF6274,
 				F5E7B24503025CE801A80180,
 				F5E7B24603025CE801A80180,
+				9345D4EA0365C5B2008635CE,
+				9345D4EB0365C5B2008635CE,
 			);
 			isa = PBXGroup;
 			name = "WebCore Support";
@@ -3129,7 +3201,7 @@
 				F8CA15C1029A3E0D01000122,
 				F83DCC71029D09F301000131,
 				F83DCC72029D09F301000131,
-				F8CA15BE029A39FC01000122,
+				9345D17B0365BF35008635CE,
 			);
 			isa = PBXGroup;
 			name = Panels;
@@ -3187,27 +3259,6 @@
 			settings = {
 			};
 		};
-		F8CA15BE029A39FC01000122 = {
-			children = (
-				F8CA15BF029A39FC01000122,
-			);
-			isa = PBXVariantGroup;
-			name = Panels.subproj;
-			path = "";
-			refType = 4;
-		};
-		F8CA15BF029A39FC01000122 = {
-			isa = PBXFileReference;
-			name = WebAuthenticationPanel.nib;
-			path = English.lproj/WebAuthenticationPanel.nib;
-			refType = 4;
-		};
-		F8CA15C0029A39FC01000122 = {
-			fileRef = F8CA15BE029A39FC01000122;
-			isa = PBXBuildFile;
-			settings = {
-			};
-		};
 		F8CA15C1029A3E0D01000122 = {
 			fileEncoding = 30;
 			isa = PBXFileReference;

-- 
WebKit Debian packaging



More information about the Pkg-webkit-commits mailing list