mirror of
https://github.com/kovidgoyal/calibre.git
synced 2025-07-31 14:33:54 -04:00
...
This commit is contained in:
parent
d4c9b0b6fd
commit
fc132d6fcc
@ -25,7 +25,7 @@ class Control(object):
|
|||||||
def fget(self):
|
def fget(self):
|
||||||
if self.type in ('checkbox', 'radio'):
|
if self.type in ('checkbox', 'radio'):
|
||||||
return unicode(self.qwe.attribute('checked')) == 'checked'
|
return unicode(self.qwe.attribute('checked')) == 'checked'
|
||||||
if self.type in ('text', 'password'):
|
if self.type in ('text', 'password', 'hidden'):
|
||||||
return unicode(self.qwe.attribute('value'))
|
return unicode(self.qwe.attribute('value'))
|
||||||
|
|
||||||
def fset(self, val):
|
def fset(self, val):
|
||||||
@ -34,7 +34,7 @@ class Control(object):
|
|||||||
self.qwe.setAttribute('checked', 'checked')
|
self.qwe.setAttribute('checked', 'checked')
|
||||||
else:
|
else:
|
||||||
self.qwe.removeAttribute('checked')
|
self.qwe.removeAttribute('checked')
|
||||||
elif self.type in ('text', 'password'):
|
elif self.type in ('text', 'password', 'hidden'):
|
||||||
self.qwe.setAttribute('value', as_unicode(val))
|
self.qwe.setAttribute('value', as_unicode(val))
|
||||||
|
|
||||||
return property(fget=fget, fset=fset)
|
return property(fget=fget, fset=fset)
|
||||||
|
Loading…
x
Reference in New Issue
Block a user