Kaydet (Commit) ba7a4cdc authored tarafından Mihai Varga's avatar Mihai Varga Kaydeden (comit) Miklos Vajna

Impress: set current page Id before showing the new page

For tiled rendering this has the effect of not invalidating the
previous slide when switching slides. After switching slides, an
invalidation occurs caused by showing the new slide, and calling
'GetPart' before 'SwitchPage' finishes returned the old part number.

Change-Id: I1cafd0e51cd39be3a80d0559ae3051238b8df744
Reviewed-on: https://gerrit.libreoffice.org/17562Tested-by: 's avatarJenkins <ci@libreoffice.org>
Reviewed-by: 's avatarSamuel Mehrbrodt <Samuel.Mehrbrodt@cib.de>
Tested-by: 's avatarSamuel Mehrbrodt <Samuel.Mehrbrodt@cib.de>
(cherry picked from commit 45576ea3)
üst 3ec89475
...@@ -964,6 +964,7 @@ bool DrawViewShell::SwitchPage(sal_uInt16 nSelectedPage) ...@@ -964,6 +964,7 @@ bool DrawViewShell::SwitchPage(sal_uInt16 nSelectedPage)
} }
mpDrawView->HideSdrPage(); mpDrawView->HideSdrPage();
maTabControl->SetCurPageId(nSelectedPage+1);
mpDrawView->ShowSdrPage(mpActualPage); mpDrawView->ShowSdrPage(mpActualPage);
GetViewShellBase().GetDrawController().FireSwitchCurrentPage(mpActualPage); GetViewShellBase().GetDrawController().FireSwitchCurrentPage(mpActualPage);
...@@ -989,7 +990,6 @@ bool DrawViewShell::SwitchPage(sal_uInt16 nSelectedPage) ...@@ -989,7 +990,6 @@ bool DrawViewShell::SwitchPage(sal_uInt16 nSelectedPage)
} }
} }
maTabControl->SetCurPageId(nSelectedPage+1);
OUString aPageName = mpActualPage->GetName(); OUString aPageName = mpActualPage->GetName();
if (maTabControl->GetPageText(nSelectedPage+1) != aPageName) if (maTabControl->GetPageText(nSelectedPage+1) != aPageName)
...@@ -1025,6 +1025,7 @@ bool DrawViewShell::SwitchPage(sal_uInt16 nSelectedPage) ...@@ -1025,6 +1025,7 @@ bool DrawViewShell::SwitchPage(sal_uInt16 nSelectedPage)
} }
mpDrawView->HideSdrPage(); mpDrawView->HideSdrPage();
maTabControl->SetCurPageId(nSelectedPage+1);
SdPage* pMaster = GetDoc()->GetMasterSdPage(nSelectedPage, mePageKind); SdPage* pMaster = GetDoc()->GetMasterSdPage(nSelectedPage, mePageKind);
...@@ -1063,8 +1064,6 @@ bool DrawViewShell::SwitchPage(sal_uInt16 nSelectedPage) ...@@ -1063,8 +1064,6 @@ bool DrawViewShell::SwitchPage(sal_uInt16 nSelectedPage)
if (nPos != -1) if (nPos != -1)
aLayoutName = aLayoutName.copy(0, nPos); aLayoutName = aLayoutName.copy(0, nPos);
maTabControl->SetCurPageId(nSelectedPage+1);
if (maTabControl->GetPageText(nSelectedPage+1) != aLayoutName) if (maTabControl->GetPageText(nSelectedPage+1) != aLayoutName)
{ {
maTabControl->SetPageText(nSelectedPage+1, aLayoutName); maTabControl->SetPageText(nSelectedPage+1, aLayoutName);
......
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