This article describes how QxTransformer generates application. Auto generated class: qx.Class.define("feedback.Application", { extend : qx.application.Standalone, members : { main: function() { //1 - call base class constructor this.base(arguments); // 2 - call function which constructs application UI this.__qxtCreateUI(); // 3 - call post create UI function if defined }, //create UI function __qxtCreateUI : function() { },
//event listeners }); Auto generated application life cycle 1) Calls base class constructor. 2) Calls function which constructs all UI. It contains all code generated by qxtransformer. 3) Calls post create UI function. Sometimes you need to do some operations when your UI has been built. In this case you can use post create function. You need to define initFunctionName (name will be changed in future) attribute name in your qx:application tag. xmlns:qx="http://www.qxtransformer.org/qooxdoo/0.8" xmlns:qxt="http://www.qxtransformer.org/extension/0.4" xmlns:fb="feedback.*" className="feedback.Application" extend=”feedback.ApplicationInit” initFunctionName=”__qxtPostCreateUI” > ... </qx:application> After that you should define __qxtPostCreateUI function in feedback.ApplicationInit base class. Main function of feedback.Application will look as main: function() { //1 - call base class constructor this.base(arguments); // 2 - call function which constructs application UI this.__qxtCreateUI(); // 3 - call post create UI function if defined this.__qxtPostCreateUI(); } |