How to trigger a pulse from a thread?

I’ve created some pulse using PtAppCreatePulse, then I’ve add an input
processing function to my Photon application using PtAppAddInput(). Then I
wanted to call PtAppPulseTrigger() from some thread. Unfortunately
PtAppPulseTrigger() documentation says it’s not thread safe! Finally, my
application hangs after some while of running.
Input processing function calls PtDamageWidget() and PtFlush() to repaint
my Raw widget (my own paint function that is the aim of whole action is
called safely that way).
Can anyone suggest me other (thread safe) way to cause my Raw widget being
repainted (and my own paint function called) as some other thread wants
it?
Greetings
Paul