It looks like the PageTransition used in the NavigationController for subframe navigation are not the one dedicated to subframe (i.e. PAGE_TRANSITION_{AUTO, MANUAL}_SUBFRAME) but the one of the main frame.
For instance:
* Navigation to a page A with an iframe B
In FrameHostMsg_DidCommitProvisionalLoad:
A -> PAGE_TRANSITION_LINK | PAGE_TRANSITION_FROM_ADDRESS_BAR
B -> PAGE_TRANSITION_AUTO_SUBFRAME
In NavigationControllerImpl:
entries[0] -> PAGE_TRANSITION_LINK | PAGE_TRANSITION_FROM_ADDRESS_BAR
* Then B navigates.
In FrameHostMsg_DidCommitProvisionalLoad:
B -> PAGE_TRANSITION_MANUAL_SUBFRAME
In NavigationControllerImpl:
entries[1] -> PAGE_TRANSITION_LINK | PAGE_TRANSITION_FROM_ADDRESS_BAR
Some old comments suggests that PAGE_TRANSITION_MANUAL_SUBFRAME was used in the NavigationControllerImpl for the second navigation. Maybe the switch to FrameNavigationEntries made it so that we don't update the transition type of the NavigationEntry anymore.
What to do is an open question.
Comment 1 by bugdroid1@chromium.org
, Jul 10 2017