Kaydet (Commit) 113dca13 authored tarafından Tor Lillqvist's avatar Tor Lillqvist

WaE: int and long confusion

üst 51dccd65
......@@ -359,11 +359,11 @@ sal_Bool SvxZoomSliderControl::MouseButtonDown( const MouseEvent & rEvt )
// click to - button
if ( nXDiff >= nButtonLeftOffset && nXDiff <= nButtonRightOffset )
mpImpl->mnCurrentZoom = basegfx::zoomtools::zoomOut( mpImpl->mnCurrentZoom );
mpImpl->mnCurrentZoom = basegfx::zoomtools::zoomOut( static_cast<int>(mpImpl->mnCurrentZoom) );
// click to + button
else if ( nXDiff >= aControlRect.GetWidth() - nSliderXOffset + nButtonLeftOffset &&
nXDiff <= aControlRect.GetWidth() - nSliderXOffset + nButtonRightOffset )
mpImpl->mnCurrentZoom = basegfx::zoomtools::zoomIn( mpImpl->mnCurrentZoom );
mpImpl->mnCurrentZoom = basegfx::zoomtools::zoomIn( static_cast<int>(mpImpl->mnCurrentZoom) );
// click to slider
else if( nXDiff >= nSliderXOffset && nXDiff <= aControlRect.GetWidth() - nSliderXOffset )
mpImpl->mnCurrentZoom = Offset2Zoom( nXDiff );
......
......@@ -1311,9 +1311,9 @@ sal_Bool SwView::HandleWheelCommands( const CommandEvent& rCEvt )
{
sal_uInt16 nFact = pWrtShell->GetViewOptions()->GetZoom();
if( 0L > pWData->GetDelta() )
nFact = static_cast< sal_uInt16 >(Max( 20, basegfx::zoomtools::zoomOut( nFact )));
nFact = static_cast< sal_uInt16 >(Max( 20, basegfx::zoomtools::zoomOut( static_cast<int>(nFact) )));
else
nFact = static_cast< sal_uInt16 >(Min( 600, basegfx::zoomtools::zoomIn( nFact )));
nFact = static_cast< sal_uInt16 >(Min( 600, basegfx::zoomtools::zoomIn( static_cast<int>(nFact) )));
SetZoom( SVX_ZOOM_PERCENT, nFact );
bOk = sal_True;
......
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