| Index: ios/chrome/browser/ui/browser_view_controller.mm
|
| diff --git a/ios/chrome/browser/ui/browser_view_controller.mm b/ios/chrome/browser/ui/browser_view_controller.mm
|
| index 2928fdc368e65249df970f0040e4a15ae657ad5d..83513d14823aefbee845c27c18342b1700d6507d 100644
|
| --- a/ios/chrome/browser/ui/browser_view_controller.mm
|
| +++ b/ios/chrome/browser/ui/browser_view_controller.mm
|
| @@ -2884,13 +2884,20 @@ - (void)overscrollActionsController:(OverscrollActionsController*)controller
|
| case OverscrollAction::CLOSE_TAB:
|
| [self closeCurrentTab];
|
| break;
|
| - case OverscrollAction::REFRESH:
|
| + case OverscrollAction::REFRESH: {
|
| if ([[[_model currentTab] webController] loadPhase] ==
|
| web::PAGE_LOADING) {
|
| [[_model currentTab] stopLoading];
|
| }
|
| - [[_model currentTab] reload];
|
| +
|
| + web::WebState* webState = [_model currentTab].webState;
|
| + if (webState)
|
| + // |check_for_repost| is true because the reload is explicitly initiated
|
| + // by the user.
|
| + webState->GetNavigationManager()->Reload(web::ReloadType::NORMAL,
|
| + true /* check_for_repost */);
|
| break;
|
| + }
|
| case OverscrollAction::NONE:
|
| NOTREACHED();
|
| break;
|
| @@ -3838,9 +3845,11 @@ - (IBAction)locationBarDidResignFirstResponder:(id)sender {
|
| // editing ends (i.e., editing was cancelled), restart the cancelled load.
|
| if (_locationBarEditCancelledLoad) {
|
| _locationBarEditCancelledLoad = NO;
|
| - if (!_toolbarModelIOS->IsLoading()) {
|
| - [[_model currentTab] reload];
|
| - }
|
| +
|
| + web::WebState* webState = [_model currentTab].webState;
|
| + if (!_toolbarModelIOS->IsLoading() && webState)
|
| + webState->GetNavigationManager()->Reload(web::ReloadType::NORMAL,
|
| + false /* check_for_repost */);
|
| }
|
| }
|
|
|
| @@ -3981,9 +3990,15 @@ - (IBAction)chromeExecuteCommand:(id)sender {
|
| [super chromeExecuteCommand:sender];
|
| }
|
| break;
|
| - case IDC_RELOAD:
|
| - [[_model currentTab] reload];
|
| + case IDC_RELOAD: {
|
| + web::WebState* webState = [_model currentTab].webState;
|
| + if (webState)
|
| + // |check_for_repost| is true because the reload is explicitly initiated
|
| + // by the user.
|
| + webState->GetNavigationManager()->Reload(web::ReloadType::NORMAL,
|
| + true /* check_for_repost */);
|
| break;
|
| + }
|
| case IDC_SHARE_PAGE:
|
| [self sharePage];
|
| break;
|
|
|