STools

Class SProtectLayer

Object
   |
   +--SProtectLayer

class SProtectLayer

Version: 1.0

Author: deltapositive (deltapositive@yahoo.fr)
Defined in SProtectLayer.js

Requires:


Field Summary
 Object event
          
 
Constructor Summary
SProtectLayer ()
            SProtectLayer is part of the STools.

Copyright 2005 STools

Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at

http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.


SProtectLayer is a class that can create an invisible layer you can put over background stuffs.
While the protection layer is displayed, only foreground stuffs will be accessible.

Basic usage:
This class is usefull when you open a menu, and want to know when the user clic outsite the menu (to close it).
Idem for modal dialog boxes, that can blink when user clicks outside.
Idem for tips that will diseapears when user click outside.

Works with:
  • IE 6.0
  • Moz 1.7
  • FF 1.0

Limitations:
  • IE 6.0: 'Select' objects disapears when the layer is displayed.
 
Method Summary
 void hide()
           Hide the protection.
Fire the onhide event.
 void setEventListener(<string> event, <function> listener)
           Set a listener for an event.
 void setLevel(<int> level)
           Set the z index of the protection (default is 10).
Applyed only at show time.
 void setOpacity(<int> value)
           Dynamicaly change the opacity.
 void setStyle(<string> attribute, <string> value)
           Dynamicaly set a style attribute.
 void show()
           Display the protection.
Fires the onshow event.
When displayed the layer is resized.
The focus is given to the layer.

Field Detail

event

Object event

Constructor Detail

SProtectLayer

SProtectLayer()

Method Detail

hide

void hide()

setEventListener

void setEventListener(<string> event, <function> listener)

setLevel

void setLevel(<int> level)

setOpacity

void setOpacity(<int> value)

setStyle

void setStyle(<string> attribute, <string> value)

show

void show()

STools

- STools Copyright 2005 -




Documentation generated by JSDoc on Tue Jan 24 21:43:37 2006