// Articles. Tutorials. Utilities.
Home  |   Search  |   Login  
Categories Skip Navigation Links
New / All
Google / Android
Python / IronPython
SQL Server
AJAX Source Viewer
Slideshow of method source in a particular class. Choose a class from the Namespaces, Classes, or Methods menu item above.
Slideshow for Class 'DomElement'
Previous Method:


Current Method:

Next Method:

Method '_ensureOldDisplayMode(element)'
Method: _ensureOldDisplayMode(element)
Method Full Name:     Sys$UI$DomElement$_ensureOldDisplayMode(element)
Class: DomElement
Namespace: Sys.UI
Source File: MicrosoftAjax.debug.js
1   Sys.UI.DomElement._ensureOldDisplayMode = function Sys$UI$DomElement$_ensureOldDisplayMode(element) {
2     if (!element._oldDisplayMode) {
3       var style = element.currentStyle || Sys.UI.DomElement._getCurrentStyle(element);
4       element._oldDisplayMode = style ? style.display : null;
5       if (!element._oldDisplayMode || element._oldDisplayMode === 'none') {
6         switch(element.tagName.toUpperCase()) {
7           case 'DIV': case 'P': case 'ADDRESS': case 'BLOCKQUOTE': case 'BODY': case 'COL':
8           case 'COLGROUP': case 'DD': case 'DL': case 'DT': case 'FIELDSET': case 'FORM':
9           case 'H1': case 'H2': case 'H3': case 'H4': case 'H5': case 'H6': case 'HR':
10          case 'IFRAME': case 'LEGEND': case 'OL': case 'PRE': case 'TABLE': case 'TD':
11          case 'TH': case 'TR': case 'UL':
12            element._oldDisplayMode = 'block';
13            break;
14          case 'LI':
15            element._oldDisplayMode = 'list-item';
16            break;
17          default:
18            element._oldDisplayMode = 'inline';
19          }
20        }
21      }
22    }
This is the JavaScript source for method _ensureOldDisplayMode(element) from ASP.NET AJAX Library. Full name for this method is Sys$UI$DomElement$_ensureOldDisplayMode(element). It belongs to the class DomElement, which is in Sys.UI namespace. This source is in MicrosoftAjax.debug.js file.
Bookmark and Share This
About  Contact  Privacy Policy  Site Map