uiDisconnect()

The function allows to disconnect previously established connections of the functions uiConnect() and uiConnectUserData().

Synopsis

int uiDisconnect(string|function_ptr callback, function_ptr event)

int uiDisconnect(string|function_ptr callback, string|shape source, string event)

int uiDisconnect(string|shape target, string callback, string|shape source, string event)

int uiDisconnect(string|function_ptr callback, string ui_eventName)

Parameters

Parameter Description
callback Name or pointer of the callback function that has been used for the uiConnect() and should now be disconnected.
event Event which has been used for uiConnect() and should now be disconnected.
source Object which has been stated inside of the uiConnect() and should now be disconnected.
target Target object which has been stated inside of the uiConnect() and should now be disconnected.
ui_eventName Name of a predefined UI manager global events which should be disconnected.

Return value

The function returns 0 on being successful and -1 in case of an error.

Errors

Wrong or missing arguments.

Description

The function uiDisconnect() is used end previously established connections to events with the functions uiConnect() or uiConnectUserData(). By calling uiDisconnect() with the stated parameters from the uiConnect the link is removed and the callback is not called anymore if the event is triggered.

Assignment

OOP

Availability

UI, CTRL