| OLD | NEW |
| 1 | 1 Polymer({ |
| 2 Polymer({ | |
| 3 is: 'paper-button', | 2 is: 'paper-button', |
| 4 | 3 |
| 5 behaviors: [ | 4 behaviors: [ |
| 6 Polymer.PaperButtonBehavior | 5 Polymer.PaperButtonBehavior |
| 7 ], | 6 ], |
| 8 | 7 |
| 9 properties: { | 8 properties: { |
| 10 /** | 9 /** |
| 11 * If true, the button should be styled with a shadow. | 10 * If true, the button should be styled with a shadow. |
| 12 */ | 11 */ |
| 13 raised: { | 12 raised: { |
| 14 type: Boolean, | 13 type: Boolean, |
| 15 reflectToAttribute: true, | 14 reflectToAttribute: true, |
| 16 value: false, | 15 value: false, |
| 17 observer: '_calculateElevation' | 16 observer: '_calculateElevation' |
| 18 } | 17 } |
| 19 }, | 18 }, |
| 20 | 19 |
| 21 _calculateElevation: function() { | 20 _calculateElevation: function() { |
| 22 if (!this.raised) { | 21 if (!this.raised) { |
| 23 this._elevation = 0; | 22 this.elevation = 0; |
| 24 } else { | 23 } else { |
| 25 Polymer.PaperButtonBehaviorImpl._calculateElevation.apply(this); | 24 Polymer.PaperButtonBehaviorImpl._calculateElevation.apply(this); |
| 26 } | 25 } |
| 27 }, | |
| 28 | |
| 29 _computeContentClass: function(receivedFocusFromKeyboard) { | |
| 30 var className = 'content '; | |
| 31 if (receivedFocusFromKeyboard) { | |
| 32 className += ' keyboard-focus'; | |
| 33 } | |
| 34 return className; | |
| 35 } | 26 } |
| 36 }); | 27 }); |
| OLD | NEW |