View Full Version : I want to know what is the difference between onRender and constructor
Hi,when I was going to create a new widget which would contain some child widgets,I am always confused whether I should create these widgets in constructor or in onRender() method. Now I just create them in the constructor. Is there any advantages or tricks if I do it in onRender()? :-/
gslender
15 Jan 2009, 4:42 AM
onRender is the correct place to create the widget dom elements - this is the model that GXT uses and should be followed to ensure lazy rendering where possible.
Thank you gslender,you are always so kind to help rookies.Now I want make clear what is the advantage of lazy rendering? To save memory space? If there is no onRender() method in GXT -what will be in trouble?
Powered by vBulletin® Version 4.1.5 Copyright © 2012 vBulletin Solutions, Inc. All rights reserved.