From 5aec190c3f7e1407f3c29d53c820fb8d51e156f3 Mon Sep 17 00:00:00 2001 From: Rudy Lu Date: Thu, 12 Jun 2014 20:08:01 +0800 Subject: [PATCH] Bug 1013739 - [Dolphin][Flame][FFOS 1.4]Long touch the build-in keyboard and income a call or alarm,the key touching is invalid. - Reset the state when the keyboard is hidden. --- apps/keyboard/js/keyboard.js | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/apps/keyboard/js/keyboard.js b/apps/keyboard/js/keyboard.js index 2b85978ae656..2aab72e87b8d 100644 --- a/apps/keyboard/js/keyboard.js +++ b/apps/keyboard/js/keyboard.js @@ -1742,6 +1742,8 @@ function hideKeyboard() { navigator.mozSettings.createLock().set({ 'keyboard.current': undefined }); + + clearTouchedKeys(); } // Resize event handler @@ -1972,6 +1974,11 @@ function clearTouchedKeys() { hideAlternatives(); touchedKeys = {}; + + // Reset all the pending actions here. + clearTimeout(deleteTimeout); + clearInterval(deleteInterval); + clearTimeout(menuTimeout); } /* * This is a helper to scroll the keyboard layout menu when the touch moves near