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

[Bug]: 页面是FBFlutterViewContainer的子类(A),这时候我present一个FBFlutterViewContainer的子类(B),B的modalPresentationStyle = UIModalPresentationOverCurrentContext。这时候我讲B页面dismiss,但是A页面不能滑动了。 #2094

Open
MegahertzCHN opened this issue Jul 18, 2024 · 0 comments

Comments

@MegahertzCHN
Copy link

请描述遇到的问题,以及您所期望的正确的结果

页面是FBFlutterViewContainer的子类(A),这时候我present一个FBFlutterViewContainer的子类(B),B的modalPresentationStyle = UIModalPresentationOverCurrentContext。这时候我讲B页面dismiss,但是A页面不能滑动了。

请说明如何操作会遇到上述问题

我看见代码里面还是特意标注了这些,是这样设计的吗?就是不支持其他类型的modalPresentationStyle吗?
@implementation FBFlutterViewContainer

  • (instancetype)init {
    ENGINE.viewController = nil;
    if (self = [super initWithEngine:ENGINE
    nibName:_flbNibName
    bundle:_flbNibBundle]) {
    // NOTES:在present页面时,默认是全屏,如此可以触发底层VC的页面事件。否则不会触发而导致异常
    self.modalPresentationStyle = UIModalPresentationFullScreen;
    [self _setup];
    }
    return self;
    }

在下面填入关键复现代码

            vc.modalPresentationStyle = UIModalPresentationFullScreen;
            vc.view.backgroundColor = [UIColor colorWithWhite:0 alpha:0.4];
            dispatch_async(dispatch_get_main_queue(), ^(void){
                [self presentViewController:vc animated:NO completion:nil];
            });

复现的平台

iOS

Flutter SDK版本

3.16.9

FlutterBoost版本

4.5.1、4.5.11、5.0.2

是否延迟初始化FlutterBoost

No

解决方案

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant