Changeset 188296 in webkit
- Timestamp:
- Aug 11, 2015, 2:26:08 PM (10 years ago)
- Location:
- branches/safari-601.1.46-branch/Source/WebKit2
- Files:
-
- 3 edited
-
ChangeLog (modified) (1 diff)
-
UIProcess/ios/WKActionSheetAssistant.mm (modified) (4 diffs)
-
UIProcess/ios/WKContentViewInteraction.mm (modified) (2 diffs)
Legend:
- Unmodified
- Added
- Removed
-
branches/safari-601.1.46-branch/Source/WebKit2/ChangeLog
r188235 r188296 1 2015-08-11 Matthew Hanson <matthew_hanson@apple.com> 2 3 Merge r188285. rdar://problem/22206433 4 5 2015-08-11 Beth Dakin <bdakin@apple.com> 6 7 REGRESSION (r188053): Sometimes unable to save an image from Google Search/ 8 imgur via long press 9 https://bugs.webkit.org/show_bug.cgi?id=147896 10 11 Reviewed by Enrica Casucci. 12 13 http://trac.webkit.org/changeset/188053 added code to call cleanupSheet when 14 the long press gesture is cancelled. However, the gesture will be called with 15 the cancelled state when then user taps an item in the action sheet (such as 16 “save image”), and sometimes the “cancel” comes in before the image has been 17 saved. That is a problem because we need to avoid cleaning up the sheet until 18 after the image is saved. Before that patch, we never cleaned up the sheet on 19 cancel, so this patch goes back to that behavior. We also have to remove some 20 assertions that assume that everything will be totally cleaned up when a new 21 sheet is created, but that is not necessarily true due to interactions 22 between the preview gesture and the long press gesture. 23 24 Remove assertions. 25 * UIProcess/ios/WKActionSheetAssistant.mm: 26 (-[WKActionSheetAssistant _createSheetWithElementActions:showLinkTitle:]): 27 (-[WKActionSheetAssistant showImageSheet]): 28 (-[WKActionSheetAssistant showLinkSheet]): 29 (-[WKActionSheetAssistant showDataDetectorsSheet]): 30 31 Revert the part of Enrica’s patch that called cleanupSheet when the gesture 32 is cancelled. 33 * UIProcess/ios/WKContentViewInteraction.mm: 34 (-[WKContentView _longPressRecognized:]): 35 1 36 2015-08-10 Babak Shafiei <bshafiei@apple.com> 2 37 -
branches/safari-601.1.46-branch/Source/WebKit2/UIProcess/ios/WKActionSheetAssistant.mm
r186734 r188296 207 207 - (void)_createSheetWithElementActions:(NSArray *)actions showLinkTitle:(BOOL)showLinkTitle 208 208 { 209 ASSERT(!_interactionSheet);210 209 auto delegate = _delegate.get(); 211 210 if (!delegate) … … 264 263 - (void)showImageSheet 265 264 { 266 ASSERT(!_interactionSheet);267 265 ASSERT(!_elementInfo); 268 266 … … 374 372 - (void)showLinkSheet 375 373 { 376 ASSERT(!_interactionSheet);377 374 ASSERT(!_elementInfo); 378 375 … … 407 404 - (void)showDataDetectorsSheet 408 405 { 409 ASSERT(!_interactionSheet);410 411 406 auto delegate = _delegate.get(); 412 407 if (!delegate) -
branches/safari-601.1.46-branch/Source/WebKit2/UIProcess/ios/WKContentViewInteraction.mm
r188197 r188296 1087 1087 _lastInteractionLocation = gestureRecognizer.startPoint; 1088 1088 1089 switch ([gestureRecognizer state]) { 1090 case UIGestureRecognizerStateBegan: 1091 { 1089 if ([gestureRecognizer state] == UIGestureRecognizerStateBegan) { 1092 1090 SEL action = [self _actionForLongPress]; 1093 1091 if (action) { … … 1095 1093 [self _cancelLongPressGestureRecognizer]; 1096 1094 } 1097 }1098 break;1099 case UIGestureRecognizerStateCancelled:1100 [_actionSheetAssistant cleanupSheet];1101 break;1102 default:1103 break;1104 1095 } 1105 1096 }
Note:
See TracChangeset
for help on using the changeset viewer.