diff --git a/cppcanvas/source/mtfrenderer/mtftools.cxx b/cppcanvas/source/mtfrenderer/mtftools.cxx index c5d36eb00652..0181fa78ec9c 100644 --- a/cppcanvas/source/mtfrenderer/mtftools.cxx +++ b/cppcanvas/source/mtfrenderer/mtftools.cxx @@ -61,10 +61,6 @@ namespace cppcanvas::tools return ::Size( 0, aMetric.GetInternalLeading() + aMetric.GetAscent() ); - default: - ENSURE_OR_THROW( false, - "tools::getBaselineOffset(): Unexpected TextAlign value" ); - // FALLTHROUGH intended (to calm compiler warning - case won't happen) case ALIGN_BASELINE: return ::Size( 0, 0 ); @@ -72,6 +68,9 @@ namespace cppcanvas::tools return ::Size( 0, -aMetric.GetDescent() ); + default: + throw css::uno::RuntimeException( + "tools::getBaselineOffset(): Unexpected TextAlign value" ); } } diff --git a/slideshow/source/engine/animationnodes/animationtransformnode.cxx b/slideshow/source/engine/animationnodes/animationtransformnode.cxx index 624bad401e8b..cbb68b024316 100644 --- a/slideshow/source/engine/animationnodes/animationtransformnode.cxx +++ b/slideshow/source/engine/animationnodes/animationtransformnode.cxx @@ -45,8 +45,8 @@ AnimationActivitySharedPtr AnimationTransformNode::createActivity() const switch( nTransformType ) { default: - ENSURE_OR_THROW( - false, "AnimationTransformNode::createTransformActivity(): " + throw css::uno::RuntimeException( + "AnimationTransformNode::createTransformActivity(): " "Unknown transform type" ); case animations::AnimationTransformType::TRANSLATE: