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

Unified Diff: third_party/google_input_tools/src/chrome/os/inputview/elements/content/modifierkey.js

Issue 828063007: Uprev Google Input Tools. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Update extensions schema. Created 5 years, 11 months 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 side-by-side diff with in-line comments
Download patch
Index: third_party/google_input_tools/src/chrome/os/inputview/elements/content/modifierkey.js
diff --git a/third_party/google_input_tools/src/chrome/os/inputview/elements/content/modifierkey.js b/third_party/google_input_tools/src/chrome/os/inputview/elements/content/modifierkey.js
index 1ebb24bee39dd52a50652b57b7606b5e80a8fad3..5fde3d83028c24f9bc6aa7cb3ca55b6c2df11b4d 100644
--- a/third_party/google_input_tools/src/chrome/os/inputview/elements/content/modifierkey.js
+++ b/third_party/google_input_tools/src/chrome/os/inputview/elements/content/modifierkey.js
@@ -24,6 +24,7 @@ goog.require('i18n.input.chrome.inputview.elements.content.FunctionalKey');
goog.scope(function() {
var StateType = i18n.input.chrome.inputview.StateType;
+var Css = i18n.input.chrome.inputview.Css;
@@ -104,8 +105,7 @@ ModifierKey.prototype.createDom = function() {
if (this.toState == i18n.input.chrome.inputview.StateType.CAPSLOCK ||
this.supportSticky) {
var dom = this.getDomHelper();
- this.dotIcon_ = dom.createDom(goog.dom.TagName.DIV,
- i18n.input.chrome.inputview.Css.CAPSLOCK_DOT);
+ this.dotIcon_ = dom.createDom(goog.dom.TagName.DIV, Css.CAPSLOCK_DOT);
dom.appendChild(this.tableCell, this.dotIcon_);
}
@@ -121,13 +121,16 @@ ModifierKey.prototype.update = function() {
this.setHighlighted(isStateEnabled);
if (this.dotIcon_) {
if (isStateEnabled && isSticky && isFinalSticky) {
- goog.dom.classlist.add(this.dotIcon_,
- i18n.input.chrome.inputview.Css.CAPSLOCK_DOT_HIGHLIGHT);
+ goog.dom.classlist.add(this.dotIcon_, Css.CAPSLOCK_DOT_HIGHLIGHT);
} else {
- goog.dom.classlist.remove(this.dotIcon_,
- i18n.input.chrome.inputview.Css.CAPSLOCK_DOT_HIGHLIGHT);
+ goog.dom.classlist.remove(this.dotIcon_, Css.CAPSLOCK_DOT_HIGHLIGHT);
}
}
+ if (isStateEnabled && isSticky && isFinalSticky) {
+ goog.dom.classlist.add(this.bgElem, Css.FUNCITONAL_KEY_STICKY);
+ } else {
+ goog.dom.classlist.remove(this.bgElem, Css.FUNCITONAL_KEY_STICKY);
+ }
};

Powered by Google App Engine
This is Rietveld 408576698