Forwarding patterns from subelements
A GetPatternCore method implementation can also specify a subelement or part as a pattern provider for its host. This example mimics how ItemsControl transfers scroll-pattern handling to the peer of its internal ScrollViewer control. To specify a subelement for pattern handling, this code gets the subelement object, creates a peer for the subelement by using the FrameworkElement.CreatePeerForElement method, and returns the new peer.