Skip to content

Define a pattern for runApp when the window may have no size  #32871

Closed

Description

@xster

With add to app, we should propose a best practice for what to do with the widget tree if, by default, users are going to run the engine ahead of time. They would need to put some widget into runApp so something rebuilds eventually but some widget want actual window sizes too so it shouldn’t be the final widget tree.

Do we need a WhenWindowAttached widget? Or just read MediaQuery.of(context).size?

Activity

  1. added
    frameworkflutter/packages/flutter repository. See also f: labels.
    a: existing-appsIntegration with existing apps via the add-to-app flow
    on May 17, 2019
  2. matthew-carroll commented on Jun 6, 2019

    @matthew-carroll
    Contributor

    This issue needs to also account for the fact that lifecycle events are sent across a platform channel and they have an impact on Flutter's running state. The platform developer would have to make a choice to send or not send those events, and that decision would impact what Flutter runs or doesn't run.

  3. xster commented on Jun 6, 2019

    @xster
    MemberAuthor

    Agreed. Perhaps one exploration might be to consider adding new parallel or enum value lifecycle signals to distinguish app not in foreground vs app in foreground but Flutter isn't

  4. self-assigned this
    on Sep 3, 2019
  5. chunhtai commented on Sep 4, 2019

    @chunhtai
    Contributor

    I wrote up a document to conclude our off line discussion https://docs.google.com/document/d/1FNuq5-3rEB1n1fChdEde6gzZG9QOiw7HtM2jb12Ecv4/

  6. xster commented on Oct 2, 2019

    @xster
    MemberAuthor

    @chunhtai you had some PRs on this right? Can we attach some links?

  7. chunhtai commented on Oct 2, 2019

    @chunhtai
    Contributor

    The life cycle pr is tracked in this #39832

  8. blasten commented on Oct 17, 2019

    @blasten

    Hi @chunhtai. Are you still working on this issue?

  9. chunhtai commented on Oct 18, 2019

    @chunhtai
    Contributor

    @blasten , I am still working on this one #39832

  10. timsneath commented on Jan 3, 2020

    @timsneath

    Touching this issue for triage purposes.

  11. xster commented on Jan 6, 2020

    @xster
    MemberAuthor

    The last bit in the chain is flutter-team-archive/engine#14002

  12. modified the milestones: December 2019 (Add-to-App), on Jan 7, 2020
  13. github-actions commented on Aug 8, 2021

    @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.

  14. locked as resolved and limited conversation to collaborators on Aug 8, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

a: existing-appsIntegration with existing apps via the add-to-app flowframeworkflutter/packages/flutter repository. See also f: labels.

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions