diff options
author | Caolán McNamara <caolanm@redhat.com> | 2014-06-04 12:36:06 +0100 |
---|---|---|
committer | Caolán McNamara <caolanm@redhat.com> | 2014-06-04 12:36:06 +0100 |
commit | 079e57658b7ca5d8dc99d049fc8ed63b19776b37 (patch) | |
tree | 857effc169559d82f2e7388cd49d6bae34dbc84a /sdext | |
parent | cc93bcf75154ac7dbcf89024c5cfbb406521b39d (diff) |
coverity#982645 bMissingDefaultsToNormal is always true
Change-Id: Ica58be0b5512eb8f386e51ec6e84d0ec09c3027f
Diffstat (limited to 'sdext')
-rw-r--r-- | sdext/source/presenter/PresenterBitmapContainer.cxx | 12 | ||||
-rw-r--r-- | sdext/source/presenter/PresenterBitmapContainer.hxx | 6 |
2 files changed, 7 insertions, 11 deletions
diff --git a/sdext/source/presenter/PresenterBitmapContainer.cxx b/sdext/source/presenter/PresenterBitmapContainer.cxx index 020d1d5c2ece..a2365592f6f7 100644 --- a/sdext/source/presenter/PresenterBitmapContainer.cxx +++ b/sdext/source/presenter/PresenterBitmapContainer.cxx @@ -334,15 +334,13 @@ PresenterBitmapContainer::BitmapDescriptor::BitmapDescriptor ( } css::uno::Reference<css::rendering::XBitmap> - PresenterBitmapContainer::BitmapDescriptor::GetNormalBitmap (void) const + PresenterBitmapContainer::BitmapDescriptor::GetNormalBitmap() const { return mxNormalBitmap; } css::uno::Reference<css::rendering::XBitmap> - PresenterBitmapContainer::BitmapDescriptor::GetBitmap ( - const Mode eMode, - const bool bMissingDefaultsToNormal) const + PresenterBitmapContainer::BitmapDescriptor::GetBitmap(const Mode eMode) const { switch (eMode) { @@ -353,19 +351,19 @@ css::uno::Reference<css::rendering::XBitmap> case MouseOver: if (mxMouseOverBitmap.is()) return mxMouseOverBitmap; - else if (bMissingDefaultsToNormal) + else return mxNormalBitmap; case ButtonDown: if (mxButtonDownBitmap.is()) return mxButtonDownBitmap; - else if (bMissingDefaultsToNormal) + else return mxNormalBitmap; case Disabled: if (mxDisabledBitmap.is()) return mxDisabledBitmap; - else if (bMissingDefaultsToNormal) + else return mxNormalBitmap; case Mask: diff --git a/sdext/source/presenter/PresenterBitmapContainer.hxx b/sdext/source/presenter/PresenterBitmapContainer.hxx index 6c6f6e665b7c..05092f59c4b2 100644 --- a/sdext/source/presenter/PresenterBitmapContainer.hxx +++ b/sdext/source/presenter/PresenterBitmapContainer.hxx @@ -53,10 +53,8 @@ public: BitmapDescriptor (const ::boost::shared_ptr<BitmapDescriptor>& rpDefault); enum Mode {Normal, MouseOver, ButtonDown, Disabled, Mask}; - css::uno::Reference<css::rendering::XBitmap> GetNormalBitmap (void) const; - css::uno::Reference<css::rendering::XBitmap> GetBitmap ( - const Mode eMode, - const bool bMissingDefaultsToNormal = true) const; + css::uno::Reference<css::rendering::XBitmap> GetNormalBitmap() const; + css::uno::Reference<css::rendering::XBitmap> GetBitmap(const Mode eMode) const; void SetBitmap ( const Mode eMode, const css::uno::Reference<css::rendering::XBitmap>& rxBitmap); |