mirror of
https://github.com/grafana/grafana.git
synced 2025-02-25 18:55:37 -06:00
rename inputBlur to switchToLink
This commit is contained in:
parent
02abda7d92
commit
f140967423
@ -53,7 +53,7 @@ export function sqlPartEditorDirective($compile, templateSrv) {
|
||||
}
|
||||
}
|
||||
|
||||
function inputBlur(paramIndex) {
|
||||
function switchToLink(paramIndex) {
|
||||
/*jshint validthis:true */
|
||||
var $input = $(this);
|
||||
var $link = $input.prev();
|
||||
@ -75,7 +75,7 @@ export function sqlPartEditorDirective($compile, templateSrv) {
|
||||
function inputKeyPress(paramIndex, e) {
|
||||
/*jshint validthis:true */
|
||||
if (e.which === 13) {
|
||||
inputBlur.call(this, paramIndex);
|
||||
switchToLink.call(this, paramIndex);
|
||||
}
|
||||
}
|
||||
|
||||
@ -124,7 +124,7 @@ export function sqlPartEditorDirective($compile, templateSrv) {
|
||||
items: 1000,
|
||||
updater: function(value) {
|
||||
setTimeout(function() {
|
||||
inputBlur.call($input[0], paramIndex);
|
||||
switchToLink.call($input[0], paramIndex);
|
||||
}, 0);
|
||||
return value;
|
||||
},
|
||||
@ -169,7 +169,7 @@ export function sqlPartEditorDirective($compile, templateSrv) {
|
||||
$paramLink.appendTo($paramsContainer);
|
||||
$input.appendTo($paramsContainer);
|
||||
|
||||
$input.blur(_.partial(inputBlur, index));
|
||||
$input.blur(_.partial(switchToLink, index));
|
||||
$input.keyup(inputKeyDown);
|
||||
$input.keypress(_.partial(inputKeyPress, index));
|
||||
$paramLink.click(_.partial(clickFuncParam, index));
|
||||
|
Loading…
Reference in New Issue
Block a user