Merge "Fix a bug about the z-order of layers caused by merging transactions" into qt-dev