[open-ils-commits] r12070 - trunk/Open-ILS/web/js/dojo/openils/widget
svn at svn.open-ils.org
svn at svn.open-ils.org
Wed Feb 4 17:50:27 EST 2009
Author: erickson
Date: 2009-02-04 17:50:23 -0500 (Wed, 04 Feb 2009)
New Revision: 12070
Modified:
trunk/Open-ILS/web/js/dojo/openils/widget/AutoGrid.js
Log:
when using the popup dialog, overide the default focus handling. this is still experimental
Modified: trunk/Open-ILS/web/js/dojo/openils/widget/AutoGrid.js
===================================================================
--- trunk/Open-ILS/web/js/dojo/openils/widget/AutoGrid.js 2009-02-04 21:49:06 UTC (rev 12069)
+++ trunk/Open-ILS/web/js/dojo/openils/widget/AutoGrid.js 2009-02-04 22:50:23 UTC (rev 12070)
@@ -39,19 +39,24 @@
/* capture keydown and launch edit dialog on enter */
_applyEditOnEnter : function() {
this.onMouseOverRow = function(e) {};
- this.onMouseOut = function(e) {};
+ this.onMouseOutRow = function(e) {};
+ this.onCellFocus = function(cell, rowIndex) {
+ openils.Util.addCSSClass(
+ cell.getNode(rowIndex).parentNode,
+ 'oils-grid-row-selected');
+ }
dojo.connect(this, 'onKeyDown',
function(e) {
if(e.keyCode == dojo.keys.ENTER) {
this.selection.deselectAll();
this.selection.select(this.focus.rowIndex);
- this._drawEditDialog(this.selection.getFirstSelected());
+ this._drawEditDialog(this.selection.getFirstSelected(), this.focus.rowIndex);
}
}
);
},
- _drawEditDialog : function(storeItem) {
+ _drawEditDialog : function(storeItem, rowIndex) {
var grid = this;
var fmObject = new fieldmapper[this.fmClass]().fromStoreItem(storeItem);
var idents = grid.store.getIdentityAttributes();
More information about the open-ils-commits
mailing list