Skip to content

Prevent interaction on rest of the page while page transitioning #30416

Closed

Description

@xster

From #27334 (comment)

Prevent page interactions during transitions in general on Android and iOS.

Activity

  1. added
    frameworkflutter/packages/flutter repository. See also f: labels.
    f: routesNavigator, Router, and related APIs.
    on Apr 3, 2019
  2. TomLiu-GitHub commented on Apr 8, 2019

    @TomLiu-GitHub

    This bug not been noticed. I think it's a very serious bug.

  3. added this to the milestone on Apr 8, 2019
  4. Fleximex commented on Apr 19, 2019

    @Fleximex

    Interestingly this bug does not appear when using the backbutton on your device. Even though you still do a Navigator Push before the transition has ended.
    I have have 'fixed' this problem by using fullscreenDialog: true, (though that changes the animation to a vertical one).

    This is indeed a severe bug and should be fixed. Also because the crash caused by it stops further interaction with the app.

  5. TomLiu-GitHub commented on May 8, 2019

    @TomLiu-GitHub

    This is indeed a severe bug and should be fixed.

    Who knows when to fix it?

    Thanks to the flutter team.

  6. added
    P2Important issues not at the top of the work list
    on May 29, 2020
  7. removed this from the milestone on Aug 17, 2020
  8. markusaksli-nc commented on Sep 24, 2020

    @markusaksli-nc
    Contributor

    Reproducible on the latest master 1.22.0-10.0.pre.340.

    flutter doctor -v
    [√] Flutter (Channel master, 1.22.0-10.0.pre.340, on Microsoft Windows [Version 10.0.19041.508], locale en-US)
        • Flutter version 1.22.0-10.0.pre.340 at C:\Development\flutter_master
        • Framework revision 1fef5912cf (65 minutes ago), 2020-09-23 21:37:08 -0700
        • Engine revision dd35b5b659
        • Dart version 2.10.0 (build 2.10.0-156.0.dev)
    
    
    [√] Android toolchain - develop for Android devices (Android SDK version 30.0.1)
        • Android SDK at C:\Users\marku\AppData\Local\Android\sdk
        • Platform android-30, build-tools 30.0.1
        • Java binary at: C:\Users\marku\AppData\Local\JetBrains\Toolbox\apps\AndroidStudio\ch-0\193.6626763\jre\bin\java
        • Java version OpenJDK Runtime Environment (build 1.8.0_242-release-1644-b01)
        • All Android licenses accepted.
    
    [√] Chrome - develop for the web
        • Chrome at C:\Program Files (x86)\Google\Chrome\Application\chrome.exe
    
    [√] Visual Studio - develop for Windows (Visual Studio Community 2019 16.6.5)
        • Visual Studio at C:\Program Files (x86)\Microsoft Visual Studio\2019\Community
        • Visual Studio Community 2019 version 16.6.30320.27
        • Windows 10 SDK version 10.0.18362.0
    
    [√] Android Studio (version 4.0)
        • Android Studio at C:\Users\marku\AppData\Local\JetBrains\Toolbox\apps\AndroidStudio\ch-0\193.6626763
        • Flutter plugin version 47.1.2
        • Dart plugin version 193.7361
        • Java version OpenJDK Runtime Environment (build 1.8.0_242-release-1644-b01)
    
    [√] Connected device (6 available)
        • SM G950F (mobile)           • ce12171c51cc001c03 • android-arm64  • Android 9 (API 28)
        • sdk gphone x86 arm (mobile) • emulator-5554      • android-x86    • Android 11 (API 30) (emulator)
        • Windows (desktop)           • windows            • windows-x64    • Microsoft Windows [Version 10.0.19041.508]
        • Web Server (web)            • web-server         • web-javascript • Flutter Tools
        • Chrome (web)                • chrome             • web-javascript • Google Chrome 85.0.4183.102
        • Edge (web)                  • edge               • web-javascript • Microsoft Edge 85.0.564.51
    
    • No issues found!
    
    Minimal reproducible code sample
    import 'package:flutter/material.dart';
    import 'package:flutter/scheduler.dart';
    
    void main() {
      timeDilation = 4.0;
      runApp(MaterialApp(
        title: 'Navigation Basics',
        home: FirstRoute(),
      ));
    }
    
    class FirstRoute extends StatelessWidget {
      @override
      Widget build(BuildContext context) {
        return Scaffold(
          appBar: AppBar(
            title: Text('First Route'),
          ),
          body: Center(
            child: RaisedButton(
              child: Text('Open route'),
              onPressed: () {
                Navigator.push(
                  context,
                  MaterialPageRoute(builder: (context) => SecondRoute()),
                );
              },
            ),
          ),
        );
      }
    }
    
    class SecondRoute extends StatelessWidget {
      @override
      Widget build(BuildContext context) {
        return Scaffold(
          appBar: AppBar(
            title: Text("Second Route"),
          ),
          body: Center(
            child: RaisedButton(
              onPressed: () {
                Navigator.pop(context);
              },
              child: Text('Go back!'),
            ),
          ),
        );
      }
    }

  9. darshankawar commented on Nov 8, 2022

    @darshankawar
    Member

    Verified this issue on latest versions and observed that tapping on back button in app bar is not recognized. Used physical device for verification. With this I am going ahead and closing as not replicable anymore. If anybody disagrees, please write in comments and I'll reopen it.

    stable, master flutter doctor -v
    [✓] Flutter (Channel stable, 3.3.7, on macOS 12.2.1 21D62 darwin-x64, locale
        en-GB)
        • Flutter version 3.3.7 on channel stable at
          /Users/dhs/documents/fluttersdk/flutter
        • Upstream repository https://github.com/flutter/flutter.git
        • Framework revision e99c9c7cd9 (2 days ago), 2022-11-01 16:59:00 -0700
        • Engine revision 857bd6b74c
        • Dart version 2.18.4
        • DevTools version 2.15.0
    
    [!] Xcode - develop for iOS and macOS (Xcode 12.3)
        • Xcode at /Applications/Xcode.app/Contents/Developer
        ! Flutter recommends a minimum Xcode version of 13.
          Download the latest version or update via the Mac App Store.
        • CocoaPods version 1.11.2
    
    [✓] Chrome - develop for the web
        • Chrome at /Applications/Google Chrome.app/Contents/MacOS/Google Chrome
    
    [✓] VS Code (version 1.62.0)
        • VS Code at /Applications/Visual Studio Code.app/Contents
        • Flutter extension version 3.21.0
    
    [✓] Connected device (5 available)
        • SM G975F (mobile)       • RZ8M802WY0X • android-arm64   • Android 11 (API 30)
        • Darshan's iphone (mobile)  • 21150b119064aecc249dfcfe05e259197461ce23 •
          ios            • iOS 14.4.1 18D61
        • iPhone 12 Pro Max (mobile) • A5473606-0213-4FD8-BA16-553433949729     •
          ios            • com.apple.CoreSimulator.SimRuntime.iOS-14-3 (simulator)
        • macOS (desktop)            • macos                                    •
          darwin-x64     • Mac OS X 10.15.4 19E2269 darwin-x64
        • Chrome (web)               • chrome                                   •
          web-javascript • Google Chrome 98.0.4758.80
    
    [✓] HTTP Host Availability
        • All required HTTP hosts are available
    
    ! Doctor found issues in 1 category.
    
    [!] Flutter (Channel master, 3.5.0-12.0.pre.168, on macOS 12.2.1 21D62
        darwin-x64, locale en-GB)
        • Flutter version 3.5.0-12.0.pre.168 on channel master at
          /Users/dhs/documents/fluttersdk/flutter
        ! Warning: `flutter` on your path resolves to
          /Users/dhs/Documents/Fluttersdk/flutter/bin/flutter, which is not inside
          your current Flutter SDK checkout at
          /Users/dhs/documents/fluttersdk/flutter. Consider adding
          /Users/dhs/documents/fluttersdk/flutter/bin to the front of your path.
        ! Warning: `dart` on your path resolves to
          /Users/dhs/Documents/Fluttersdk/flutter/bin/dart, which is not inside your
          current Flutter SDK checkout at /Users/dhs/documents/fluttersdk/flutter.
          Consider adding /Users/dhs/documents/fluttersdk/flutter/bin to the front
          of your path.
        • Upstream repository https://github.com/flutter/flutter.git
        • Framework revision a1432a9c5d (4 hours ago), 2022-11-07 19:17:03 -0600
        • Engine revision e7d7edab98
        • Dart version 2.19.0 (build 2.19.0-374.0.dev)
        • DevTools version 2.19.0
        • If those were intentional, you can disregard the above warnings; however
          it is recommended to use "git" directly to perform update checks and
          upgrades.
        
    [!] Xcode - develop for iOS and macOS (Xcode 12.3)
        • Xcode at /Applications/Xcode.app/Contents/Developer
        ! Flutter recommends a minimum Xcode version of 13.
          Download the latest version or update via the Mac App Store.
        • CocoaPods version 1.11.2
    
    [✓] Chrome - develop for the web
        • Chrome at /Applications/Google Chrome.app/Contents/MacOS/Google Chrome
    
    [✓] VS Code (version 1.62.0)
        • VS Code at /Applications/Visual Studio Code.app/Contents
        • Flutter extension version 3.21.0
    
    [✓] Connected device (5 available)
        • SM G975F (mobile)       • RZ8M802WY0X • android-arm64   • Android 11 (API 30)
        • Darshan's iphone (mobile)  • 21150b119064aecc249dfcfe05e259197461ce23 •
          ios            • iOS 14.4.1 18D61
        • iPhone 12 Pro Max (mobile) • A5473606-0213-4FD8-BA16-553433949729     •
          ios            • com.apple.CoreSimulator.SimRuntime.iOS-14-3 (simulator)
        • macOS (desktop)            • macos                                    •
          darwin-x64     • Mac OS X 10.15.4 19E2269 darwin-x64
        • Chrome (web)               • chrome                                   •
          web-javascript • Google Chrome 98.0.4758.80
    
    [✓] HTTP Host Availability
        • All required HTTP hosts are available
    
    ! Doctor found issues in 1 category.
    
    
    
    
  10. added
    r: fixedIssue is closed as already fixed in a newer version
    on Nov 8, 2022
  11. github-actions commented on Nov 22, 2022

    @github-actions

    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, including the output of flutter doctor -v and a minimal reproduction of the issue.

  12. locked as resolved and limited conversation to collaborators on Nov 22, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    P2Important issues not at the top of the work listf: routesNavigator, Router, and related APIs.found in release: 1.22Found to occur in 1.22frameworkflutter/packages/flutter repository. See also f: labels.has reproducible stepsThe issue has been confirmed reproducible and is ready to work onr: fixedIssue is closed as already fixed in a newer version

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions