diff --git a/ChangeLog b/ChangeLog index d418da14d..e8345c598 100644 --- a/ChangeLog +++ b/ChangeLog @@ -15,6 +15,7 @@ $HeadURL: https://phpmyadmin.svn.sourceforge.net/svnroot/phpmyadmin/trunk/phpMyA - bug #2280904 [export] do not include view name in export - rfe #1688975 [display] enable copying of auto increment by default - bug #2355753 [core] do not bail out creating session on any PHP warning +- bug #2355925 [display] properly update tooltips in navigation frame 3.1.0.0 (2008-11-28) + [auth] Support for Swekey hardware authentication, diff --git a/index.php b/index.php index cb8947289..837e0ac0d 100644 --- a/index.php +++ b/index.php @@ -128,6 +128,8 @@ header('Content-Type: text/html; charset=' . $GLOBALS['charset']); var token = ''; var text_dir = ''; var pma_absolute_uri = ''; + var pma_text_default_tab = ''; + var pma_text_left_default_tab = ''; // for content and navigation frames diff --git a/js/common.js b/js/common.js index 770050a12..e1de64a54 100644 --- a/js/common.js +++ b/js/common.js @@ -439,9 +439,13 @@ function updateTableTitle( table_link_id, new_title ) { //alert('updateTableTitle'); if ( window.parent.frame_navigation.document.getElementById(table_link_id) ) { var left = window.parent.frame_navigation.document; - left.getElementById(table_link_id).title = new_title; - new_title = left.getElementById('icon_' + table_link_id).alt + ': ' + new_title; - left.getElementById('quick_' + table_link_id).title = new_title; + + var link = left.getElementById(table_link_id); + link.title = window.parent.pma_text_default_tab + ': ' + new_title; + + var link = left.getElementById('quick_' + table_link_id); + link.title = window.parent.pma_text_left_default_tab + ': ' + new_title; + return true; } diff --git a/libraries/common.lib.php b/libraries/common.lib.php index 12f189ed9..b38d0d69c 100644 --- a/libraries/common.lib.php +++ b/libraries/common.lib.php @@ -2662,4 +2662,35 @@ function PMA_duplicateFirstNewline($string){ return $string; } +/** + * get the action word corresponding to a script name + * in order to display it as a title in navigation panel + * + * @uses switch() + * @uses $GLOBALS + * @param string a valid value for $cfg['LeftDefaultTabTable'] + * or $cfg['DefaultTabTable'] + */ +function PMA_getTitleForTarget($target) { + switch ($target) { + case 'tbl_structure.php': + $message = 'strStructure'; + break; + case 'tbl_sql.php': + $message = 'strSQL'; + break; + case 'tbl_select.php': + $message = 'strSearch'; + break; + case 'tbl_change.php': + $message = 'strInsert'; + break; + case 'sql.php': + $message = 'strBrowse'; + break; + default: + $message = ''; + } + return $GLOBALS[$message]; +} ?> diff --git a/navigation.php b/navigation.php index 1dca52392..de6ada7f7 100644 --- a/navigation.php +++ b/navigation.php @@ -606,10 +606,11 @@ function PMA_displayTableList($tables, $visible = false, } echo '' . "\n"; } elseif (is_array($table)) { + $link_title = PMA_getTitleForTarget($GLOBALS['cfg']['LeftDefaultTabTable']); // quick access icon next to each table name echo '
  • ' . "\n"; echo '' . "\n"; + .' width="10" height="10" alt="' . htmlspecialchars($link_title) . '" />' . "\n"; // link for the table name itself $href = $GLOBALS['cfg']['DefaultTabTable'] . '?' @@ -643,38 +644,6 @@ function PMA_displayTableList($tables, $visible = false, echo ''; } -/** - * get the action word corresponding to a script name - * in order to display it as a title in navigation panel - * - * @uses switch() - * @uses $GLOBALS - * @param string a valid value for $cfg['LeftDefaultTabTable'] - * or $cfg['DefaultTabTable'] - */ -function PMA_getTitleForTarget($target) { - switch ($target) { - case 'tbl_structure.php': - $message = 'strStructure'; - break; - case 'tbl_sql.php': - $message = 'strSQL'; - break; - case 'tbl_select.php': - $message = 'strSearch'; - break; - case 'tbl_change.php': - $message = 'strInsert'; - break; - case 'sql.php': - $message = 'strBrowse'; - break; - default: - $message = ''; - } - return $GLOBALS[$message]; -} - echo '' . "\n"; PMA_exitNavigationFrame();