[JENKINS-14653] maven with triggered build selector

[JENKINS-14653] (https://issues.jenkins-ci.org/browse/JENKINS-14653)
"Upstream build" works for matrix child projects even when the build is triggered by parent builds of those matrix projects.
This is done by special codes written only for matrix projects, and doesn't work for maven modules even though the relation between maven module sets and maven modules is just same to that of matrix parents and matrix children.
This change using `AbstractProject#getRootProject` generalizes the way to handle child builds and make it work also for maven modules.
And `TriggeredBuildSelector` no longer depends on matrix-project.

`MatrixRun#getParentBuild` is no longer necessary as triggered build selector tracks ancestor builds since 1.26 and parent builds should be tracked as triggering builds of child builds.