Bug 139567 - [iOS] Predictions are not updated when using navigation buttons
Summary: [iOS] Predictions are not updated when using navigation buttons
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: WebKit2 (show other bugs)
Version: 528+ (Nightly build)
Hardware: Unspecified iOS 8.1
: P2 Normal
Assignee: Enrica Casucci
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2014-12-11 16:19 PST by Enrica Casucci
Modified: 2014-12-12 16:00 PST (History)
1 user (show)

See Also:


Attachments
Patch (8.44 KB, patch)
2014-12-11 16:34 PST, Enrica Casucci
mitz: review+
Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Enrica Casucci 2014-12-11 16:19:06 PST
Predictions on top of the on screen keyboard are not updated when changing focus using the navigation buttons.
We need to notify the keyboard that the selection has changed so that it can update the prediction bar.

rdar://problem/19132585
Comment 1 Enrica Casucci 2014-12-11 16:34:55 PST
Created attachment 243161 [details]
Patch
Comment 2 WebKit Commit Bot 2014-12-11 16:36:48 PST
Attachment 243161 [details] did not pass style-queue:


ERROR: Source/WebKit2/UIProcess/ios/WKContentViewInteraction.mm:153:  Should have space between @property and attributes.  [whitespace/property] [4]
ERROR: Source/WebKit2/UIProcess/ios/WKContentViewInteraction.mm:153:  Missing space after ,  [whitespace/comma] [3]
ERROR: Source/WebKit2/UIProcess/WebPageProxy.h:454:  Extra space before ( in function call  [whitespace/parens] [4]
ERROR: Source/WebKit2/UIProcess/ios/WebPageProxyIOS.mm:803:  Extra space before ( in function call  [whitespace/parens] [4]
Total errors found: 4 in 7 files


If any of these errors are false positives, please file a bug against check-webkit-style.
Comment 3 mitz 2014-12-11 16:55:53 PST
Comment on attachment 243161 [details]
Patch

View in context: https://bugs.webkit.org/attachment.cgi?id=243161&action=review

> Source/WebKit2/UIProcess/ios/WKContentViewInteraction.mm:1187
> +    return _formAccessoryView.get().buttonItems;

We normally don’t use dot syntax after get(), but instead prefer bracket syntax in this case.

I’m assuming it’s OK to call -buttonItems here without a runtime check, because this method will only be called if -buttonItems is defined. If I’m wrong, please add a -respondsToSelector check.
Comment 4 Enrica Casucci 2014-12-12 11:56:41 PST
(In reply to comment #3)
> Comment on attachment 243161 [details]
> Patch
> 
> View in context:
> https://bugs.webkit.org/attachment.cgi?id=243161&action=review
> 
> > Source/WebKit2/UIProcess/ios/WKContentViewInteraction.mm:1187
> > +    return _formAccessoryView.get().buttonItems;
> 
> We normally don’t use dot syntax after get(), but instead prefer bracket
> syntax in this case.
I will do as you suggested.
> 
> I’m assuming it’s OK to call -buttonItems here without a runtime check,
> because this method will only be called if -buttonItems is defined. If I’m
> wrong, please add a -respondsToSelector check.
Yes, it is OK.
Thanks for the review!
Comment 5 Enrica Casucci 2014-12-12 16:00:09 PST
Committed revision 177246.