1
Help for ParamQuery Grid (free version) / Why row focus(dotted box) missed?
« on: November 14, 2014, 02:42:06 pm »
keyboard left, right key -> horizonScroll Control
i customized pqgrid PRO...
_pKeyNav._bodyKeyPressDown = function(evt) {
....
if (evt.keyCode == keyCodes.LEFT) {
var decr = 0;
if (SM.type == "row" && $(that.$hscroll)[0].style.display != 'none') {
$(that.$hscroll).children('.left-btn').trigger('click');
decr = 1;
}
var obj = this._decrIndx(rowIndxPage, colIndx);
if (obj) {
rowIndx = obj.rowIndxPage + offset + decr;
this.select({
rowIndx: rowIndx,
colIndx: obj.colIndx,
evt: evt
})
}
evt.preventDefault();
return
} else {
if (evt.keyCode == keyCodes.RIGHT) {
var incr = 0;
if (SM.type == "row" && $(that.$hscroll)[0].style.display != 'none') {
$(that.$hscroll).children('.right-btn').trigger('click');
incr = -1;
}
var obj = this._incrIndx(rowIndxPage, colIndx);
if (obj) {
rowIndx = obj.rowIndxPage + offset + incr;
this.select({
rowIndx: rowIndx,
colIndx: obj.colIndx,
evt: evt
})
}
evt.preventDefault();
return
} else {
.....
}
......
keyboard left, right key -> horizonScroll Control very Well.
but, row focus(dotted box) missed.... T.T
i customized pqgrid PRO...
_pKeyNav._bodyKeyPressDown = function(evt) {
....
if (evt.keyCode == keyCodes.LEFT) {
var decr = 0;
if (SM.type == "row" && $(that.$hscroll)[0].style.display != 'none') {
$(that.$hscroll).children('.left-btn').trigger('click');
decr = 1;
}
var obj = this._decrIndx(rowIndxPage, colIndx);
if (obj) {
rowIndx = obj.rowIndxPage + offset + decr;
this.select({
rowIndx: rowIndx,
colIndx: obj.colIndx,
evt: evt
})
}
evt.preventDefault();
return
} else {
if (evt.keyCode == keyCodes.RIGHT) {
var incr = 0;
if (SM.type == "row" && $(that.$hscroll)[0].style.display != 'none') {
$(that.$hscroll).children('.right-btn').trigger('click');
incr = -1;
}
var obj = this._incrIndx(rowIndxPage, colIndx);
if (obj) {
rowIndx = obj.rowIndxPage + offset + incr;
this.select({
rowIndx: rowIndx,
colIndx: obj.colIndx,
evt: evt
})
}
evt.preventDefault();
return
} else {
.....
}
......
keyboard left, right key -> horizonScroll Control very Well.
but, row focus(dotted box) missed.... T.T