Hi Friends,
i am facing the following problem...
how i can access the variable which is declared in the mainwindow class from some other class?
code snippet:
{
Q_OBJECT
public:
~MainWindow();
public:
QList<int> cno_airfoilgeom;
QList<int> sno_airfoilgeom;
};
class AirfoilGeomTab
: public QWidget{
Q_OBJECT
public:
AirfoilGeomTab
(QWidget *parent
= 0);
};
i wanted to use the "cno_airfoilgeom" variable in the "AirfoilGeomTab" constructor...
AirfoilGeomTab::AirfoilGeomTab(QWidget *parent
) {
// i wanted to use the "cno_airfoilgeom" variable here
}
class MainWindow : public QMainWindow
{
Q_OBJECT
public:
MainWindow(QWidget *parent = 0);
~MainWindow();
public:
QList<int> cno_airfoilgeom;
QList<int> sno_airfoilgeom;
};
class AirfoilGeomTab : public QWidget
{
Q_OBJECT
public:
AirfoilGeomTab(QWidget *parent = 0);
};
i wanted to use the "cno_airfoilgeom" variable in the "AirfoilGeomTab" constructor...
AirfoilGeomTab::AirfoilGeomTab(QWidget *parent)
: QWidget(parent)
{
// i wanted to use the "cno_airfoilgeom" variable here
}
To copy to clipboard, switch view to plain text mode
can anyone please help me...?
Thanks in Advance,
mammaiap
Bookmarks