def populate_tlc_children(self,tlc_id):
#controls_generator=generator(controls)
child_comments_tuple_generator=generator(self.child_lists[tlc_id])
for control_id in self.x_controls:
control=self.getControl(control_id)
try:
post_text,author,depth=child_comments_tuple_generator.next()
except StopIteration:
post_text,author,depth=None,None,0
if post_text:
#control.setText( ("[B]"+repr(control_id-1000)+"[/B] " + post_text) if post_text else None)
#control.setText(post_text+' '+author)
#log(('.'*depth)+repr(post_text))
control.setText(post_text)
else:
control.setText(None)
#use animation to stagger the comments according to how deep they are
control.setAnimations( [ animation_format(0,100,'slide', 0, (20*depth), 'sine', 'in' ) ] )
#either there's no more child comments or we run out of controls
return
评论列表
文章目录