laserpants / qt-material-widgets

:art: Qt widgets-based implementation of the Material Design specification.
BSD 3-Clause "New" or "Revised" License
3k stars 673 forks source link

QtMaterialDialog: dialog is invisible without calling QWidget::show() #31

Open ZimNovich opened 6 years ago

ZimNovich commented 6 years ago

When I am instantiating an object of QtMaterialDialog class, the dialog becomes visible only after calling QWidget's show() method:

// Show Preferences
QtMaterialDialog* prefs = new QtMaterialDialog(this);
// Adding child objects and stuff
. . .
prefs->setWindowLayout(dialogLayout);
prefs->show(); // This call is necessary (!)
prefs->showDialog();