Roo/bootstrap/Progress.js
[roojs1] / Roo / bootstrap / Progress.js
1 /*
2  * - LGPL
3  *
4  * Progress
5  * 
6  */
7
8 /**
9  * @class Roo.bootstrap.Progress
10  * @extends Roo.bootstrap.Component
11  * Bootstrap Progress class
12  * @cfg {Boolean} striped striped of the progress bar
13  * @cfg {Boolean} active animated of the progress bar
14  * 
15  * 
16  * @constructor
17  * Create a new Progress
18  * @param {Object} config The config object
19  */
20
21 Roo.bootstrap.Progress = function(config){
22     Roo.bootstrap.Progress.superclass.constructor.call(this, config);
23 };
24
25 Roo.extend(Roo.bootstrap.Progress, Roo.bootstrap.Component,  {
26     
27     aria_valuenow : false,
28     aria_valuemin : 0,
29     aria_valuemax : 100,
30     label : false,
31     panel : false,
32     role : false,
33     striped : false,
34     active: false,
35     sr_only: false,
36     
37     getAutoCreate : function(){
38         var cfg = {
39             tag: 'div',
40             cls: 'progress',
41             cn: [
42                 {
43                     tag: 'div',
44                     cls: 'progress-bar'
45                 }
46             ]
47         };
48         
49         
50         if(this.striped){
51             cfg.cls += ' progress-striped';
52         }
53       
54         if(this.active){
55             cfg.cls += ' active';
56         }
57         
58         
59         return cfg;
60     }
61    
62 });
63
64  
65
66