OpenMS
SignalProvider Class Reference

provides a signal mechanism (by deriving from QObject) for classes which are not allowed to have signals themselves. More...

#include <OpenMS/VISUAL/EnhancedTabBarWidgetInterface.h>

Inheritance diagram for SignalProvider:
[legend]
Collaboration diagram for SignalProvider:
[legend]

Signals

void aboutToBeDestroyed (int id)
 

Public Member Functions

void emitAboutToBeDestroyed (int id)
 

Detailed Description

provides a signal mechanism (by deriving from QObject) for classes which are not allowed to have signals themselves.

This might be useful for EnhancedTabBarWidgetInterface, since that cannot derive from QObject due to the diamond star inheritance problem via its parent classes (e.g. PlotWidget).

Diamond star problem:

PlotWidget / \ ETBWI QWidget -! / QObject

Thus, ETBWI cannot derive from QObject and needs to delegate its signaling duties to a SignalProvider.

Wrap all signals that are required in a function call and call these functions instead of emitting the signal directly. Connect the signal to a slot by using QObject::connect() externally somewhere.

Member Function Documentation

◆ aboutToBeDestroyed

void aboutToBeDestroyed ( int  id)
signal

◆ emitAboutToBeDestroyed()

void emitAboutToBeDestroyed ( int  id)
inline