/**
* @fileOverview jquery plugin, provides simple notification (with timeout and close button). jQuery UI themes compatible.
*
License MIT
*
Copyright 2012 Christos Pontikis http://pontikis.net
*
Project page http://pontikis.net/labs/jui_alert
*
Minified using Online YUI Compressor http://www.refresh-sf.com/yui/
* @version 2.0.0 (26 Jan 2013)
* @author Christos Pontikis http://pontikis.net
* @requires jquery (>=1.6), jquery-ui (>=1.8)
*/
"use strict";(function(d){var c="jui_alert";var a={init:function(e){var f=this;return this.each(function(){var j=f.data(c);if(typeof(j)=="undefined"){var k=f.jui_alert("getDefaults");j=d.extend({},k,e)}else{j=d.extend({},j,e)}f.data(c,j);var l=f.attr("id");var i;var g=b(j.close_btn_id_prefix,l);var o=b(j.timer_btn_id_prefix,l);var m="";f.removeClass().addClass(j.containerClass);m+='
";f.html(m);var p=d("#"+g);var n=d("#"+o);if(j.timeout>0){i=setTimeout(function(){p.click()},j.timeout)}p.click(function(){f.html("")});n.click(function(){d(this).removeClass(j.btnTimerOnClass).addClass(j.btnTimerOffClass);d(this).prop("title","");clearTimeout(i)});var h=["slide","bounce","shake","pulsate"];if(d.inArray(j.use_effect.effect_name,h)>-1){f.effect(j.use_effect.effect_name,j.use_effect.effect_options,j.use_effect.effect_duration)}})},getDefaults:function(){return{timeout:2500,containerClass:"ui-widget",buttonsAreaClass:"jui_alert_buttons_p",btnCloseClass:"jui_alert_btn_close ui-icon ui-icon-closethick",btnTimerOnClass:"jui_alert_btn_timer ui-icon ui-icon-pin-w",btnTimerOffClass:"jui_alert_btn_timer ui-icon ui-icon-pin-s",messageAreaClass:"jui_alert_message_area ui-state-highlight ui-corner-all",messageBodyClass:"jui_alert_message_body",messageIconClass:"jui_alert_icon ui-icon ui-icon-info",close_btn_id_prefix:"close_",timer_btn_id_prefix:"cancel_timer_",use_effect:""}},getOption:function(e){var f=this;return f.data(c)[e]},getAllOptions:function(){var e=this;return e.data(c)},setOption:function(e,h,g){var f=this;f.data(c)[e]=h;if(g){f.jui_alert("init")}},refresh:function(){var e=this;e.jui_alert()},destroy:function(){return d(this).each(function(){var e=d(this);e.removeData(c)})}};var b=function(f,e){return f+e};d.fn.jui_alert=function(f){if(this.size()!=1){var e="You must use this plugin ("+c+") with a unique element (at once)";this.html('ERROR: '+e+"");d.error(e)}if(a[f]){return a[f].apply(this,Array.prototype.slice.call(arguments,1))}else{if(typeof f==="object"||!f){return a.init.apply(this,arguments)}else{d.error("Method "+f+" does not exist on jQuery."+c)}}}})(jQuery);