Fix #5660 - roojs docs - linking and other tidy ups
[roojs1] / docs / Roo.docs.js
1 //<script type="text/javascript">
2
3 // Auto generated file - created by app.Builder.js- do not edit directly (at present!)
4
5 Roo.namespace('Roo');
6
7 Roo.docs = new Roo.XComponent({
8
9  _strings : {
10   '3e6ec55e2dff4342e3f25b0b0b988de9' :"Inheritance tree",
11   'ae635f08107a69569e636835f24e6f6f' :" extends ",
12   '87f9f735a1d36793ceaecd4e47124b63' :"Events",
13   'd41d8cd98f00b204e9800998ecf8427e' :"",
14   '9b34238e8113db140b452beec500024b' :"Roo JS Documentation",
15   '50f33d14f129e4548c1c270fd6725a78' :"Configuration options",
16   'e64b94523532dbac62df6795a5153f04' :"doc-desc",
17   '3673e725413179fe76f341ed908a5c36' :"Defined in: ",
18   'd2b697ad8e989a6c4592987f22f5bbfc' :"doc-comments",
19   'f361257612a512f9be2fdc2abfb25aef' :"<small>Defined by</small>",
20   '494a64a432ff6a121e4ab9003c7a0df3' :"parentcls",
21   'f561aaf6ef0bf14d4208bb46a4ccb3ad' :"xxx",
22   '9bd81329febf6efe22788e03ddeaf0af' :" Class ",
23   'a1d108496af420635536a4e29e87d42b' :"Constructor, Static and Public Methods",
24   'd41d8cd98f00b204e9800998ecf8427e' :" "
25  },
26
27   part     :  ["docs", "docs" ],
28   order    : '001-Roo.docs',
29   region   : 'center',
30   parent   : false,
31   name     : "unnamed module",
32   disabled : false, 
33   permname : '', 
34   _tree : function(_data)
35   {
36    var _this = this;
37    var MODULE = this;
38    return {
39    xtype : 'Body',
40    cls : 'doc-body',
41    listeners : {
42     render : function (_self)
43      {
44            
45         
46          
47      }
48    },
49    xns : Roo.bootstrap,
50    '|xns' : 'Roo.bootstrap',
51    items  : [
52     {
53      xtype : 'NavSidebar',
54      cls : 'left-menu-sidebar',
55      listeners : {
56       render : function (_self)
57        {
58          _this.sidebar = this;
59          //  this.el.addClass(language);
60            
61        }
62      },
63      xns : Roo.bootstrap,
64      '|xns' : 'Roo.bootstrap',
65      items  : [
66       {
67        xtype : 'NavGroup',
68        activeLookup : function() 
69        { 
70            return;
71            
72            var pathname = window.location.pathname.substring(baseURL.length);
73            
74            if(!pathname.length){
75                return;
76            }
77            
78            if(pathname.match(/^\/Projects/)){
79                pathname = '/Projects';
80            }
81            
82            var lookupPath = function(item)
83            {
84                if(typeof(item.href) == 'undefined' || !item.href.length || item.href == '#'){
85                    return true;
86                }
87                
88                item.el.removeClass('active');
89                
90                var href = item.href.substring(baseURL.length);
91                
92                if(href != pathname){
93                    return true;
94                }
95                
96                item.el.addClass('active');
97                return false;
98                    
99            };
100            
101            var seted = false;
102            
103            Roo.each(_this.navGroup.items, function(i){
104                
105                var s = lookupPath(i);
106                
107                if(!s){
108                    return false;
109                }
110                
111                if(typeof(i.menu) == 'undefined' || !i.menu.items.length){
112                    return;
113                }
114                
115                Roo.each(i.menu.items, function(ii){
116                    
117                    var ss = lookupPath(ii);
118                    
119                    if(!ss){
120                        seted = true;
121                        return false;
122                    }
123                    
124                });
125                
126                if(seted){
127                    return false;
128                }
129                
130            });
131        },
132        autoExpand : function() 
133        { 
134            return;
135            
136            _this.menu_expand = false;
137            
138            var lookupMenu = function(menu, index){
139                
140                if(menu.target == pagedata.page.target){
141                    _this.menu_expand = index + 1;
142                    return;
143                }
144                
145                if(!menu.children.length){
146                    return;
147                }
148                
149                Roo.each(menu.children, function(c){
150                    lookupMenu(c, index);
151                });
152                
153            }
154            
155            Roo.each(pagemenus, function(v, k){
156                
157                lookupMenu(v, k);
158                
159            });
160            
161            if(_this.menu_expand === false){
162                return;
163            }
164            
165            if(typeof(_this.navGroup.items[_this.menu_expand].menu) == 'undefined'){
166                return;
167            }
168            
169            _this.navGroup.items[_this.menu_expand].menu.show(_this.navGroup.items[_this.menu_expand].el, false, false);
170            
171        },
172        listeners : {
173         childrenrendered : function (_self)
174          {
175              _this.navGroup.autoExpand();
176              
177              _this.navGroup.activeLookup();
178          },
179         render : function (_self)
180          {
181              _this.navGroup = this;
182              
183          }
184        },
185        xns : Roo.bootstrap,
186        '|xns' : 'Roo.bootstrap',
187        items  : [
188         {
189          xtype : 'NavItem',
190          active : false,
191          cls : '',
192          style : 'position:fixed;top:0;z-Index:1000;',
193          xns : Roo.bootstrap,
194          '|xns' : 'Roo.bootstrap',
195          items  : [
196           {
197            xtype : 'Link',
198            cls : 'logo',
199            href : '#',
200            preventDefault : true,
201            listeners : {
202             click : function (e)
203              {
204                  document.location.hash = '#';
205              }
206            },
207            xns : Roo.bootstrap,
208            '|xns' : 'Roo.bootstrap'
209           }
210          ]
211         }
212        ]
213       },
214       {
215        xtype : 'Container',
216        cls : 'left-menu-sidebar-options',
217        xns : Roo.bootstrap,
218        '|xns' : 'Roo.bootstrap',
219        items  : [
220         {
221          xtype : 'Row',
222          xns : Roo.bootstrap,
223          '|xns' : 'Roo.bootstrap'
224         }
225        ]
226       }
227      ]
228     },
229     {
230      xtype : 'NavHeaderbar',
231      autohide : true,
232      brand : ' ',
233      brand_href : '#',
234      cls : 'mobile-header-menu',
235      inverse : false,
236      position : 'fixed-top',
237      style : '',
238      listeners : {
239       beforetoggle : function (_self)
240        {
241           // _this.mobileNavGroup.autoExpand(); 
242            
243           
244             if(!this.el.select('.navbar-collapse',true).first().hasClass('in')){
245                 this.el.select('.navbar-collapse',true).first().removeClass('in');
246                 return true;
247        
248             }
249            if(!this.el.select('.navbar-collapse',true).first().hasClass('in')){
250              //  this.el.select('.navbar-collapse',true).first().setHeight(innerHeight-50);
251                //(function() {
252                //    this.el.select('.navbar-collapse',true).first().setHeight(innerHeight-50);
253                //}).defer(500,this);
254                      
255                return;
256            }
257        },
258       render : function (_self)
259        {
260           
261             _this.navHeaderBar = this;
262            return;
263            /*
264            var body = Roo.select('body', true).first();
265            
266            var mark = {
267                tag: "div",
268                cls:"x-dlg-mask"
269            };
270            
271            this.mask = Roo.DomHelper.append(body, mark, true);
272            
273            var size = body.getSize();
274            this.mask.setSize(size.width, size.height);
275            
276            this.mask.setStyle('z-index', '1029');
277            
278            this.mask.enableDisplayMode("block");
279            this.mask.hide();
280            
281            this.mask.on('click', function(){
282                
283                this.el.select('.navbar-collapse',true).removeClass('in'); 
284                this.mask.hide();
285                
286            }, this);
287            
288            
289            var maxHeight = Roo.lib.Dom.getViewHeight() - this.el.select('.navbar-header', true).first().getHeight();
290            
291            this.el.select('.navbar-collapse', true).first().setStyle('max-height', maxHeight);
292            */
293        }
294      },
295      xns : Roo.bootstrap,
296      '|xns' : 'Roo.bootstrap',
297      items  : [
298       {
299        xtype : 'NavGroup',
300        listeners : {
301         render : function (_self)
302          {
303              _this.mobileNavGroup = this;
304          }
305        },
306        xns : Roo.bootstrap,
307        '|xns' : 'Roo.bootstrap'
308       }
309      ]
310     },
311     {
312      xtype : 'Container',
313      cls : 'general-content-body general-content-intro',
314      listeners : {
315       render : function (_self)
316        {
317               _this.introContainer = this;
318        }
319      },
320      xns : Roo.bootstrap,
321      '|xns' : 'Roo.bootstrap',
322      items  : [
323       {
324        xtype : 'Header',
325        html : _this._strings['9b34238e8113db140b452beec500024b'] /* Roo JS Documentation */,
326        level : 1,
327        xns : Roo.bootstrap,
328        '|xns' : 'Roo.bootstrap'
329       },
330       {
331        xtype : 'Container',
332        listeners : {
333         render : function (_self)
334          {
335              _this.introBody = this;
336          }
337        },
338        xns : Roo.bootstrap,
339        '|xns' : 'Roo.bootstrap'
340       }
341      ]
342     },
343     {
344      xtype : 'Container',
345      cls : 'general-content-body',
346      listeners : {
347       render : function (_self)
348        {
349            _this.doc_body_content = this;
350        }
351      },
352      xns : Roo.bootstrap,
353      '|xns' : 'Roo.bootstrap',
354      items  : [
355       {
356        xtype : 'Row',
357        style : 'margin: 0px;',
358        xns : Roo.bootstrap,
359        '|xns' : 'Roo.bootstrap',
360        items  : [
361         {
362          xtype : 'Column',
363          md : 9,
364          xns : Roo.bootstrap,
365          '|xns' : 'Roo.bootstrap',
366          items  : [
367           {
368            xtype : 'Container',
369            cls : 'doc-header-container',
370            xns : Roo.bootstrap,
371            '|xns' : 'Roo.bootstrap',
372            items  : [
373             {
374              xtype : 'Header',
375              html : _this._strings['9bd81329febf6efe22788e03ddeaf0af'] /*  Class  */,
376              level : 4,
377              xns : Roo.bootstrap,
378              '|xns' : 'Roo.bootstrap',
379              items  : [
380               {
381                xtype : 'Element',
382                cls : 'doc-classname',
383                html : _this._strings['f561aaf6ef0bf14d4208bb46a4ccb3ad'] /* xxx */,
384                style : 'font-size: 24px;\n    font-weight: bold;',
385                tag : 'span',
386                listeners : {
387                 render : function (_self)
388                  {
389                      _this.doc_name = this
390                  }
391                },
392                xns : Roo.bootstrap,
393                '|xns' : 'Roo.bootstrap'
394               },
395               {
396                xtype : 'Element',
397                cls : 'doc-extends-str',
398                html : _this._strings['ae635f08107a69569e636835f24e6f6f'] /*  extends  */,
399                tag : 'small',
400                listeners : {
401                 render : function (_self)
402                  {
403                      _this.doc_extends_sep = this;
404                  }
405                },
406                xns : Roo.bootstrap,
407                '|xns' : 'Roo.bootstrap',
408                items  : [
409                 {
410                  xtype : 'Link',
411                  cls : 'doc-extends',
412                  html : _this._strings['494a64a432ff6a121e4ab9003c7a0df3'] /* parentcls */,
413                  preventDefault : true,
414                  listeners : {
415                   click : function (e)
416                    {
417                    
418                        if (this.el.dom.innerHTML.length) {
419                            document.location.hash = '#' +  this.el.dom.innerHTML;
420                          
421                        } 
422                    },
423                   render : function (_self)
424                    {
425                        _this.doc_extends = this;
426                    }
427                  },
428                  xns : Roo.bootstrap,
429                  '|xns' : 'Roo.bootstrap'
430                 }
431                ]
432               }
433              ]
434             },
435             {
436              xtype : 'Header',
437              html : _this._strings['3673e725413179fe76f341ed908a5c36'] /* Defined in:  */,
438              level : 5,
439              xns : Roo.bootstrap,
440              '|xns' : 'Roo.bootstrap',
441              items  : [
442               {
443                xtype : 'Link',
444                cls : 'doc-source',
445                href : '#',
446                html : _this._strings['3673e725413179fe76f341ed908a5c36'] /* Defined in:  */,
447                preventDefault : true,
448                listeners : {
449                 click : function (e)
450                  {
451                      
452                      Roo.log(["click", this]);
453                      if (this.el.dom.innerHTML.length > 0) {
454                          Roo.docs.init.loadSource();
455                      }
456                  },
457                 render : function (_self)
458                  {
459                      _this.doc_source = this;
460                  }
461                },
462                xns : Roo.bootstrap,
463                '|xns' : 'Roo.bootstrap'
464               }
465              ]
466             }
467            ]
468           },
469           {
470            xtype : 'Container',
471            cls : 'doc-desc',
472            html : _this._strings['e64b94523532dbac62df6795a5153f04'] /* doc-desc */,
473            listeners : {
474             render : function (_self)
475              {
476                  _this.doc_desc = this;
477              }
478            },
479            xns : Roo.bootstrap,
480            '|xns' : 'Roo.bootstrap'
481           },
482           {
483            xtype : 'Container',
484            cls : 'doc-comments',
485            hidden : true,
486            html : _this._strings['d2b697ad8e989a6c4592987f22f5bbfc'] /* doc-comments */,
487            xns : Roo.bootstrap,
488            '|xns' : 'Roo.bootstrap'
489           }
490          ]
491         },
492         {
493          xtype : 'Column',
494          md : 3,
495          xns : Roo.bootstrap,
496          '|xns' : 'Roo.bootstrap',
497          items  : [
498           {
499            xtype : 'Container',
500            cls : 'doc-augments',
501            header : _this._strings['3e6ec55e2dff4342e3f25b0b0b988de9'] /* Inheritance tree */,
502            panel : 'primary',
503            listeners : {
504             render : function (_self)
505              {
506                  _this.augments  = this;
507              }
508            },
509            xns : Roo.bootstrap,
510            '|xns' : 'Roo.bootstrap'
511           }
512          ]
513         }
514        ]
515       },
516       {
517        xtype : 'Container',
518        cls : 'doc-table-container',
519        expandable : true,
520        expanded : true,
521        header : _this._strings['50f33d14f129e4548c1c270fd6725a78'] /* Configuration options */,
522        panel : 'primary',
523        style : 'margin-top:15px',
524        listeners : {
525         render : function (_self)
526          {
527              _this.configTableContainer = this;
528          }
529        },
530        xns : Roo.bootstrap,
531        '|xns' : 'Roo.bootstrap',
532        items  : [
533         {
534          xtype : 'Table',
535          rowSelection : true,
536          striped : true,
537          listeners : {
538           render : function (_self)
539            {
540                _this.configTable = this;
541            },
542           rowclass : function (_self, rowcfg)
543            {
544                  rc = rowcfg.record.json.memberOf == Roo.docs.init.currentClass ? 'doc-added-member '  : 'doc-not-member ';
545                  rowcfg.rowClass = rc + (rowcfg.record.json.expanded ? 'expanded' : '');
546            },
547           rowclick : function (_self, el, rowIndex, e)
548            {
549                if (e.target.className != 'fixedFont' && e.target.parentNode.className != 'fixedFont') {
550                    return false;
551                }
552                
553                var r = this.store.getAt(rowIndex);
554                r.json.expanded = !r.json.expanded ;
555                this.refreshRow(r);
556            }
557          },
558          xns : Roo.bootstrap,
559          '|xns' : 'Roo.bootstrap',
560          store : {
561           xtype : 'Store',
562           xns : Roo.data,
563           '|xns' : 'Roo.data',
564           proxy : {
565            xtype : 'MemoryProxy',
566            xns : Roo.data,
567            '|xns' : 'Roo.data'
568           },
569           reader : {
570            xtype : 'ArrayReader',
571            fields : [ 'name', 'type', 'desc', 'memberOf' ],
572            xns : Roo.data,
573            '|xns' : 'Roo.data'
574           }
575          },
576          cm : [
577           {
578            xtype : 'ColumnModel',
579            dataIndex : 'name',
580            header : _this._strings['d41d8cd98f00b204e9800998ecf8427e'] /*  */,
581            md : 11,
582            renderer : function(v,x,r) { 
583            
584                return Roo.docs.template.config(r.json);
585            
586                                 
587            },
588            xns : Roo.grid,
589            '|xns' : 'Roo.grid'
590           },
591           {
592            xtype : 'ColumnModel',
593            dataIndex : 'memberOf',
594            header : _this._strings['f361257612a512f9be2fdc2abfb25aef'] /* <small>Defined by</small> */,
595            md : 1,
596            renderer : function(v,x,r) { 
597             if (r.json.memberOf  == Roo.docs.init.currentClass) {
598                        return '';
599                    }
600            
601                         return  '<small><a href="#' + r.json.memberOf + '">' + r.json.memberOf + '</a></small>';
602                                 
603            },
604            xs : 0,
605            xns : Roo.grid,
606            '|xns' : 'Roo.grid'
607           }
608          ]
609         }
610        ]
611       },
612       {
613        xtype : 'Container',
614        cls : 'doc-table-container',
615        expandable : true,
616        expanded : true,
617        header : _this._strings['a1d108496af420635536a4e29e87d42b'] /* Constructor, Static and Public Methods */,
618        panel : 'primary',
619        listeners : {
620         render : function (_self)
621          {
622              _this.methodsTableContainer = this;
623          }
624        },
625        xns : Roo.bootstrap,
626        '|xns' : 'Roo.bootstrap',
627        items  : [
628         {
629          xtype : 'Table',
630          rowSelection : true,
631          listeners : {
632           render : function (_self)
633            {
634                _this.methodsTable = this;
635            },
636           rowclass : function (_self, rowcfg)
637            {
638                  var j = rowcfg.record.json;
639                  var rc = j.memberOf == Roo.docs.init.currentClass || j.isConstructor ? 'doc-added-member '  : 'doc-not-member ';
640                  rowcfg.rowClass = rc + (rowcfg.record.json.expanded ? 'expanded' : '');
641            },
642           rowclick : function (_self, el, rowIndex, e)
643            {
644                  if (e.target.className != 'fixedFont' && e.target.parentNode.className != 'fixedFont') {
645                    return false;
646                }
647                 var r = this.store.getAt(rowIndex);
648                r.json.expanded = !r.json.expanded ;
649                this.refreshRow(r);
650            }
651          },
652          xns : Roo.bootstrap,
653          '|xns' : 'Roo.bootstrap',
654          store : {
655           xtype : 'Store',
656           sortInfo : { field : 'name', direction : 'ASC' },
657           xns : Roo.data,
658           '|xns' : 'Roo.data',
659           proxy : {
660            xtype : 'MemoryProxy',
661            xns : Roo.data,
662            '|xns' : 'Roo.data'
663           },
664           reader : {
665            xtype : 'ArrayReader',
666            fields : [ 'name', 'type', 'desc', 'memberOf' ],
667            xns : Roo.data,
668            '|xns' : 'Roo.data'
669           }
670          },
671          cm : [
672           {
673            xtype : 'ColumnModel',
674            dataIndex : 'name',
675            header : _this._strings['d41d8cd98f00b204e9800998ecf8427e'] /*   */,
676            md : 11,
677            renderer : function(v,x,r) { 
678            
679                return Roo.docs.template.method(r.json);
680                          
681                                 
682            },
683            sortable : false,
684            xns : Roo.grid,
685            '|xns' : 'Roo.grid'
686           },
687           {
688            xtype : 'ColumnModel',
689            dataIndex : 'memberOf',
690            header : _this._strings['f361257612a512f9be2fdc2abfb25aef'] /* <small>Defined by</small> */,
691            md : 1,
692            renderer : function(v,x,r) { 
693            
694             if (r.json.memberOf  == Roo.docs.init.currentClass) {
695                        return '';
696                    }
697                         return  '<small><a href="#' + r.json.memberOf + '">' + r.json.memberOf + '</a></small>';
698                                 
699            },
700            xs : 0,
701            xns : Roo.grid,
702            '|xns' : 'Roo.grid'
703           }
704          ]
705         }
706        ]
707       },
708       {
709        xtype : 'Container',
710        cls : 'doc-table-container',
711        expandable : true,
712        expanded : true,
713        header : _this._strings['87f9f735a1d36793ceaecd4e47124b63'] /* Events */,
714        panel : 'primary',
715        listeners : {
716         render : function (_self)
717          {
718              _this.eventsTableContainer   = this;
719          }
720        },
721        xns : Roo.bootstrap,
722        '|xns' : 'Roo.bootstrap',
723        items  : [
724         {
725          xtype : 'Table',
726          rowSelection : true,
727          listeners : {
728           render : function (_self)
729            {
730                _this.eventsTable = this;
731            },
732           rowclass : function (_self, rowcfg)
733            {
734                  rc = rowcfg.record.json.memberOf == Roo.docs.init.currentClass ? 'doc-added-member '  : 'doc-not-member ';
735                  rowcfg.rowClass = rc + (rowcfg.record.json.expanded ? 'expanded' : '');
736            },
737           rowclick : function (_self, el, rowIndex, e)
738            {
739                    if (e.target.className != 'fixedFont' && e.target.parentNode.className != 'fixedFont') {
740                    return false;
741                }
742                var r = this.store.getAt(rowIndex);
743                r.json.expanded = !r.json.expanded ;
744                this.refreshRow(r);
745            }
746          },
747          xns : Roo.bootstrap,
748          '|xns' : 'Roo.bootstrap',
749          store : {
750           xtype : 'Store',
751           xns : Roo.data,
752           '|xns' : 'Roo.data',
753           proxy : {
754            xtype : 'MemoryProxy',
755            xns : Roo.data,
756            '|xns' : 'Roo.data'
757           },
758           reader : {
759            xtype : 'ArrayReader',
760            fields : [ 'name', 'type', 'desc', 'memberOf' ],
761            xns : Roo.data,
762            '|xns' : 'Roo.data'
763           }
764          },
765          cm : [
766           {
767            xtype : 'ColumnModel',
768            dataIndex : 'name',
769            header : _this._strings['d41d8cd98f00b204e9800998ecf8427e'] /*  */,
770            md : 11,
771            renderer : function(v,x,r) { 
772            
773                return Roo.docs.template.event(r.json);
774                          
775                                 
776            },
777            xns : Roo.grid,
778            '|xns' : 'Roo.grid'
779           },
780           {
781            xtype : 'ColumnModel',
782            dataIndex : 'memberOf',
783            header : _this._strings['f361257612a512f9be2fdc2abfb25aef'] /* <small>Defined by</small> */,
784            md : 1,
785            renderer : function(v,x,r) { 
786                    if (r.json.memberOf  == Roo.docs.init.currentClass) {
787                        return '';
788                    }
789            
790                         return  '<small><a href="#' + r.json.memberOf + '">' + r.json.memberOf + '</a></small>';
791                                 
792            },
793            xs : 0,
794            xns : Roo.grid,
795            '|xns' : 'Roo.grid'
796           }
797          ]
798         }
799        ]
800       }
801      ]
802     }
803    ]
804   };  }
805 });