Changeset 231944 in webkit
- Timestamp:
- May 17, 2018 10:51:40 PM (6 years ago)
- Location:
- branches/safari-606.1.17-branch
- Files:
-
- 1 added
- 5 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/safari-606.1.17-branch/Source/WebKit/ChangeLog
r231943 r231944 1 2018-05-17 Babak Shafiei <bshafiei@apple.com> 2 3 Cherry-pick r231591. rdar://problem/39290394 4 5 [Cocoa] Some fields are not identified as [WKWebProcessPlugInNodeHandle isTextField] 6 https://bugs.webkit.org/show_bug.cgi?id=185260 7 <rdar://problem/39290394> 8 9 Source/WebKit: 10 11 INPUT element are not considered to be text fields when 12 calling -[WKWebProcessPlugInNodeHandle isTextField] 13 when they are of type number. 14 15 Patch by Richard Houle <rhoule@apple.com> on 2018-05-09 16 Reviewed by Tim Horton. 17 18 * WebProcess/InjectedBundle/DOM/InjectedBundleNodeHandle.cpp: 19 (WebKit::InjectedBundleNodeHandle::isTextField const): 20 21 Tools: 22 23 Patch by Richard Houle <rhoule@apple.com> on 2018-05-09 24 Reviewed by Tim Horton. 25 26 * TestWebKitAPI/TestWebKitAPI.xcodeproj/project.pbxproj: 27 * TestWebKitAPI/Tests/WebKitCocoa/InjectedBundleNodeHandleIsTextField.mm: Added. 28 (-[InjectedBundleNodeHandleIsTextField isTextFieldForHTMLInputType:document:jsContext:]): 29 (-[InjectedBundleNodeHandleIsTextField webProcessPlugIn:didCreateBrowserContextController:]): 30 * TestWebKitAPI/Tests/WebKitCocoa/UIDelegate.mm: 31 (-[InjectedBundleNodeHandleIsTextFieldDelegate webView:runJavaScriptAlertPanelWithMessage:initiatedByFrame:completionHandler:]): 32 33 git-svn-id: https://svn.webkit.org/repository/webkit/trunk@231591 268f45cc-cd09-0410-ab3c-d52691b4dbfc 34 35 2018-05-09 Richard Houle <rhoule@apple.com> 36 37 [Cocoa] Some fields are not identified as [WKWebProcessPlugInNodeHandle isTextField] 38 https://bugs.webkit.org/show_bug.cgi?id=185260 39 <rdar://problem/39290394> 40 41 INPUT element are not considered to be text fields when 42 calling -[WKWebProcessPlugInNodeHandle isTextField] 43 when they are of type number. 44 45 Reviewed by Tim Horton. 46 47 * WebProcess/InjectedBundle/DOM/InjectedBundleNodeHandle.cpp: 48 (WebKit::InjectedBundleNodeHandle::isTextField const): 49 1 50 2018-05-17 Babak Shafiei <bshafiei@apple.com> 2 51 -
branches/safari-606.1.17-branch/Source/WebKit/WebProcess/InjectedBundle/DOM/InjectedBundleNodeHandle.cpp
r226048 r231944 335 335 return false; 336 336 337 return downcast<HTMLInputElement>(m_node.get()).isText ();337 return downcast<HTMLInputElement>(m_node.get()).isTextField(); 338 338 } 339 339 -
branches/safari-606.1.17-branch/Tools/ChangeLog
r231943 r231944 1 2018-05-17 Babak Shafiei <bshafiei@apple.com> 2 3 Cherry-pick r231591. rdar://problem/39290394 4 5 [Cocoa] Some fields are not identified as [WKWebProcessPlugInNodeHandle isTextField] 6 https://bugs.webkit.org/show_bug.cgi?id=185260 7 <rdar://problem/39290394> 8 9 Source/WebKit: 10 11 INPUT element are not considered to be text fields when 12 calling -[WKWebProcessPlugInNodeHandle isTextField] 13 when they are of type number. 14 15 Patch by Richard Houle <rhoule@apple.com> on 2018-05-09 16 Reviewed by Tim Horton. 17 18 * WebProcess/InjectedBundle/DOM/InjectedBundleNodeHandle.cpp: 19 (WebKit::InjectedBundleNodeHandle::isTextField const): 20 21 Tools: 22 23 Patch by Richard Houle <rhoule@apple.com> on 2018-05-09 24 Reviewed by Tim Horton. 25 26 * TestWebKitAPI/TestWebKitAPI.xcodeproj/project.pbxproj: 27 * TestWebKitAPI/Tests/WebKitCocoa/InjectedBundleNodeHandleIsTextField.mm: Added. 28 (-[InjectedBundleNodeHandleIsTextField isTextFieldForHTMLInputType:document:jsContext:]): 29 (-[InjectedBundleNodeHandleIsTextField webProcessPlugIn:didCreateBrowserContextController:]): 30 * TestWebKitAPI/Tests/WebKitCocoa/UIDelegate.mm: 31 (-[InjectedBundleNodeHandleIsTextFieldDelegate webView:runJavaScriptAlertPanelWithMessage:initiatedByFrame:completionHandler:]): 32 33 git-svn-id: https://svn.webkit.org/repository/webkit/trunk@231591 268f45cc-cd09-0410-ab3c-d52691b4dbfc 34 35 2018-05-09 Richard Houle <rhoule@apple.com> 36 37 [Cocoa] Some fields are not identified as [WKWebProcessPlugInNodeHandle isTextField] 38 https://bugs.webkit.org/show_bug.cgi?id=185260 39 <rdar://problem/39290394> 40 41 Reviewed by Tim Horton. 42 43 * TestWebKitAPI/TestWebKitAPI.xcodeproj/project.pbxproj: 44 * TestWebKitAPI/Tests/WebKitCocoa/InjectedBundleNodeHandleIsTextField.mm: Added. 45 (-[InjectedBundleNodeHandleIsTextField isTextFieldForHTMLInputType:document:jsContext:]): 46 (-[InjectedBundleNodeHandleIsTextField webProcessPlugIn:didCreateBrowserContextController:]): 47 * TestWebKitAPI/Tests/WebKitCocoa/UIDelegate.mm: 48 (-[InjectedBundleNodeHandleIsTextFieldDelegate webView:runJavaScriptAlertPanelWithMessage:initiatedByFrame:completionHandler:]): 49 1 50 2018-05-17 Babak Shafiei <bshafiei@apple.com> 2 51 -
branches/safari-606.1.17-branch/Tools/TestWebKitAPI/TestWebKitAPI.xcodeproj/project.pbxproj
r231321 r231944 294 294 76E182DD1547569100F1FADD /* WillSendSubmitEvent_Bundle.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 76E182DC1547569100F1FADD /* WillSendSubmitEvent_Bundle.cpp */; }; 295 295 76E182DF154767E600F1FADD /* auto-submitting-form.html in Copy Resources */ = {isa = PBXBuildFile; fileRef = 76E182DE15475A8300F1FADD /* auto-submitting-form.html */; }; 296 79C5D431209D768300F1E7CA /* InjectedBundleNodeHandleIsTextField.mm in Sources */ = {isa = PBXBuildFile; fileRef = 79C5D430209D768300F1E7CA /* InjectedBundleNodeHandleIsTextField.mm */; }; 296 297 7A010BCB1D877C0500EDE72A /* CoreGraphics.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 7A010BCA1D877C0500EDE72A /* CoreGraphics.framework */; }; 297 298 7A010BCD1D877C0D00EDE72A /* QuartzCore.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 7A010BCC1D877C0D00EDE72A /* QuartzCore.framework */; }; … … 1511 1512 76E182DC1547569100F1FADD /* WillSendSubmitEvent_Bundle.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = WillSendSubmitEvent_Bundle.cpp; sourceTree = "<group>"; }; 1512 1513 76E182DE15475A8300F1FADD /* auto-submitting-form.html */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.html; path = "auto-submitting-form.html"; sourceTree = "<group>"; }; 1514 79C5D430209D768300F1E7CA /* InjectedBundleNodeHandleIsTextField.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = InjectedBundleNodeHandleIsTextField.mm; sourceTree = "<group>"; }; 1513 1515 7A010BCA1D877C0500EDE72A /* CoreGraphics.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = CoreGraphics.framework; path = System/Library/Frameworks/CoreGraphics.framework; sourceTree = SDKROOT; }; 1514 1516 7A010BCC1D877C0D00EDE72A /* QuartzCore.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = QuartzCore.framework; path = System/Library/Frameworks/QuartzCore.framework; sourceTree = SDKROOT; }; … … 2192 2194 5198A23F1EA7E595008910B7 /* InitialWarmedProcessUsed.mm */, 2193 2195 2DB0232E1E4E871800707123 /* InteractionDeadlockAfterCrash.mm */, 2196 79C5D430209D768300F1E7CA /* InjectedBundleNodeHandleIsTextField.mm */, 2194 2197 5C69BDD41F82A7EB000F4F4B /* JavaScriptDuringNavigation.mm */, 2195 2198 C25CCA051E51380B0026CB8A /* LineBreaking.mm */, … … 3863 3866 37A709AF1E3EA97E00CA5969 /* BundleRangeHandlePlugIn.mm in Sources */, 3864 3867 1C2B81831C891F0900A5529F /* CancelFontSubresourcePlugIn.mm in Sources */, 3868 79C5D431209D768300F1E7CA /* InjectedBundleNodeHandleIsTextField.mm in Sources */, 3865 3869 5CB18BA81F5645E300EE23C4 /* ClickAutoFillButton.mm in Sources */, 3866 3870 A14FC58B1B89927100D107EB /* ContentFilteringPlugIn.mm in Sources */, -
branches/safari-606.1.17-branch/Tools/TestWebKitAPI/Tests/WebKitCocoa/UIDelegate.mm
r231519 r231944 628 628 } 629 629 630 @interface InjectedBundleNodeHandleIsTextFieldDelegate : NSObject <WKUIDelegatePrivate> 631 @end 632 633 @implementation InjectedBundleNodeHandleIsTextFieldDelegate 634 635 - (void)webView:(WKWebView *)webView runJavaScriptAlertPanelWithMessage:(NSString *)message initiatedByFrame:(WKFrameInfo *)frame completionHandler:(void (^)())completionHandler 636 { 637 completionHandler(); 638 ASSERT_STREQ(message.UTF8String, "isTextField success"); 639 done = true; 640 } 641 642 @end 643 644 TEST(WebKit, InjectedBundleNodeHandleIsTextField) 645 { 646 WKWebViewConfiguration *configuration = [WKWebViewConfiguration _test_configurationWithTestPlugInClassName:@"InjectedBundleNodeHandleIsTextField"]; 647 648 auto webView = adoptNS([[TestWKWebView alloc] initWithFrame:CGRectMake(0, 0, 800, 600) configuration:configuration]); 649 auto delegate = adoptNS([[InjectedBundleNodeHandleIsTextFieldDelegate alloc] init]); 650 [webView setUIDelegate:delegate.get()]; 651 TestWebKitAPI::Util::run(&done); 652 } 653 630 654 @interface PinnedStateObserver : NSObject 631 655 @end
Note: See TracChangeset
for help on using the changeset viewer.