Created
February 14, 2011 11:06
-
-
Save teramako/825738 to your computer and use it in GitHub Desktop.
Vimperator patch for http://code.google.com/p/vimperator-labs/issues/detail?id=483
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
diff -r d1cf77d3a834 common/content/commandline.js | |
--- a/common/content/commandline.js Sat Feb 12 15:58:01 2011 +0100 | |
+++ b/common/content/commandline.js Mon Feb 14 20:04:45 2011 +0900 | |
@@ -132,6 +132,7 @@ | |
this._commandWidget = document.getElementById("liberator-commandline-command"); | |
this._messageBox = document.getElementById("liberator-message"); | |
+ this._messageBox.addEventListener("transitionend", this.close.bind(this), false); | |
this._commandWidget.inputField.QueryInterface(Ci.nsIDOMNSEditableElement); | |
//this._messageBox.inputField.QueryInterface(Ci.nsIDOMNSEditableElement); | |
@@ -252,7 +253,13 @@ | |
*/ | |
_echoLine: function (str, highlightGroup, forceSingle) { | |
this._setHighlightGroup(highlightGroup); | |
+ this._messageBox.style.width = "auto"; | |
this._messageBox.value = str; | |
+ if (str && [this.HL_INFOMSG, this.HL_ERRORMSG, this.HL_NORMAL, this.HL_WARNINGMSG].indexOf(highlightGroup) != -1) { | |
+ this._messageBox.style.width = "-moz-calc(" + window.getComputedStyle(this._messageBox, "").width + " + 1em)"; | |
+ let self = this;; | |
+ window.setTimeout(function(){self._messageBox.style.width = "";}, 0); | |
+ } | |
liberator.triggerObserver("echoLine", str, highlightGroup, forceSingle); | |
diff -r d1cf77d3a834 common/content/finder.js | |
--- a/common/content/finder.js Sat Feb 12 15:58:01 2011 +0100 | |
+++ b/common/content/finder.js Mon Feb 14 20:04:45 2011 +0900 | |
@@ -414,14 +414,14 @@ | |
mappings.add(myModes.concat([modes.CARET, modes.TEXTAREA]), ["*"], | |
"Find word under cursor", | |
function () { | |
- this._found = false; | |
+ finder._found = false; | |
finder.onSubmit(buffer.getCurrentWord(), false); | |
}); | |
mappings.add(myModes.concat([modes.CARET, modes.TEXTAREA]), ["#"], | |
"Find word under cursor backwards", | |
function () { | |
- this._found = false; | |
+ finder._found = false; | |
finder.onSubmit(buffer.getCurrentWord(), true); | |
}); | |
}, | |
diff -r d1cf77d3a834 common/skin/liberator.css | |
--- a/common/skin/liberator.css Sat Feb 12 15:58:01 2011 +0100 | |
+++ b/common/skin/liberator.css Mon Feb 14 20:04:45 2011 +0900 | |
@@ -131,6 +131,8 @@ | |
} | |
#liberator-message { | |
margin: 0px; | |
+ width: 0; | |
+ -moz-transition: width 1s 3s; | |
} | |
#sidebar { |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment