Skip to content

Commit d6aaefb

Browse files
committed
add a note about thread safety of activity.bind.
1 parent 8500aaf commit d6aaefb

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

docs/source/android.rst

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -46,6 +46,10 @@ The default PythonActivity has a observer pattern for `onActivityResult <http://
4646
- ``on_new_intent`` is the event associated to the onNewIntent java call
4747
- ``on_activity_result`` is the event associated to the onActivityResult java call
4848

49+
.. warning::
50+
51+
This method is not thread-safe. Call it in the mainthread of your app. (tips: use kivy.clock.mainthread decorator)
52+
4953
.. function:: unbind(eventname=callback, ...)
5054

5155
Unregister a previously registered callback with :func:`bind`.

0 commit comments

Comments
 (0)