diff options
author | Jim Raykowski <raykowj@gmail.com> | 2019-04-11 22:45:42 -0800 |
---|---|---|
committer | Jim Raykowski <raykowj@gmail.com> | 2019-04-15 04:09:00 +0200 |
commit | b4869c08b81a1bc707c882a1b3668b056e8f44d1 (patch) | |
tree | 5da5ba4a4a3a057dc67ed6a61a2a26d14c148371 /sw | |
parent | e9651c2509004e2113864e15d74b8637966083ab (diff) |
tdf#115600 Display messages in Findbar for Navigate By Page
...and make Navigate By Page wrap
Change-Id: Iec45d87f665f75e90378c302b8c3098bb5cbe7d1
Reviewed-on: https://gerrit.libreoffice.org/70640
Tested-by: Jenkins
Reviewed-by: Jim Raykowski <raykowj@gmail.com>
Diffstat (limited to 'sw')
-rw-r--r-- | sw/source/uibase/uiview/viewmdi.cxx | 27 |
1 files changed, 26 insertions, 1 deletions
diff --git a/sw/source/uibase/uiview/viewmdi.cxx b/sw/source/uibase/uiview/viewmdi.cxx index dc910ca91427..bff30a24443d 100644 --- a/sw/source/uibase/uiview/viewmdi.cxx +++ b/sw/source/uibase/uiview/viewmdi.cxx @@ -348,7 +348,32 @@ IMPL_LINK( SwView, MoveNavigationHdl, void*, p, void ) switch( m_nMoveType ) { case NID_PGE: - bNext ? PhyPageDown() : PhyPageUp(); + if ( bNext ) + { + if ( USHRT_MAX == rSh.GetNextPrevPageNum( true ) ) + { + rSh.GotoPage( 1, true ); + SvxSearchDialogWrapper::SetSearchLabel( SearchLabel::EndWrapped ); + } + else + { + PhyPageDown(); + SvxSearchDialogWrapper::SetSearchLabel( SearchLabel::Empty ); + } + } + else + { + if ( USHRT_MAX == rSh.GetNextPrevPageNum( false ) ) + { + rSh.GotoPage( rSh.GetPageCnt(), true ); + SvxSearchDialogWrapper::SetSearchLabel( SearchLabel::StartWrapped ); + } + else + { + PhyPageUp(); + SvxSearchDialogWrapper::SetSearchLabel( SearchLabel::Empty ); + } + } break; case NID_TBL : rSh.EnterStdMode(); |