Qt: fixed signal of a clicked push button (patch #786)
This commit is contained in:
parent
3c7055b9ce
commit
233dfd252d
@ -1338,8 +1338,11 @@ void CvButtonbar::addButton( QString name, CvButtonCallback call, void* userdata
|
|||||||
}
|
}
|
||||||
|
|
||||||
if (button)
|
if (button)
|
||||||
{
|
{
|
||||||
QObject::connect( button, SIGNAL( toggled(bool) ),button, SLOT( callCallBack(bool) ));
|
if (button_type == CV_PUSH_BUTTON)
|
||||||
|
QObject::connect( button, SIGNAL( clicked(bool) ),button, SLOT( callCallBack(bool) ));
|
||||||
|
else
|
||||||
|
QObject::connect( button, SIGNAL( toggled(bool) ),button, SLOT( callCallBack(bool) ));
|
||||||
addWidget(button,Qt::AlignCenter);
|
addWidget(button,Qt::AlignCenter);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user