widget-autohide-debug.js revision 897547688bb5907542df4114fc4a55979ad7ec12
daa301d2a0f17b5c1b04d777de3acf969b9b63d2Luke SmithWidgetAutohide = Y.Base.create(WIDGET_AUTOHIDE, Y.Plugin.Base, [], {
daa301d2a0f17b5c1b04d777de3acf969b9b63d2Luke Smith // *** Instance Members *** //
daa301d2a0f17b5c1b04d777de3acf969b9b63d2Luke Smith // *** Lifecycle Methods *** //
9533104fb7447a0765dc2aafec105c729d2c1be7Luke Smith destructor : function () {
9533104fb7447a0765dc2aafec105c729d2c1be7Luke Smith bindUI : function () {
9533104fb7447a0765dc2aafec105c729d2c1be7Luke Smith this.afterHostEvent(VISIBLE+CHANGE, this._afterHostVisibleChange);
9533104fb7447a0765dc2aafec105c729d2c1be7Luke Smith syncUI : function () {
9533104fb7447a0765dc2aafec105c729d2c1be7Luke Smith this._uiSetHostVisible(this.get(HOST).get(VISIBLE));
daa301d2a0f17b5c1b04d777de3acf969b9b63d2Luke Smith // *** Private Methods *** //
9533104fb7447a0765dc2aafec105c729d2c1be7Luke Smith //this._attachUIHandles();
9533104fb7447a0765dc2aafec105c729d2c1be7Luke Smith _attachUIHandles : function () {
9533104fb7447a0765dc2aafec105c729d2c1be7Luke Smith if (this._uiHandles) { return; }
9533104fb7447a0765dc2aafec105c729d2c1be7Luke Smith o = {node: undefined, ev: undefined, keyCode: undefined};
9533104fb7447a0765dc2aafec105c729d2c1be7Luke Smith //push all events on which the widget should be hidden
9563d8a01a40e508f7697d9c674c164512940371Luke Smith //no keycode or node defined
9563d8a01a40e508f7697d9c674c164512940371Luke Smith //node defined, no keycode (not a keypress)
9563d8a01a40e508f7697d9c674c164512940371Luke Smith //node defined, keycode defined, event defined (its a key press)
9563d8a01a40e508f7697d9c674c164512940371Luke Smith uiHandles.push(o.node.on(o.ev, hide, o.keyCode));
daa301d2a0f17b5c1b04d777de3acf969b9b63d2Luke Smith _detachUIHandles : function () {
daa301d2a0f17b5c1b04d777de3acf969b9b63d2Luke Smith // *** Static *** //
9533104fb7447a0765dc2aafec105c729d2c1be7Luke Smith}, '@VERSION@' ,{requires:['base-build', 'widget', 'plugin', 'gallery-outside-events']});