Bug 970747 - 6/6 - Make LayerTransactionParent::RecvUpdate error out if RepositionChild fails - r=mattwoodrow

This commit is contained in:
Benoit Jacob 2014-02-21 16:50:25 -05:00
Родитель 0c5e25c738
Коммит 7212d43233
1 изменённых файлов: 6 добавлений и 4 удалений

Просмотреть файл

@ -457,10 +457,11 @@ LayerTransactionParent::RecvUpdate(const InfallibleTArray<Edit>& cset,
return false;
}
ContainerLayerComposite* container = ShadowContainer(orc)->AsContainerLayerComposite();
if (!container) {
if (!container ||
!container->RepositionChild(child, ShadowAfter(orc)->AsLayer()))
{
return false;
}
container->RepositionChild(child, ShadowAfter(orc)->AsLayer());
break;
}
case Edit::TOpRaiseToTopChild: {
@ -472,10 +473,11 @@ LayerTransactionParent::RecvUpdate(const InfallibleTArray<Edit>& cset,
return false;
}
ContainerLayerComposite* container = ShadowContainer(rtc)->AsContainerLayerComposite();
if (!container) {
if (!container ||
!container->RepositionChild(child, nullptr))
{
return false;
}
container->RepositionChild(child, nullptr);
break;
}
case Edit::TCompositableOperation: {