kwave  18.07.70
Kwave::MessageBox::Trigger Class Reference
Inheritance diagram for Kwave::MessageBox::Trigger:
Inheritance graph
Collaboration diagram for Kwave::MessageBox::Trigger:
Collaboration graph

Public Member Functions

 Trigger (Kwave::MessageBox &box)
 
virtual ~Trigger ()
 

Private Attributes

Kwave::MessageBoxm_box
 

Detailed Description

internal helper for showing the KMessageBox in the GUI thread

Definition at line 141 of file MessageBox.h.

Constructor & Destructor Documentation

◆ Trigger()

Kwave::MessageBox::Trigger::Trigger ( Kwave::MessageBox box)
explicit

Constructor, re-parents itself to the GUI thread

Parameters
boxthe Kwave::MessageBox to use

Definition at line 224 of file MessageBox.cpp.

225  :QObject(Q_NULLPTR), m_box(box)
226 {
227  moveToThread(QApplication::instance()->thread());
228 }
Kwave::MessageBox & m_box
Definition: MessageBox.h:161

◆ ~Trigger()

Kwave::MessageBox::Trigger::~Trigger ( )
virtual

Destructor. Will always be executed in the GUI thread, because the instance of this object is moved to the GUI thread and deleteLater() is called. This calls the "show()" method of the Kwave::MessageBox in a safe context.

Definition at line 231 of file MessageBox.cpp.

References m_box, and Kwave::MessageBox::show().

232 {
233  m_box.show();
234 }
Kwave::MessageBox & m_box
Definition: MessageBox.h:161
Here is the call graph for this function:

Member Data Documentation

◆ m_box

Kwave::MessageBox& Kwave::MessageBox::Trigger::m_box
private

reference to the Kwave::MessageBox instance

Definition at line 161 of file MessageBox.h.

Referenced by ~Trigger().


The documentation for this class was generated from the following files: