diff options
author | Mike Kaganski <mike.kaganski@collabora.com> | 2021-12-26 09:11:53 +0100 |
---|---|---|
committer | Mike Kaganski <mike.kaganski@collabora.com> | 2022-01-02 09:03:32 +0100 |
commit | 9f4aad493c7087256d03b01ca3fb18d96f461526 (patch) | |
tree | 6db1c950085bd2809cfb2e1ecf9ddcd3537da961 /extensions | |
parent | 41ee9dcc4e12c32d49294dd4b19a97cb24f8253f (diff) |
Introduce OUString::unacquired(const OUStringBuffer&)
... and avoid OUStringBuffer::toString when the temporary is used
for checking current buffer content
Change-Id: I114178f3e74ca3e4a3e517763f9eaab4797b7deb
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/127478
Tested-by: Jenkins
Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com>
Diffstat (limited to 'extensions')
-rw-r--r-- | extensions/source/propctrlr/browserline.cxx | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/extensions/source/propctrlr/browserline.cxx b/extensions/source/propctrlr/browserline.cxx index a42b63c10e9b..814c24f4b306 100644 --- a/extensions/source/propctrlr/browserline.cxx +++ b/extensions/source/propctrlr/browserline.cxx @@ -179,7 +179,7 @@ namespace pcr OUStringBuffer aText(m_xFtTitle->get_label()); int n10DotsWidth = m_xFtTitle->get_pixel_size("..........").Width(); - int nTextWidth = m_xFtTitle->get_pixel_size(aText.toString()).Width(); + int nTextWidth = m_xFtTitle->get_pixel_size(OUString::unacquired(aText)).Width(); int nDiff = m_nNameWidth - nTextWidth; int nExtraChars = (nDiff * 10) / n10DotsWidth; for (int i = 0; i < nExtraChars; ++i) |