diff options
Diffstat (limited to 'sw/source')
-rw-r--r-- | sw/source/uibase/utlui/content.cxx | 11 |
1 files changed, 2 insertions, 9 deletions
diff --git a/sw/source/uibase/utlui/content.cxx b/sw/source/uibase/utlui/content.cxx index 47bb9e560a7a..dcfa88e668d7 100644 --- a/sw/source/uibase/utlui/content.cxx +++ b/sw/source/uibase/utlui/content.cxx @@ -1773,8 +1773,8 @@ void SwContentTree::Display( bool bActive ) nEntryRelPos = GetModel()->GetAbsPos(pOldSelEntry) - GetModel()->GetAbsPos(pParentEntry); } } + Clear(); SetUpdateMode( false ); - SvTreeListBox::Clear(); if (!bActive) m_eState = State::HIDDEN; else if (State::HIDDEN == m_eState) @@ -1912,6 +1912,7 @@ void SwContentTree::Display( bool bActive ) SetCurEntry(pParent); } } + SetUpdateMode( true ); ScrollBar* pVScroll = GetVScroll(); if(GetEntryCount() == nOldEntryCount && nOldScrollPos && pVScroll && pVScroll->IsVisible() @@ -1920,8 +1921,6 @@ void SwContentTree::Display( bool bActive ) sal_Int32 nDelta = pVScroll->GetThumbPos() - nOldScrollPos; ScrollOutputArea( static_cast<short>(nDelta) ); } - if (!m_bIsInPromoteDemote) - SetUpdateMode( true ); } void SwContentTree::Clear() @@ -2721,8 +2720,6 @@ void SwContentTree::ExecCommand(const OUString& rCmd, bool bOutlineWithChildren) } SvTreeListBox::Invalidate(); } - // SetUpdateMode is set false in the Display function - SetUpdateMode(true); } } @@ -2734,10 +2731,6 @@ void SwContentTree::ShowTree() void SwContentTree::Paint( vcl::RenderContext& rRenderContext, const tools::Rectangle& rRect ) { - // prevent focus rect from flashing when tree is cleared - // SvTreeListBox::Paint shows focus rectangle when tree is empty - if (!GetEntryCount()) - return; // Start the update timer on the first paint; avoids // flicker on the first reveal. m_aUpdTimer.Start(); |