Correction for spinbox auto-selection without suffix
This commit is contained in:
parent
2d78ce6f87
commit
ad10b06652
|
@ -240,6 +240,9 @@ class SpinBox(QtGui.QAbstractSpinBox):
|
||||||
"""
|
"""
|
||||||
le = self.lineEdit()
|
le = self.lineEdit()
|
||||||
text = asUnicode(le.text())
|
text = asUnicode(le.text())
|
||||||
|
if self.opts['suffix'] == '':
|
||||||
|
le.setSelection(0, len(text))
|
||||||
|
else:
|
||||||
try:
|
try:
|
||||||
index = text.index(' ')
|
index = text.index(' ')
|
||||||
except ValueError:
|
except ValueError:
|
||||||
|
|
Loading…
Reference in New Issue
Block a user