chart2/source/controller/dialogs/dlg_DataEditor.cxx | 3 +-- chart2/source/tools/ThreeDHelper.cxx | 6 ++---- dtrans/source/win32/clipb/MtaOleClipb.cxx | 3 +-- 3 files changed, 4 insertions(+), 8 deletions(-)
New commits: commit 30e72a9a36750b7326803fa8fa1b8d40648e7e89 Author: Julien Nabet <serval2...@yahoo.fr> Date: Sun Sep 29 22:49:15 2013 +0200 cppcheck: some cleanings Change-Id: Ie41b33c09d79b40116cc10f7557987860acb55e8 diff --git a/chart2/source/controller/dialogs/dlg_DataEditor.cxx b/chart2/source/controller/dialogs/dlg_DataEditor.cxx index 6a4bb14..0495b2a 100644 --- a/chart2/source/controller/dialogs/dlg_DataEditor.cxx +++ b/chart2/source/controller/dialogs/dlg_DataEditor.cxx @@ -93,8 +93,7 @@ DataEditor::DataEditor( sal_Int32 nMaxWidth = GetDesktopRectPixel().getWidth() - (aWinSizeWithBorder.getWidth() - aWinSize.getWidth() + aWinPos.getX()) - 10; // leave some space sal_Int32 nBrowserWidth = m_apBrwData->GetTotalWidth() + 12 + 16; // plus padding + 16? - sal_Int32 nWindowWidth = ::std::max( nMinWidth, nBrowserWidth ); - nWindowWidth = ::std::min( nMaxWidth, nBrowserWidth ); + sal_Int32 nWindowWidth = ::std::min( nMaxWidth, nBrowserWidth ); aWinSize.setWidth( nWindowWidth ); SetOutputSizePixel( aWinSize ); AdaptBrowseBoxSize(); diff --git a/chart2/source/tools/ThreeDHelper.cxx b/chart2/source/tools/ThreeDHelper.cxx index 47502c8..81d20a1 100644 --- a/chart2/source/tools/ThreeDHelper.cxx +++ b/chart2/source/tools/ThreeDHelper.cxx @@ -1157,7 +1157,6 @@ void ThreeDHelper::setCameraDistance( double ThreeDHelper::CameraDistanceToPerspective( double fCameraDistance ) { - double fRet = fCameraDistance; double fMin, fMax; ThreeDHelper::getCameraDistanceRange( fMin, fMax ); //fMax <-> 0; fMin <->100 @@ -1165,14 +1164,13 @@ double ThreeDHelper::CameraDistanceToPerspective( double fCameraDistance ) double a = 100.0*fMax*fMin/(fMax-fMin); double b = -a/fMax; - fRet = a/fCameraDistance + b; + double fRet = a/fCameraDistance + b; return fRet; } double ThreeDHelper::PerspectiveToCameraDistance( double fPerspective ) { - double fRet = fPerspective; double fMin, fMax; ThreeDHelper::getCameraDistanceRange( fMin, fMax ); //fMax <-> 0; fMin <->100 @@ -1180,7 +1178,7 @@ double ThreeDHelper::PerspectiveToCameraDistance( double fPerspective ) double a = 100.0*fMax*fMin/(fMax-fMin); double b = -a/fMax; - fRet = a/(fPerspective - b); + double fRet = a/(fPerspective - b); return fRet; } diff --git a/dtrans/source/win32/clipb/MtaOleClipb.cxx b/dtrans/source/win32/clipb/MtaOleClipb.cxx index d893dd4..365e869 100644 --- a/dtrans/source/win32/clipb/MtaOleClipb.cxx +++ b/dtrans/source/win32/clipb/MtaOleClipb.cxx @@ -399,7 +399,6 @@ HRESULT CMtaOleClipboard::getClipboard( IDataObject** ppIDataObject ) CAutoComInit comAutoInit; LPSTREAM lpStream; - HRESULT hr = E_FAIL; *ppIDataObject = NULL; @@ -411,7 +410,7 @@ HRESULT CMtaOleClipboard::getClipboard( IDataObject** ppIDataObject ) aMsgCtx.aCondition.wait( /* infinite */ ); - hr = aMsgCtx.hr; + HRESULT hr = aMsgCtx.hr; if ( SUCCEEDED( hr ) ) { _______________________________________________ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits