Module: UWA/Drivers/Prototype

UWA/Drivers/Prototype

This module declare/extends UWA to use Prototype Framework on UWA core functions.

Index

Members

<static> UWA.driver :String

The current driver name (e.g "Prototype").

Type
  • String

Methods

<static> UWA.extendElement(element) → {Element}

Extent a DOM Element with UWA.Element methods.

Example
var el = UWA.extendElement(document.getElementById('myElementId'));
Parameters
Name Type Description
element Element

The Element to extend

Returns

the extended Element.

Type
Element

<static> UWA.createElement(tagName, options) → {Element}

Create a DOM Element with UWA.Element methods.

Example
var myElement = UWA.createElement('a', {
   'class': 'myClass1 myClass2',
   html: 'Hello World',
   styles: {
     ...
   },
   events: {
       click: function(event) {
           UWA.Event.stop(event);
           ...
       }
   }
});
Parameters
Name Type Description
tagName String

The element tag name (eg: 'div')

options Object

Element attributes and options

Returns

The new Element.

Type
Element