{
Q_OBJECT
public:
private slots:
void blocked();
//LOOK HERE
};
#endif
buttons.cpp
connect(deshabilitar, SIGNAL(clicked()),this, SLOT(blocked()));
//LOOK HERE
//QPushButton *Button7= new QPushButton(tr("Button7"), this);
void buttons:: blocked( )
{
//FINALLY LOOK HERE
//Button7.setDisabled(true);
Button7->setDisabled(true);
}
class buttons: public QWidget
{
Q_OBJECT
public:
buttons(QWidget *parent = 0);
private slots:
void blocked();
//LOOK HERE
QPushButton *Button7;
};
#endif
buttons.cpp
QPushButton *deshabilitar = new QPushButton(tr("deshabilitar"), this);
connect(deshabilitar, SIGNAL(clicked()),this, SLOT(blocked()));
//LOOK HERE
//QPushButton *Button7= new QPushButton(tr("Button7"), this);
Button7= new QPushButton(tr("Button7"), this);
void buttons:: blocked( )
{
//FINALLY LOOK HERE
//Button7.setDisabled(true);
Button7->setDisabled(true);
}
To copy to clipboard, switch view to plain text mode
make other buttons the member as well
Bookmarks