Commit e96e229c authored by Romain Courteaud's avatar Romain Courteaud

Change implementation of setListboxLineContentMode.


git-svn-id: https://svn.erp5.org/repos/public/erp5/trunk@2986 20353a03-c40f-0410-a6d1-a30d3c3de9de
parent a9975383
......@@ -2144,26 +2144,17 @@ class ListBoxLine:
content_mode can be 'TitleLine' 'StatLine' 'DataLine'
Default value is 'DataLine'
"""
if content_mode == 'TitleLine':
self.is_title_line = 1
self.is_data_line = 0
self.is_stat_line = 0
self.is_summary_line = 0
elif content_mode == 'DataLine':
self.is_title_line = 0
self.is_data_line = 1
self.is_stat_line = 0
self.is_summary_line = 0
elif content_mode == 'StatLine':
self.is_title_line = 0
self.is_data_line = 0
self.is_stat_line = 1
self.is_summary_line = 0
elif content_mode == 'SummaryLine':
self.is_title_line = 0
self.is_data_line = 0
self.is_stat_line = 0
self.is_summary_line = 1
content_mode_dict = {
'TitleLine':(1,0,0,0),
'DataLine':(0,1,0,0),
'StatLine':(0,0,1,0),
'SummaryLine':(0,0,0,1)
}
self.is_title_line,\
self.is_data_line,\
self.is_stat_line,\
self.is_summary_line = content_mode_dict[content_mode]
self.setConfigProperty('content_mode',content_mode)
#security.declarePublic('View')
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment