Signals.hasHandlerPending

Returns whether there are any handlers connected to instance for the given signal id and detail. One example of when you might use this is when the arguments to the signal are difficult to compute. A class implementor may opt to not emit the signal if no one is attached anyway, thus saving the cost of building the arguments.

class Signals
static
int
hasHandlerPending

Parameters

signalId uint

the signal id.

detail GQuark

the detail.

mayBeBlocked int

whether blocked handlers should count as match.

Return Value

Type: int

TRUE if a handler is connected to the signal, FALSE otherwise.

Meta