Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit a019b4f

Browse files
committed
update change log
1 parent da7a5cc commit a019b4f

2 files changed

Lines changed: 5 additions & 9 deletions

File tree

doc/api/next_api_changes/deprecations/30844-IHI.rst

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,3 @@ The *cid* parameter of `.CallbackRegistry.disconnect` has been renamed to
44
*cid_or_func*. The method now also accepts a callable, which will disconnect
55
that callback from all signals or from a specific signal if the *signal*
66
keyword argument is provided.
7-
8-
``CallbackRegistry.disconnect_func`` has been removed; use
9-
``disconnect(func, signal=...)`` instead.
Lines changed: 5 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,9 @@
1-
``CallbackRegistry.disconnect_func`` to disconnect callbacks by function
1+
``CallbackRegistry.disconnect`` allows directly callbacks by function
22
-------------------------------------------------------------------------
33

4-
`.CallbackRegistry` now has a `~.CallbackRegistry.disconnect_func` method that
5-
allows disconnecting a callback by passing the signal and function directly,
6-
instead of needing to track the callback ID returned by
7-
`~.CallbackRegistry.connect`.
4+
`.CallbackRegistry` now allows directly passing a function and optionally signal
5+
`~.CallbackRegistry.disconnect` to disconnect instead of needing to track the callback
6+
ID returned by `~.CallbackRegistry.connect`.
87

98
.. code-block:: python
109
@@ -17,4 +16,4 @@ instead of needing to track the callback ID returned by
1716
callbacks.connect('my_signal', my_callback)
1817
1918
# Disconnect by function reference instead of callback ID
20-
callbacks.disconnect_func('my_signal', my_callback)
19+
callbacks.disconnect('my_signal', my_callback)

0 commit comments

Comments
 (0)