diff options
author | Caolán McNamara <caolanm@redhat.com> | 2017-05-16 10:42:49 +0100 |
---|---|---|
committer | Caolán McNamara <caolanm@redhat.com> | 2017-05-16 22:17:28 +0200 |
commit | f0eec7572dfa630f903e91ac44a41f3503112846 (patch) | |
tree | cfcae34dfac59705c8802f892e94b048cf8d2763 /sc | |
parent | 4e52299a6aff1386151223a99e7ed3a49496d967 (diff) |
ExternalZoom and ExternalScroll are unused
which leads to CommandWheelMode::ZOOM_SCALE becoming unused
and so touch/touch.h is unnecessary
Change-Id: I7cb9a4f6af2719deb0d768e35d514b59010daf79
Reviewed-on: https://gerrit.libreoffice.org/37671
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Caolán McNamara <caolanm@redhat.com>
Tested-by: Caolán McNamara <caolanm@redhat.com>
Diffstat (limited to 'sc')
-rw-r--r-- | sc/source/ui/view/tabview.cxx | 17 |
1 files changed, 5 insertions, 12 deletions
diff --git a/sc/source/ui/view/tabview.cxx b/sc/source/ui/view/tabview.cxx index 7610296acd76..2510be1f891a 100644 --- a/sc/source/ui/view/tabview.cxx +++ b/sc/source/ui/view/tabview.cxx @@ -968,8 +968,7 @@ bool ScTabView::ScrollCommand( const CommandEvent& rCEvt, ScSplitPos ePos ) bool bDone = false; const CommandWheelData* pData = rCEvt.GetWheelData(); - if ( pData && (pData->GetMode() == CommandWheelMode::ZOOM || - pData->GetMode() == CommandWheelMode::ZOOM_SCALE ) ) + if (pData && pData->GetMode() == CommandWheelMode::ZOOM) { if ( !aViewData.GetViewShell()->GetViewFrame()->GetFrame().IsInPlace() ) { @@ -979,16 +978,10 @@ bool ScTabView::ScrollCommand( const CommandEvent& rCEvt, ScSplitPos ePos ) const Fraction& rOldY = aViewData.GetZoomY(); long nOld = (long)(( rOldY.GetNumerator() * 100 ) / rOldY.GetDenominator()); long nNew; - if ( pData->GetMode() == CommandWheelMode::ZOOM_SCALE ) - { - nNew = 100 * (long) ((nOld / 100.0) * (pData->GetDelta() / 100.0)); - } else - { - if ( pData->GetDelta() < 0 ) - nNew = std::max( (long) MINZOOM, basegfx::zoomtools::zoomOut( nOld )); - else - nNew = std::min( (long) MAXZOOM, basegfx::zoomtools::zoomIn( nOld )); - } + if ( pData->GetDelta() < 0 ) + nNew = std::max( (long) MINZOOM, basegfx::zoomtools::zoomOut( nOld )); + else + nNew = std::min( (long) MAXZOOM, basegfx::zoomtools::zoomIn( nOld )); if ( nNew != nOld ) { // scroll wheel doesn't set the AppOptions default |