Allow size hint changes during a rearrange.

Previously, we marked the layout as not dirty straight after a
rearrange was done. However, in the case of when a size hint changed
during a rearrange that would block the pending rearrange (since it
only perform the actual rearrange if its dirty).

Instead, mark the layout as not dirty *before* the rearrange.

This will allow bindings such as
  implicitWidth: height
to execute the pending rearrange.
(Although such bindings are not encouraged)

Task-number: QTBUG-36169
Change-Id: I75bd821a0ca4302026bd5dac01287ca3359d471b
Reviewed-by: J-P Nurmi <jpnurmi@digia.com>