Calling the dialog checkbox from mainwindow
-
it is working on my device. Remember i have called the dialog class/form from the mainwindow ,if thats wat you want
Dialog.cpp
@
Dialog::Dialog(QWidget *parent) :
QDialog(parent),
ui(new Ui::Dialog)
{
ui->setupUi(this);
setLayout(ui->verticalLayout);}
@MainWindow.cpp
@
MainWindow::MainWindow(QWidget *parent) :
QMainWindow(parent),
ui(new Ui::MainWindow)
{
ui->setupUi(this);
Dialog *d= new Dialog();
d->show();
setCentralWidget(d);}
@alfah
-
I have a lot of widgets on the mainwindow. when the program loads, it loads the mainwindow and then the dialog. the dialog loaded is not in focus so i need to load the dialog from the mainwindow and then check if the dialog is loaded. if the dialog is not loaded then i need to write some code in the mainwindow.
i need to call the dialog checkbox from the mainwindow to determine if the dialog is displayed. if the dialog is not displayed then i can write my code in the dialog.cpp file.