summaryrefslogtreecommitdiff
path: root/embeddedobj/source/commonembedding/embedobj.cxx
diff options
context:
space:
mode:
Diffstat (limited to 'embeddedobj/source/commonembedding/embedobj.cxx')
-rw-r--r--embeddedobj/source/commonembedding/embedobj.cxx4
1 files changed, 2 insertions, 2 deletions
diff --git a/embeddedobj/source/commonembedding/embedobj.cxx b/embeddedobj/source/commonembedding/embedobj.cxx
index 32c5085232dc..9aefab91ae79 100644
--- a/embeddedobj/source/commonembedding/embedobj.cxx
+++ b/embeddedobj/source/commonembedding/embedobj.cxx
@@ -65,8 +65,8 @@ awt::Rectangle GetRectangleInterception( const awt::Rectangle& aRect1, const awt
sal_Int32 nBottom1 = aRect1.Y + aRect1.Height;
sal_Int32 nRight2 = aRect2.X + aRect2.Width;
sal_Int32 nBottom2 = aRect2.Y + aRect2.Height;
- aResult.Width = ( nRight1 < nRight2 ? nRight1 : nRight2 ) - aResult.X;
- aResult.Height = ( nBottom1 < nBottom2 ? nBottom1 : nBottom2 ) - aResult.Y;
+ aResult.Width = std::min( nRight1, nRight2 ) - aResult.X;
+ aResult.Height = std::min( nBottom1, nBottom2 ) - aResult.Y;
return aResult;
}