Merge change 21225 into eclair

* changes:
  fix a bug that could cause a window to be hidden in some cases.