summaryrefslogtreecommitdiff
path: root/extensions/source/scanner/sanedlg.cxx
diff options
context:
space:
mode:
authorNoel Grandin <noel.grandin@collabora.co.uk>2017-05-26 10:58:42 +0200
committerNoel Grandin <noel.grandin@collabora.co.uk>2017-05-28 19:44:08 +0200
commitef513fd4b049b214a03fbe6e62a5ea43680a7a9b (patch)
tree82f2ce93bc8e5fde6dce8685b633c3d643c9f069 /extensions/source/scanner/sanedlg.cxx
parent826f1bca40a01f0a249d5b6cbb7c39c11638a060 (diff)
remove unnecessary use of OString::getStr
Change-Id: I0490efedf459190521f4339854b3394d57765fdb Reviewed-on: https://gerrit.libreoffice.org/38058 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'extensions/source/scanner/sanedlg.cxx')
-rw-r--r--extensions/source/scanner/sanedlg.cxx9
1 files changed, 2 insertions, 7 deletions
diff --git a/extensions/source/scanner/sanedlg.cxx b/extensions/source/scanner/sanedlg.cxx
index cc712b24ccd3..3813f58eea5e 100644
--- a/extensions/source/scanner/sanedlg.cxx
+++ b/extensions/source/scanner/sanedlg.cxx
@@ -689,9 +689,7 @@ IMPL_LINK( SaneDlg, SelectHdl, ListBox&, rListBox, void )
{
if( &rListBox == mpQuantumRangeBox )
{
- OString aValue(OUStringToOString(mpQuantumRangeBox->GetSelectEntry(),
- osl_getThreadTextEncoding()));
- double fValue = atof(aValue.getStr());
+ double fValue = mpQuantumRangeBox->GetSelectEntry().toDouble();
mrSane.SetOptionValue( mnCurrentOption, fValue, mnCurrentElement );
}
else if( &rListBox == mpStringRangeBox )
@@ -809,10 +807,7 @@ IMPL_LINK( SaneDlg, ModifyHdl, Edit&, rEdit, void )
}
else if( &rEdit == mpNumericEdit )
{
- double fValue;
- OString aContents(OUStringToOString(mpNumericEdit->GetText(),
- osl_getThreadTextEncoding()));
- fValue = atof(aContents.getStr());
+ double fValue = mpNumericEdit->GetText().toDouble();
if( mfMin != mfMax && ( fValue < mfMin || fValue > mfMax ) )
{
char pBuf[256];