Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(166)

Side by Side Diff: ui/keyboard/resources/elements/kb-altkey-container.js

Issue 730573002: Remove dead code for system VK. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 6 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
(Empty)
1 // Copyright 2014 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
4
5 Polymer('kb-altkey-container', {
6 resetActiveElement: function() {
7 var activeAccentKeySet = this.querySelector('#' + this.keyset);
8 var offset = activeAccentKeySet.offset;
9 var element = activeAccentKeySet.firstElementChild;
10 while (offset) {
11 element = element.nextElementSibling;
12 offset--;
13 }
14 element.classList.add('active');
15 },
16 up: function(detail) {
17 this.hidden = true;
18 this.resetActiveElement();
19 this.keyset = null;
20 },
21 out: function(event) {
22 // Check if touch is outside container boundaries.
23 if(!(this.compareDocumentPosition(event.relatedTarget)
24 & Node.DOCUMENT_POSITION_CONTAINED_BY)) {
25 this.hidden = true;
26 }
27 },
28
29 hiddenChanged: function() {
30 this.fire('stateChange', {
31 state: 'candidatePopupVisibility',
32 value: !!this.hidden
33 });
34 },
35 });
OLDNEW
« no previous file with comments | « ui/keyboard/resources/elements/kb-altkey-container.html ('k') | ui/keyboard/resources/elements/kb-altkey-data.html » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698