Closed alpesh12345 closed 3 years ago
new PopupDialog(getContext, customComponent);
The above constructor call will only acquire the height and width of customComponent that is passed in the constructor.
To customize the content of the popup dialog, you need to use the following API
public PopupDialog setCustomComponent​(Component customComponent)
You may refer this documentation for additional information
Describe the query
I am developing a Harmony application where I want to create a popup dialog with a custom component. I tried this
After running this I only see a White background Box and Custom Component is not visible. Why
new PopupDialog(getContext, customComponent);
is not setting customComponent.Create the query with harmonyos tag in stackoverflow and share the link here:
**** https://stackoverflow.com/questions/68592453/why-creating-popup-dialog-with-custom-component-passed-in-constructor-showing-bl
Additional information
Developer Platform: Windows DevEco Studio version:2.1.0.501 SDK API version: 5 SDK version: 2.1.1.21 Device: Not required Device OS version: Not required