Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Root view panel #12372

Open
wants to merge 2 commits into
base: main
Choose a base branch
from
Open

Root view panel #12372

wants to merge 2 commits into from

Conversation

lyahdav
Copy link
Collaborator

@lyahdav lyahdav commented Nov 9, 2023

Description

RootViewPanel is useful for product view manager which need to manage keyboard/touch inputs.

Type of Change

  • New feature (non-breaking change which adds functionality)

Why

Before this change it's not possible to make a view manager in product code for XAML controls such as Popup/Flyout. This is why it's not possible to make something like FlyoutViewManager in product code as it requires TouchEventHandler/PreviewKeyboardEventHandlerOnRoot which are not exposed in the RNW ABI.

What

Created RootViewPanel class which is exposed via RNW ABI for use in product view managers.

Testing

At Meta we've used this class to create a product view manager which uses XAML Popup. In the view manager's AddView method you can add child views onto a RootViewPanel.

Changelog

Should this change be included in the release notes: no

Microsoft Reviewers: Open in CodeFlow

Useful for product view manager which need to manage keyboard/touch
inputs.
@lyahdav lyahdav requested review from a team as code owners November 9, 2023 21:13
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.

3 participants