*
* - Pman.Tab.* appears to work.
* .. next up ..Dialog...
+ *
+ *
+ *
+ * Current issues:
+ * - xtype is combined on generated files. (not xns + xtype)
+ * - listeners are prefixed with '|' ...
+ *
*
*/
- // perfect for dialogs...
+
+
+
+
+
+ // perfect for dialogs... - is this our 'generic, non-pman code?'
var pos = this.lookFor( 'function');
},
+
parsePmanLayout : function()
{
// then it's a layout style..
},
+ // Seed xobject file.
+ parseXObject : function() {
+
+ this.parseImports();
+
+ var pos = this.lookFor('XObject');
+ if (pos < 0) {
+ throw "Can not find XObject";
+ }
+ this.cfg.name = this.tokens[pos-3].data;
+
+ var cfg = this.tokens[pos+1].items[0][0].props;
+ this.cfg.items = [ this.parseProps(cfg) ];
+
+ //print(JSON.stringify(this.tokens[pos]));
+
+ //print(JSON.stringify(this.tokens,null,4)); Seed.quit();
+ //Seed.quit();
+
+ },
+
/**
parseImports : function()
{
// console.dump(this.tokens);
- this.giImports = [];
+ this.cfg.giImports = [];
+ this.cfg.imports= [];
while (true) {
var pos = this.lookFor('=');
if (pos < 0) {
}
if (v.data.match(/^imports\.gi/)) {
// gi import..
- this.giImports.push(v.data.replace(/imports\.gi\./, ''));
+ this.cfg.giImports.push(v.data.replace(/imports\.gi\./, ''));
this.cursor++;
continue;
// two types of import left
// imports.xnew
if (v.data.match(/^imports\./)) {
- this.imports[k.data] = v.data.replace(/imports\./, '') + '.js';
+ this.cfg.imports[k.data] = v.data.replace(/imports\./, '') + '.js';
this.cursor++;
continue;
}
var bpos = this.lookFor('[');
// console.dump(this.tokens[bpos]);
- this.imports[k.data] = this.tokens[bpos].items[0][0].toJS();
+ this.cfg.imports[k.data] = this.tokens[bpos].items[0][0].toJS();
this.cursor++;
},
-
+ /**
+ * convert a function call token array back into a string
+ */
expand: function(ar)
{
var ret = '';
},
+
+ /***
+ * change the indentation on a function
+ *
+ */
clean_body : function(str)
{
var lns = str.split("\n");