| Index: polymer_1.2.3/bower_components/iron-a11y-keys-behavior/demo/x-key-aware.html
|
| diff --git a/polymer_1.0.4/bower_components/iron-a11y-keys-behavior/demo/x-key-aware.html b/polymer_1.2.3/bower_components/iron-a11y-keys-behavior/demo/x-key-aware.html
|
| similarity index 77%
|
| copy from polymer_1.0.4/bower_components/iron-a11y-keys-behavior/demo/x-key-aware.html
|
| copy to polymer_1.2.3/bower_components/iron-a11y-keys-behavior/demo/x-key-aware.html
|
| index a7f3205d1589c1d79a7dc186765f5fb325bbbceb..16b9b2a518dc556df6a4392d65f824a6b3107069 100644
|
| --- a/polymer_1.0.4/bower_components/iron-a11y-keys-behavior/demo/x-key-aware.html
|
| +++ b/polymer_1.2.3/bower_components/iron-a11y-keys-behavior/demo/x-key-aware.html
|
| @@ -9,7 +9,7 @@ subject to an additional IP rights grant found at http://polymer.github.io/PATEN
|
| -->
|
|
|
| <link rel="import" href="../../polymer/polymer.html">
|
| -<link rel="import" href="../../paper-styles/paper-styles.html">
|
| +<link rel="import" href="../../paper-styles/color.html">
|
| <link rel="import" href="../iron-a11y-keys-behavior.html">
|
|
|
| <dom-module id="x-key-aware">
|
| @@ -22,7 +22,7 @@ subject to an additional IP rights grant found at http://polymer.github.io/PATEN
|
| pre {
|
| color: var(--google-blue-700);
|
| }
|
| -
|
| +
|
| .keys {
|
| line-height: 25px;
|
| }
|
| @@ -37,6 +37,7 @@ subject to an additional IP rights grant found at http://polymer.github.io/PATEN
|
| </style>
|
| <template>
|
| <h4>Press any of these keys</h4>
|
| + <input type="checkbox" checked="{{preventDefault::change}}"> prevent default = {{preventDefault}}
|
| <p class="keys">
|
| <template is="dom-repeat" items="[[boundKeys]]">
|
| <span>{{item}}</span>
|
| @@ -68,6 +69,12 @@ subject to an additional IP rights grant found at http://polymer.github.io/PATEN
|
| }
|
| },
|
|
|
| + preventDefault: {
|
| + type: Boolean,
|
| + value: true,
|
| + notify: true
|
| + },
|
| +
|
| keyEventTarget: {
|
| type: Object,
|
| value: function() {
|
| @@ -77,12 +84,18 @@ subject to an additional IP rights grant found at http://polymer.github.io/PATEN
|
| },
|
|
|
| keyBindings: {
|
| - '* pageup pagedown left right down up shift+a alt+a home end space enter': '_updatePressed'
|
| + '* pageup pagedown left right down up home end space enter @ ~ " $ ? ! \\ + : # backspace': '_updatePressed',
|
| + 'a': '_updatePressed',
|
| + 'shift+a alt+a': '_updatePressed',
|
| + 'shift+tab shift+space': '_updatePressed'
|
| },
|
|
|
| _updatePressed: function(event) {
|
| console.log(event.detail);
|
|
|
| + if (this.preventDefault) {
|
| + event.preventDefault();
|
| + }
|
| this._setPressed(
|
| this.pressed + event.detail.combo + ' pressed!\n'
|
| );
|
|
|