mirror of
https://git.lyx.org/repos/lyx.git
synced 2025-01-18 21:45:24 +00:00
* Validator.cpp:
- get rid of unnecessary conversions. git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/branches/BRANCH_1_5_X@26452 a592a061-630c-0410-9148-cb99ea01b6c8
This commit is contained in:
parent
a3855c29df
commit
955925ef22
@ -98,8 +98,7 @@ LengthAutoValidator::LengthAutoValidator(QWidget * parent)
|
||||
|
||||
QValidator::State LengthAutoValidator::validate(QString & qtext, int & dummy) const
|
||||
{
|
||||
string const text = fromqstr(qtext);
|
||||
if (text == "auto")
|
||||
if (qtext == "auto")
|
||||
return QValidator::Acceptable;
|
||||
return LengthValidator::validate(qtext, dummy);
|
||||
}
|
||||
@ -123,8 +122,7 @@ DoubleAutoValidator::DoubleAutoValidator(double bottom,
|
||||
|
||||
|
||||
QValidator::State DoubleAutoValidator::validate(QString & input, int & pos) const {
|
||||
string const text = fromqstr(input);
|
||||
if (text == "auto")
|
||||
if (input == "auto")
|
||||
return QValidator::Acceptable;
|
||||
return QDoubleValidator::validate(input, pos);
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user