From 4b79515d00f1cfe57cf92f2b6311f6644cced7e8 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Michal=20=C4=8Ciha=C5=99?= Date: Fri, 2 Apr 2010 13:14:45 +0200 Subject: [PATCH] Separate function for clearing input. --- js/navigation.js | 10 ++++++++++ navigation.php | 2 +- 2 files changed, 11 insertions(+), 1 deletion(-) diff --git a/js/navigation.js b/js/navigation.js index e02ccdc8b..113f16944 100644 --- a/js/navigation.js +++ b/js/navigation.js @@ -173,6 +173,16 @@ function fast_filter(value){ document.getElementById('fast_filter').disabled=false; } +/** + * Clears fast filter. + */ +function clear_fast_filter() { + var elm = jQuery('#NavFilter input'); + elm.val(''); + fast_filter(''); + elm.focus(); +} + /* Performed on load */ jQuery(document).ready(function(){ /* Display filter */ diff --git a/navigation.php b/navigation.php index 8516cb032..099bb8796 100644 --- a/navigation.php +++ b/navigation.php @@ -318,7 +318,7 @@ if ($GLOBALS['cfg']['LeftFrameLight'] && strlen($GLOBALS['db'])) { ?>