Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

in iOS on InAppWebView alwaysBounceVertical: true, disallowOverScroll: false do not work. It never bounces. #517

Closed
5 tasks done
delay opened this issue Sep 11, 2020 · 4 comments
Labels
bug Something isn't working

Comments

@delay
Copy link

delay commented Sep 11, 2020

Environment

Technology Version
Flutter version Channel dev, 1.22.0-9.0.pre
Plugin version ^4.0.0+4
Android version
iOS version 13.7
Xcode version 11.7

Device information: iPhone X

Description

There is no bounce on InAppWebView on iOS like there is in native safari. I have enabled these two settings. alwaysBounceVertical: true, disallowOverScroll: false

Expected behavior:
I expect it to bounce when reaching the bottom or top of screen when scrolling.
Current behavior:
It doesn't bounce at all.

Steps to reproduce

Project to reproduce issue.

import 'dart:async';
import 'package:flutter/material.dart';
import 'package:flutter_inappwebview/flutter_inappwebview.dart';

Future main() async {
  WidgetsFlutterBinding.ensureInitialized();
  runApp(new Browser());
}

class Browser extends StatefulWidget {
  @override
  _BrowserState createState() => new _BrowserState();
}

class _BrowserState extends State<Browser> {
  InAppWebViewController _webViewController;
  String url = "";
  double progress = 0;

  @override
  Widget build(BuildContext context) {
    return MaterialApp(
      home: Scaffold(
        appBar: AppBar(
          title:
              Text("${(url.length > 50) ? url.substring(0, 50) + "..." : url}"),
        ),
        body: InAppWebView(
          initialUrl: "https://google.com",
          initialOptions: InAppWebViewGroupOptions(
              ios: IOSInAppWebViewOptions(
                  alwaysBounceVertical: true, disallowOverScroll: false),
              crossPlatform: InAppWebViewOptions(
                debuggingEnabled: true,
              )),
          onWebViewCreated: (InAppWebViewController controller) {
            _webViewController = controller;
          },
          onLoadStart: (InAppWebViewController controller, String url) {
            setState(() {
              this.url = url;
            });
          },
          onLoadStop: (InAppWebViewController controller, String url) async {
            setState(() {
              this.url = url;
            });
          },
          onProgressChanged: (InAppWebViewController controller, int progress) {
            setState(() {
              this.progress = progress / 100;
            });
          },
        ),
      ),
    );
  }
}
  1. This
  2. Than that
  3. Then

Images

Stacktrace/Logcat

@delay delay added the bug Something isn't working label Sep 11, 2020
@ruizyi
Copy link

ruizyi commented Nov 29, 2020

Is it fixed it or ?
I have exactly same issues

@chavesgu
Copy link

same issues

@delay
Copy link
Author

delay commented Mar 1, 2021

This was just fixed in the latest build! fixed with the latest release 5.0.5+1

Originally posted by @pichillilorenzo in #696 (comment)

@delay delay closed this as completed Mar 1, 2021
Copy link

github-actions bot commented Nov 6, 2024

This thread has been automatically locked since there has not been any recent activity after it was closed. If you are still experiencing a similar issue, please open a new bug and a minimal reproduction of the issue.

@github-actions github-actions bot locked as resolved and limited conversation to collaborators Nov 6, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

3 participants