Skip to content

Moved Navigated before OnNavigatedTo and OnNavigatedFrom - #2008

Closed
DZetko wants to merge 2 commits into
unoplatform:masterfrom
DZetko:dev/dazi/navigationorder
Closed

DZetko wants to merge 2 commits into
unoplatform:masterfrom
DZetko:dev/dazi/navigationorder

Conversation

@DZetko

@DZetko DZetko commented Oct 31, 2019 •

Copy link
Copy Markdown
Contributor

GitHub Issue (If applicable): #1863

PR Type

What kind of change does this PR introduce?

  • Bugfix

What is the current behavior?

Wrong order of navigation events.

What is the new behavior?

Correct order of navigation events.

PR Checklist

Please check if your PR fulfills the following requirements:

  • Tested code with current supported SDKs
  • Docs have been added/updated which fit documentation template (for bug fixes / features)
  • Unit Tests and/or UI Tests for the changes have been added (for bug fixes / features) (if applicable)
  • Wasm UI Tests are not showing unexpected any differences. Validate PR Screenshots Compare Test Run results.
  • Contains NO breaking changes
  • Updated the Release Notes
  • Associated with an issue (GitHub or internal)

Other information

Internal Issue (If applicable):

@jeromelaban

Copy link
Copy Markdown
Member

Thanks for your contribution!

We do have unit tests for Frame here:

Could you add one to validate the behavior and sequence?

null
);

Navigated?.Invoke(this, navigationEvent);

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Events most likely have to be moved before Content = CurrentEntry.Instance; above for x:Bind to done after navigatedto properly.

@MartinZikmund MartinZikmund Mar 27, 2020 •

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Unfortunately, it must stay after setting the Content - in UWP Content is already set when Navigated is raised. It seems the Loading and Loaded events need to be initiated by the frame if the page is inside of it.

Frame navigating
Page constructor
Frame.Content == EventOrdering.MainPage
Frame navigated
Page navigated to
Page loading
Page loaded

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

@jeromelaban I have created #2895 for it. It seems it will be a very complex issue.

@MartinZikmund
MartinZikmund force-pushed the dev/dazi/navigationorder branch from de41b08 to 868f7d7 Compare March 27, 2020 12:30
@gitpod-io

gitpod-io Bot commented Mar 27, 2020

Copy link
Copy Markdown

Assert.IsNull(myPage2.Frame);
}

internal static NavigateOrderTracker _navigateOrderTracker = null;

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

@MartinZikmund MartinZikmund left a comment •

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Fixed the conventional commits, so should now be merge-able

@CLAassistant

Copy link
Copy Markdown

CLA assistant check
Thank you for your submission! We really appreciate it. Like many open source projects, we ask that you sign our Contributor License Agreement before we can accept your contribution.
You have signed the CLA already but the status is still pending? Let us recheck it.

@carldebilly carldebilly mentioned this pull request Jul 10, 2020
1 of 9 tasks
@DZetko
DZetko requested a review from a team August 7, 2020 22:11
@jeromelaban

Copy link
Copy Markdown
Member

Let's close this PR for now as it will be reworked by the Loaded/Unloaded work.

pull Bot pushed a commit to AKJUS/uno that referenced this pull request Jun 10, 2026
…andler

feat(HotReload): Add UIUpdate.ForceRefresh(Type[]) to re-apply types bypassing active pauses
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

Successfully merging this pull request may close these issues.

5 participants