The branch, master has been updated via c27663917fadccbfb7f7613e5e95c8e0f30f5d3d (commit) via e049a44f5964ea4fbc6f447ab2808964b03c268d (commit) via 829a7d81469c64d7b01260738698f0a76b553493 (commit) via 0098927245c72015bd2f504147b9dfee250c6762 (commit) via 111ba5d79f95575dddc4178f7d9fc63321094406 (commit) via 4b79515d00f1cfe57cf92f2b6311f6644cced7e8 (commit) via 6f602b6777455a596f7bdd91511feefd4e5eab4a (commit) via 686f330dc9e07910db506d6472d9b162811b1c38 (commit) from 0805f5701eef84538f06d69a7802c6c2d9f4d7c6 (commit)
- Log ----------------------------------------------------------------- commit c27663917fadccbfb7f7613e5e95c8e0f30f5d3d Author: Michal Čihař mcihar@novell.com Date: Fri Apr 2 13:34:27 2010 +0200
Do not try to play with parent if there is none.
commit e049a44f5964ea4fbc6f447ab2808964b03c268d Author: Michal Čihař mcihar@novell.com Date: Fri Apr 2 13:33:12 2010 +0200
Move input event binding to separate js file.
commit 829a7d81469c64d7b01260738698f0a76b553493 Author: Michal Čihař mcihar@novell.com Date: Fri Apr 2 13:30:01 2010 +0200
Bind clear event in javascript.
commit 0098927245c72015bd2f504147b9dfee250c6762 Author: Michal Čihař mcihar@novell.com Date: Fri Apr 2 13:24:17 2010 +0200
Move inline CSS to themes.
commit 111ba5d79f95575dddc4178f7d9fc63321094406 Author: Michal Čihař mcihar@novell.com Date: Fri Apr 2 13:20:44 2010 +0200
Adjust CSS to display clear button over the input.
commit 4b79515d00f1cfe57cf92f2b6311f6644cced7e8 Author: Michal Čihař mcihar@novell.com Date: Fri Apr 2 13:14:45 2010 +0200
Separate function for clearing input.
commit 6f602b6777455a596f7bdd91511feefd4e5eab4a Author: Michal Čihař mcihar@novell.com Date: Fri Apr 2 13:09:36 2010 +0200
Move unhiding code to js file.
commit 686f330dc9e07910db506d6472d9b162811b1c38 Author: Michal Čihař mcihar@novell.com Date: Fri Apr 2 13:05:24 2010 +0200
Wrap code a bit to make it more readable.
No functional changes.
-----------------------------------------------------------------------
Summary of changes: js/navigation.js | 23 +++++++++++++++++++++-- navigation.php | 7 ++++++- themes/darkblue_orange/css/theme_right.css.php | 19 +++++++++++++++++++ themes/original/css/theme_left.css.php | 18 ++++++++++++++++++ 4 files changed, 64 insertions(+), 3 deletions(-)
diff --git a/js/navigation.js b/js/navigation.js index 1e038ab..2932105 100644 --- a/js/navigation.js +++ b/js/navigation.js @@ -88,7 +88,7 @@ function PMA_setFrameSize() { pma_navi_width = PMA_getCookie('pma_navi_width'); //alert('from cookie: ' + typeof(pma_navi_width) + ' : ' + pma_navi_width); - if (pma_navi_width != null) { + if (pma_navi_width != null && parent.document != document) { if (parent.text_dir == 'ltr') { parent.document.getElementById('mainFrameset').cols = pma_navi_width + ',*'; } else { @@ -171,4 +171,23 @@ function fast_filter(value){ } } document.getElementById('fast_filter').disabled=false; -} \ No newline at end of file +} + +/** + * 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 */ + jQuery('#NavFilter').css('display', 'inline'); + jQuery('#clear_fast_filter').click(clear_fast_filter); + jQuery('#fast_filter').focus(function (evt) {evt.target.select();}); + jQuery('#fast_filter').keyup(function (evt) {fast_filter(evt.target.value);}); +}); diff --git a/navigation.php b/navigation.php index 82f7f95..5f544e7 100644 --- a/navigation.php +++ b/navigation.php @@ -315,7 +315,12 @@ if ($GLOBALS['cfg']['LeftFrameLight'] && strlen($GLOBALS['db'])) { } echo '</a></p>'; if ($table_count) { - echo '<span id='NavFilter' style="display:none;"><span onclick="document.getElementById(\'fast_filter\').value=\'\'; fast_filter(\'\');document.getElementById(\'fast_filter\').focus();" style="background:white;color:black;cursor:pointer;padding:2px;margin:0 0 0 -20px;position:relative;float:right;" title="' . $strReset . '">X</span><input type="text" name="fast_filter" id="fast_filter" title="' . $strNavTableFilter . '" onkeyup="setTimeout(function(word){ return function(){ fast_filter(word);}}(this.value),1000);" style="width:90%;padding:0 -20px 0 0; padding:2px;" onfocus="this.select();" /></span><script type="text/javascript">document.getElementById('NavFilter').style.display='';</script>'; + ?> + <span id="NavFilter"> + <input type="text" name="fast_filter" id="fast_filter" title="<?php echo $strNavTableFilter; ?>" /> + <span id="clear_fast_filter" title="<?php echo $strReset; ?>">X</span> + </span> + <?php }
/** diff --git a/themes/darkblue_orange/css/theme_right.css.php b/themes/darkblue_orange/css/theme_right.css.php index 72420e3..0a59056 100644 --- a/themes/darkblue_orange/css/theme_right.css.php +++ b/themes/darkblue_orange/css/theme_right.css.php @@ -1265,3 +1265,22 @@ table#serverconnection_src_local, table#serverconnection_trg_local { float:left; } + +#NavFilter { + display: none; +} + +#clear_fast_filter { + background: white; + color: black; + cursor: pointer; + padding: 0; + margin: 0; + position: relative; + right: 3ex; +} + +#fast_filter { + width: 90%; + padding: 0.1em; +} diff --git a/themes/original/css/theme_left.css.php b/themes/original/css/theme_left.css.php index 2ffd388..ab794f5 100644 --- a/themes/original/css/theme_left.css.php +++ b/themes/original/css/theme_left.css.php @@ -232,3 +232,21 @@ div#left_tableList ul ul { padding: 1em; }
+#NavFilter { + display: none; +} + +#clear_fast_filter { + background: white; + color: black; + cursor: pointer; + padding: 0; + margin: 0; + position: relative; + right: 3ex; +} + +#fast_filter { + width: 90%; + padding: 0.1em; +}
hooks/post-receive