[Phpmyadmin-git] [SCM] phpMyAdmin branch, master, updated. RELEASE_3_4_2-4162-g1be932c
Marc Delisle
lem9 at users.sourceforge.net
Sun Jun 19 14:11:18 CEST 2011
The branch, master has been updated
via 1be932c707eaac963afb1f6ea4db77a527b20926 (commit)
via e34e0e1f860b951c591bb08908c18838d512b69b (commit)
from 29bb225b920f4fbdc9977bcc795ae8f8e5c83a7b (commit)
- Log -----------------------------------------------------------------
commit 1be932c707eaac963afb1f6ea4db77a527b20926
Merge: 29bb225b920f4fbdc9977bcc795ae8f8e5c83a7b e34e0e1f860b951c591bb08908c18838d512b69b
Author: Marc Delisle <marc at infomarc.info>
Date: Sun Jun 19 08:09:12 2011 -0400
Merge commit 'e34e0e1f860b951c591bb08908c18838d512b69b'
commit e34e0e1f860b951c591bb08908c18838d512b69b
Author: Aris Feryanto <aris_feryanto at yahoo.com>
Date: Sat Jun 18 21:19:33 2011 +0700
Fix bug: (1) Disable column reordering for EXPLAIN and SHOW syntax, (2) Show mark tooltip only when column is markable
-----------------------------------------------------------------------
Summary of changes:
js/makegrid.js | 38 ++++++++++++++++++++++----------------
1 files changed, 22 insertions(+), 16 deletions(-)
diff --git a/js/makegrid.js b/js/makegrid.js
index 038300b..80a62ad 100644
--- a/js/makegrid.js
+++ b/js/makegrid.js
@@ -347,14 +347,16 @@
showHint: function(e) {
if (!this.colRsz && !this.colMov) { // if not resizing or dragging
var text = '';
- if (this.showReorderHint) {
+ if (this.showReorderHint && this.reorderHint) {
text += this.reorderHint;
}
- if (this.showSortHint) {
+ if (this.showSortHint && this.sortHint) {
text += text.length > 0 ? '<br />' : '';
text += this.sortHint;
}
- if (this.showMarkHint) {
+ if (this.showMarkHint && this.markHint &&
+ !this.showSortHint // we do not show mark hint, when sort hint is shown
+ ) {
text += text.length > 0 ? '<br />' : '';
text += this.markHint;
}
@@ -456,9 +458,6 @@
g.sortHint = $('#sort_hint').val();
g.markHint = $('#col_mark_hint').val();
- // determine whether to show the column reordering hint or not
- g.showReorderHint = $firstRowCols.length > 1;
-
// initialize column order
$col_order = $('#col_order');
if ($col_order.length > 0) {
@@ -491,32 +490,39 @@
.wrapInner('<span />');
// register events
- if ($firstRowCols.length > 1) {
+ if ($firstRowCols.length > 1 && g.reorderHint) { // make sure columns is reorderable
$(t).find('th.draggable')
.css('cursor', 'move')
.mousedown(function(e) {
g.dragStartMove(e, this);
+ })
+ .mouseenter(function(e) {
+ g.showReorderHint = true;
+ g.showHint(e);
+ })
+ .mouseleave(function(e) {
+ g.showReorderHint = false;
+ g.showHint(e);
});
}
- $(t).find('th.draggable')
- .mouseenter(function(e) {
- g.showMarkHint = !g.showSortHint;
- g.showHint(e);
- })
- .mouseleave(function(e) {
- g.hideHint();
- });
$(t).find('th.draggable a')
.attr('title', '') // hide default tooltip for sorting
.mouseenter(function(e) {
g.showSortHint = true;
- g.showMarkHint = false;
g.showHint(e);
})
.mouseleave(function(e) {
g.showSortHint = false;
+ g.showHint(e);
+ });
+ $(t).find('th.marker')
+ .mouseenter(function(e) {
g.showMarkHint = true;
g.showHint(e);
+ })
+ .mouseleave(function(e) {
+ g.showMarkHint = false;
+ g.showHint(e);
});
$(document).mousemove(function(e) {
g.dragMove(e);
hooks/post-receive
--
phpMyAdmin
More information about the Git
mailing list