| This file defines the host object. |
| |
| Creates instances from constructor. |
| General init function for host.js. |
| host.conf conveniently stores variables that are subject to change |
| |
| {boolean} when true, the cookie-based exception reporting system is active. |
| container for server paths |
| |
| {String} relative path to directory on server containing constructors |
| container for date formats used with lib_nerveDate and lib_nerveDateUTC |
| |
| {String} default date mask in the format “1/1/2001 01:01 PM” |
| host.kernel contains most services not related to managing the gui |
| functions for interacting with the server |
| |
| |
| |
| |
| |
| {HTMLDiv} reference to HTML DIV used by modalShield system. |
| starts a server-push persistent connection. |
| functions for getting, setting, deleting, and counting cookies |
| |
| |
| creates cookie by name, or updates cookie if one already exists by passed name |
| |
| |
| collection of various utilities, some of these may not be useful in enough cases to justfy being in here. |
| |
| determines if DOM element has a parent |
| determines an element’s top and left values relative to the window object. |
| determines inner width of window object. |
| determines inner height of window object. |
| reads a style rule from the currently loaded style sheet(s) |
| for the element passed, determines the value of a style property as determined in the style sheet, not the current DOM |
| creates array of keys in a JS Object object |
| returns the position of an element within an array. |
| convenience method to delete an element from an array. |
| convenience method to get last element from an array. |
| convenience method to get first element from an array. |
| finds position of element matching passed value and returns the value of the next element, wraps around end of array if val matches last element |
| finds position of element matching passed value and returns the value of the previous element, wraps around beginning of array if val matches element 0 |
| appends a new HTML attribute to a DOM element |
| empties a DOM element of all children |
| This function allows the programmer to inject new lines of code into any function at runtime. |
| creates Document Object from XML string |
| some random math functions |
| |
| determines if a point is contained within a bounding box. |
| creates a random integer between defined min and max values |
| functions for working with URI strings |
| |
| returns current document URI’s search string as hash of name/value pairs. |
| searches current document URI’s search string for value matching specified name |
| assembles a URI string from passed values. |
| assembles a parameters for HTTP POST. |
| functions for “path” strings used by viewer_folderTree constructor. |
| |
| returns the number of nodes in a path |
| returns the last node string or “node name” of this path. |
| |
| browser detection functions. |
| |
| performs browser detection |
| JSON serialize/deserialize functions |
| |
| |
| converts JS object into JSON string. |
| exception-handling functions |
| |
| general exception-handling function. |
| writes formatted error object into cookie so the server can collect and clear it later. |
| displays all arguments in a nicely formatted text box, good for debugging. |
| container for constructors |
| |
| Creates an HTML table with built-in references to all internal cells and rows. |
| Creates an Image object and applies a src property. |
| container for all things GUI |
| |
| {DOMElement} reference to the whole document BODY |
| {DOMElement} reference to the whole document HEAD |
| |
| placeholder method, it is expected that this is occluded in the application. |
| loads the specified stylesheet and applies its rules to gui.canvas. |
| container for GUI state system. |
| |
| {Object} contains all local state data |
| |
| sets one of an element’s state properties to a value. |
| gets the value of one of an element’s state properties. |
| Fetches all state data and copies into state_o. |
| sets the value of one of an element’s state property to “” in state_o and on the server. |
| Container for event router and event-handling methods |
| |
| Binds a context menu to a DOM element via the mousedown event. |
| Appends an event listener to a DOM elemnent |
| Removes an event listener from a DOM elemnent |
| Returns the target of an event |
| Returns the target of an event |
| stops propagation of event object |
| Container for key-event-handling methods |
| |
| Starts key capture, routing events to listen |
| |
| Central key-handling function. |
| Stops propagation and prevents default action of an event. |
| Container for mouse-event-handling methods |
| |
| This method is called whenever any mouse click occurs. |
| This method returns a string [“left”|”right”] depending on which mouse button was pressed. |
| Disables the browser’s native context menu for a specific DOM element, can be applied to the whole document body. |
| Binds a context menu to a DOM element via the mousedown event. |
| binds and object to the drag/drop system and its own internal drag/drop behaviors Each bound object’s dragDropHandler handles the specifics of drag-and-drop behavior |
| initiates the drag/drop process, calls the target object’s own grab function |
| middle of the drag/drop process, calls the target object’s own trackMouse function |
| ends the drag/drop process, calls the target object’s own ungrab function |
| Container for methods and properties to handle focus, open, and close of custom context menus |
| |
| {Object} Reference to currently focused menu. |
| |
| activates the current context menu |
| deactivates the current context menu |
| Container for context system. |
| |
| {Array} Array of references to panels with context. |
| {DOMElement} reference to the panel with current persistent focus. |
| {DOMElement} reference to the panel with current momentary focus. |
| |
| returns reference to the panel that currently has context. |
| Points current context (momentary or persistent) to a panel. |
| “tabs through” panels, pointing current persistent context to current panel. |
| Provides a good global place to store references to images |
| Provides a good global place to store reference to root panelSet |
| Provides a good global place to store references to dialog boxes |
| Provides a good global place to store references to popups windows |
| Closer is the system which closes all open menus, contextMenus, floaters, etc. |
| |
| responds to mouse action by closing all open menus, contextMenus, floaters, etc. |
| The modalShield is an event-capturing div with a z-index between the canvas and a modal dialog. |
| |
| {HTMLDiv} reference to HTML DIV used by modalShield system. |
| {boolean} tracks whether is modalShield.div is attached to the DOM |
| |
| creates modalShield.div, should be called at init of app. |
| Makes the modalShield active. |
| Makes the modalShield inactive. |