Force empty text property on no visible cell
In some cases, the treeview with fixed height mode computes a too big height for the row which a non visible cell with text. This is an hack to avoid this behavior. issue7667 review49541002
This commit is contained in:
1 parent
2668c6c69c
commit
801ede5790
1 file changed
+6
@@ -219,6 +219,12 @@ class GenericText(Cell):
|
||||
field.state_set(record, states=states)
|
||||
invisible = field.get_state_attrs(record).get('invisible', False)
|
||||
cell.set_property('visible', not invisible)
|
||||
# Sometimes, the treeview with fixed height mode computes a too big
|
||||
# height for not visible cell with text
|
||||
# We can force an empty text because not visible cell can not be edited
|
||||
# and so value_from_text is never called.
|
||||
if invisible:
|
||||
cell.set_property('text', '')
|
||||
|
||||
if editable:
|
||||
readonly = self.attrs.get('readonly',
|
||||
|
||||
Reference in new issue
Block a user