Kaydet (Commit) f9164c17 authored tarafından Caolán McNamara's avatar Caolán McNamara

guard against missing grandfather layout

Change-Id: I1282b2c3c920ef89460aa57026d89c8928155116
üst 1b12d0dc
......@@ -190,7 +190,7 @@ void LwpFrame::RegisterStyle(XFFrameStyle* pFrameStyle)
LwpVirtualLayout* pParent = m_pLayout->GetParentLayout();
if (!pParent)
throw std::runtime_error("missing Parent Layout");
if(pParent->IsPage()&& pParent->GetParentLayout()->IsPage())
if (pParent->IsPage() && pParent->GetParentLayout() && pParent->GetParentLayout()->IsPage())
{
//for mirror page, problems exist if the parent layout is header or footer layout,
pParent = pParent->GetParentLayout();
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment