Kaydet (Commit) a49cd863 authored tarafından Michael Meeks's avatar Michael Meeks

targetted cppcheck warning fix reversion

Change-Id: I44bafcc62a127f2d7c6da2952573e4128783c342
üst 3f5762b6
...@@ -696,6 +696,7 @@ void SpinField::ImplCalcButtonAreas( OutputDevice* pDev, const Size& rOutSz, Rec ...@@ -696,6 +696,7 @@ void SpinField::ImplCalcButtonAreas( OutputDevice* pDev, const Size& rOutSz, Rec
long nBottom1 = aSize.Height()/2; long nBottom1 = aSize.Height()/2;
long nBottom2 = aSize.Height()-1; long nBottom2 = aSize.Height()-1;
long nTop2 = nBottom1; long nTop2 = nBottom1;
long nTop1 = 0;
if ( !(aSize.Height() & 0x01) ) if ( !(aSize.Height() & 0x01) )
nBottom1--; nBottom1--;
...@@ -740,7 +741,6 @@ void SpinField::ImplCalcButtonAreas( OutputDevice* pDev, const Size& rOutSz, Rec ...@@ -740,7 +741,6 @@ void SpinField::ImplCalcButtonAreas( OutputDevice* pDev, const Size& rOutSz, Rec
} }
else else
{ {
long nTop1 = 0;
aSize.Width() -= CalcZoom( GetDrawPixel( pDev, rStyleSettings.GetSpinSize() ) ); aSize.Width() -= CalcZoom( GetDrawPixel( pDev, rStyleSettings.GetSpinSize() ) );
rSpinUpArea = Rectangle( aSize.Width(), nTop1, rOutSz.Width()-aDropDownSize.Width()-1, nBottom1 ); rSpinUpArea = Rectangle( aSize.Width(), nTop1, rOutSz.Width()-aDropDownSize.Width()-1, nBottom1 );
......
...@@ -3601,8 +3601,12 @@ void OutputDevice::ImplDrawWaveLine( long nBaseX, long nBaseY, ...@@ -3601,8 +3601,12 @@ void OutputDevice::ImplDrawWaveLine( long nBaseX, long nBaseY,
{ {
long nCurX = nStartX; long nCurX = nStartX;
long nCurY = nStartY; long nCurY = nStartY;
long nDiffX = 2;
long nDiffY = nHeight-1; long nDiffY = nHeight-1;
long nCount = nWidth; long nCount = nWidth;
long nOffY = -1;
long nFreq;
long i;
long nPixWidth; long nPixWidth;
long nPixHeight; long nPixHeight;
sal_Bool bDrawPixAsRect; sal_Bool bDrawPixAsRect;
...@@ -3642,11 +3646,8 @@ void OutputDevice::ImplDrawWaveLine( long nBaseX, long nBaseY, ...@@ -3642,11 +3646,8 @@ void OutputDevice::ImplDrawWaveLine( long nBaseX, long nBaseY,
} }
else else
{ {
long nDiffX = 2;
long nOffY = -1;
long i;
nCurY += nDiffY; nCurY += nDiffY;
long nFreq = nCount / (nDiffX+nDiffY); nFreq = nCount / (nDiffX+nDiffY);
while ( nFreq-- ) while ( nFreq-- )
{ {
for( i = nDiffY; i; --i ) for( i = nDiffY; i; --i )
...@@ -4914,6 +4915,7 @@ long OutputDevice::ImplGetTextLines( ImplMultiTextLineInfo& rLineInfo, ...@@ -4914,6 +4915,7 @@ long OutputDevice::ImplGetTextLines( ImplMultiTextLineInfo& rLineInfo,
// auf mehr als Zwei Zeilen gebrochen wird... // auf mehr als Zwei Zeilen gebrochen wird...
if ( xHyph.is() ) if ( xHyph.is() )
{ {
sal_Unicode cAlternateReplChar = 0;
i18n::Boundary aBoundary = xBI->getWordBoundary( aText, nBreakPos, rDefLocale, ::com::sun::star::i18n::WordType::DICTIONARY_WORD, sal_True ); i18n::Boundary aBoundary = xBI->getWordBoundary( aText, nBreakPos, rDefLocale, ::com::sun::star::i18n::WordType::DICTIONARY_WORD, sal_True );
// sal_uInt16 nWordStart = nBreakPos; // sal_uInt16 nWordStart = nBreakPos;
// sal_uInt16 nBreakPos_OLD = nBreakPos; // sal_uInt16 nBreakPos_OLD = nBreakPos;
...@@ -4985,8 +4987,6 @@ long OutputDevice::ImplGetTextLines( ImplMultiTextLineInfo& rLineInfo, ...@@ -4985,8 +4987,6 @@ long OutputDevice::ImplGetTextLines( ImplMultiTextLineInfo& rLineInfo,
DBG_ASSERT( ( nAltEnd - nAltStart ) == 1, "Alternate: Falsche Annahme!" ); DBG_ASSERT( ( nAltEnd - nAltStart ) == 1, "Alternate: Falsche Annahme!" );
sal_Unicode cAlternateReplChar = 0;
if ( nTxtEnd > nTxtStart ) if ( nTxtEnd > nTxtStart )
cAlternateReplChar = aAlt.GetChar( nAltStart ); cAlternateReplChar = aAlt.GetChar( nAltStart );
......
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