I am changing position of some things inside the CompositionTarget.Rendering event, so it has a little delay. If I could update the layout only at the end of this event, I guess this problem would be solved. Is it possible? Thank you.
CompositionTarget.Rendering += new EventHandler(Draw);
void Draw(object sender, EventArgs e)
{
...
//update();
}