Skip to content
This repository was archived by the owner on Feb 25, 2025. It is now read-only.

Conversation

@ColdPaleLight
Copy link
Member

@ColdPaleLight ColdPaleLight commented Jul 12, 2022

fix flutter/flutter#105203

Pre-launch Checklist

  • I read the [Contributor Guide] and followed the process outlined there for submitting PRs.
  • I read the [Tree Hygiene] wiki page, which explains my responsibilities.
  • I read and followed the [Flutter Style Guide] and the [C++, Objective-C, Java style guides].
  • I listed at least one issue that this PR fixes in the description above.
  • I added new tests to check the change I am making or feature I am adding, or Hixie said the PR is test-exempt. See [testing the engine] for instructions on
    writing and running engine tests.
  • I updated/added relevant documentation (doc comments with ///).
  • I signed the [CLA].
  • All existing and new tests are passing.

Copy link
Contributor

@Nayuta403 Nayuta403 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

👍🏻 with some ideas

// onStart and onStop.
// See https://github.com/flutter/flutter/issues/93276
flutterView.setVisibility(View.GONE);
if (flutterView.getVisibility() != View.GONE) {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
if (flutterView.getVisibility() != View.GONE) {

I wonder if this judgment can be removed, or previousVisibility needs to be assigned again in else.
So let's say this is the case:

  • First time the flutterView is View.VISIBLE. When onStop is executed, previousVisibility will also become View.VISIBLE.
  • Second time I change the flutterView to View.GONE. When onStop is executed, the previousVisibility will not be changed.

If onStart is executed at this time, previousVisibility remains as before, causes the flutterView to be View.VISIBLE(Even though I've changed to View.GONE

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Good catch! I'll remove it.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Done

@ColdPaleLight ColdPaleLight added the autosubmit Merge PR when tree becomes green via auto submit App label Jul 12, 2022
@auto-submit auto-submit bot merged commit 4cd7b92 into flutter:main Jul 12, 2022
engine-flutter-autoroll added a commit to engine-flutter-autoroll/flutter that referenced this pull request Jul 12, 2022
betrevisan pushed a commit to betrevisan/engine that referenced this pull request Jul 15, 2022
@chdo002
Copy link

chdo002 commented Aug 24, 2022

issues/105203
still exits;
this merge doesn't fix it

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

autosubmit Merge PR when tree becomes green via auto submit App platform-android

Projects

None yet

Development

Successfully merging this pull request may close these issues.

FlutterFragment forced to visiable when Activity resumed

4 participants