Hello @SGaist
That's correct. Sadly, in my use case usual way of closing the context menu by click outside of its bounds has side effects, as in close neighborhood of the menu there are many QWidgets whose react to mouse clicks. Hence the need of dedicated close/cancel button.
However, I've finally found a hint in Assistant "If the QWidgetAction fires the triggered() signal, the menu will close.".
So, the problem is solved for my case, the solution is just:
but thank you mate nonetheless for trying to help.