The branch, master has been updated via 13b7e75428c88e9c0b43ec613445243124d81662 (commit) from a4bb5d3e32f24396e7c1e7f6df1125e7c0423bfc (commit)
- Log ----------------------------------------------------------------- commit 13b7e75428c88e9c0b43ec613445243124d81662 Author: Marc Delisle marc@infomarc.info Date: Mon Sep 13 12:48:05 2010 -0400
bug #3064963 tabindex wrong for generated inserted rows
-----------------------------------------------------------------------
Summary of changes: js/tbl_change.js | 14 ++++++++++++++ tbl_change.php | 8 ++++---- 2 files changed, 18 insertions(+), 4 deletions(-)
diff --git a/js/tbl_change.js b/js/tbl_change.js index 52d8432..f9c2d43 100644 --- a/js/tbl_change.js +++ b/js/tbl_change.js @@ -424,6 +424,20 @@ $(document).ready(function() { } curr_rows++; } + // recompute tabindex for text fields and other controls at footer; + // IMO it's not really important to handle the tabindex for + // function and Null + var tabindex = 0; + $('.textfield') + .each(function() { + tabindex++; + $(this).attr('tabindex', tabindex); + }); + $('.control_at_footer') + .each(function() { + tabindex++; + $(this).attr('tabindex', tabindex); + }); } else if( curr_rows > target_rows) { while(curr_rows > target_rows) { diff --git a/tbl_change.php b/tbl_change.php index 3e4d814..54e0d7f 100644 --- a/tbl_change.php +++ b/tbl_change.php @@ -497,7 +497,7 @@ foreach ($rows as $row_id => $vrow) { }
$idindex = ($o_rows * $fields_cnt) + $i + 1; - $tabindex = (($idindex - 1) * 3) + 1; + $tabindex = $idindex;
// The function column // ------------------- @@ -1019,7 +1019,7 @@ $(function() { <table border="0" cellpadding="5" cellspacing="0"> <tr> <td valign="middle" nowrap="nowrap"> - <select name="submit_type" tabindex="<?php echo ($tabindex + $tabindex_for_value + 1); ?>"> + <select name="submit_type" class="control_at_footer" tabindex="<?php echo ($tabindex + $tabindex_for_value + 1); ?>"> <?php if (isset($where_clause)) { ?> @@ -1071,8 +1071,8 @@ if (isset($where_clause)) { <?php echo PMA_showHint(__('Use TAB key to move from value to value, or CTRL+arrows to move anywhere')); ?> </td> <td colspan="3" align="right" valign="middle"> - <input type="submit" value="<?php echo __('Go'); ?>" tabindex="<?php echo ($tabindex + $tabindex_for_value + 6); ?>" id="buttonYes" /> - <input type="reset" value="<?php echo __('Reset'); ?>" tabindex="<?php echo ($tabindex + $tabindex_for_value + 7); ?>" /> + <input type="submit" class="control_at_footer" value="<?php echo __('Go'); ?>" tabindex="<?php echo ($tabindex + $tabindex_for_value + 6); ?>" id="buttonYes" /> + <input type="reset" class="control_at_footer" value="<?php echo __('Reset'); ?>" tabindex="<?php echo ($tabindex + $tabindex_for_value + 7); ?>" /> </td> </tr> </table>
hooks/post-receive