The connect (UI - & gt; LoginButton, & amp; QPushButton: : clicked, this, & amp; Widgets: : OnClickedLogin);
The connect (UI - & gt; LogoutButton, & amp; QPushButton: : clicked, this, & amp; Widgets: : OnClickedLogout);
The connect (UI - & gt; PreviewButton, & amp; QPushButton: : clicked, this, & amp; Widgets: : OnClickedPreview);
The connect (UI - & gt; StopPreviewButton, & amp; QPushButton: : clicked, this, & amp; Widgets: : OnClickedStopPreview);
The connect (UI - & gt; CaptureButton, & amp; QPushButton: : clicked, this, & amp; Widgets: : OnClickedCapture);
The class mythread: public QThread
{
Void the run ()
{
Widgets * w=new Widget;
W - & gt; Show ();
}
};
Int main (int arg c, char * argv [])
{
QApplication a (arg c, argv);
Mythread c;
C.s. tart ();
Return a.e xec ();
}
CodePudding user response:
Widget try using modal window open, it is estimated that threads run after releaseCodePudding user response: