// Copyright 2007 by Developer Utility
// Please see http://www.developerutility.com/Terms.htm for terms of use.

////////////////////////////////////////////////////////////////////////////////////////////////////////
// NB : All setting are made for North America Standard, meaning US, FR-Canada and EN-Canada Keyboard //
//      For other language/country, we suggest to consult our online FAQ for easier implementation    //
////////////////////////////////////////////////////////////////////////////////////////////////////////

// Domain name here
var domainName1A3C8G9YEWQIKL = "localhost"; // localhost, www.developerutility.com

// This is the message text the user receive if he try to change the cell focus
// inside the grid while already editing another one
// (if you set the message length to zero, no message will be display)
var msgCellEdition = "      You have to finish the current cell edition\n" + 
                     "     (by pressing the 'enter' key on your keyboard)\n" + 
                     "           before moving to another element.";

// The possible name of a boolean value set to true in your database and return inside a node of the xml body
// (this is for the column type="checkbox" inside your xml head)
// All checkbox type boolean value are converted to "1" or "0" inside the Grid object and filter
var arrSqlBoolean = new Array("true", "1", "vrai");

// For monitoring change inside the grid, sql boolean true/false or null will be converted to those value
// (this is for the column type="checkbox" inside your xml head)
var sqlBooleanTrue = 1;  // boolean true
var sqlBooleanFalse = 0; // boolean false or null

// The xpath query of your head and body inside your xml grid document
var xPathQueryHead = "Dataset/Head";
var xPathQueryBody = "Dataset/Body";

// These are the special keyboard input data entry the grid object need to convert in xml format
// Both array need to be of equat length 
// (see full list of special caracter http://www.ramsch.org/martin/uni/fmi-hp/iso8859-1.html)
var specialCharacterInput = new Array("&", "<", ">");
var specialCharacterInputXml = new Array("&amp;", "&lt;", "&gt;");

// Color and gap distance of shade in the grid body (to cancel shading, just set the rowShadeGap to 9999)
var rowShadeGap = 2;
var rowShadeColor = "#E2E2E2";

// Option for building the "page X of Y" at the bottom of the table (google style)
var rowPerPage = 8; // number of row display on the user screen
var maxPage = 15;   // number of page X of Y display on the user screen

// Special keyboard key use inside the grid monitoring
var keepCellContentKey = 113; // Keep cell content before it's edition (like Excel), event.keyCode "F2" on US keyboard
var undoCellContentKey = 27;  // Cancel the cell edition (like Excel), event.keyCode "ESC" on US keyboard
var enterKey = 13;            // Stop cell edition, event.keyCode "ENTER" on US keyboard

var arrowUp = 38;             // Move grid selected cell one position up (to cancel this functionnality, just set this value to 9999)
var arrowDown = 40;           // Move grid selected cell one position down (to cancel this functionnality, just set this value to 9999)
var arrowLeft = 37;           // Move grid selected cell one position left (to cancel this functionnality, just set this value to 9999)
var arrowRight = 39;          // Move grid selected cell one position right (to cancel this functionnality, just set this value to 9999)

// Filter DOM node property
var filterTemplateID = "filter";         // Default filter template ID in your DOM (<DIV id="filter" ...>)
var filterMatchCaseNumber = 3;           // Number of match case display in the filter
var filterMatchCaseWidth = "170px";      // Length of the drop down menu in the filter displaying the column name
var filterColumnDisplayNumber = 3;       // Number of columns per row in the filter display/hide
var filterValidateInputOnKeyDown = true; // Validate user value keyboard input while typing 
                                         // (see function ValidateInputAfterChange in JsGridEvent.js)

// Resize column property
var resizeTolerance = 10;            // Change the tolerance width of the column resize cursor display
                                     // on each column right edge
var resizeCursorIcon = "col-resize"; // Cursor icon display on the column right edge

// This variable is only for demo purpose, 
// it increment a simple counter for new(s) 
// row(s) key(s) field(s) value(s)
var keyFieldCounter = 1000;
