only do kepress on outside of page for dtmf

This commit is contained in:
Anthony Minessale 2014-07-24 23:43:05 +05:00
parent acffa7961b
commit bd804df7a3
1 changed files with 2 additions and 1 deletions

View File

@ -430,10 +430,11 @@ function init() {
});
$(document).keypress(function(event) {
if (!cur_call) return;
if (!(cur_call && event.target.id == "page-incall")) return;
var key = String.fromCharCode(event.keyCode);
var i = parseInt(key);
if (key === "#" || key === "*" || key === "0" || (i > 0 && i <= 9)) {
cur_call.dtmf(key);
}