/**
 * 功能搜索
 */
EBOS.search = (function(){
	return {
		init : function(){
			$('body').append('<div id="div_for_search"></div>');
			$('#div_for_search').html('<iframe class="frame" src="../plugins/app/search.jsp"/>');
			$('#div_for_search').hide();
			$('.indicator_search').on('mousedown', function(){
				return false;
			}).on('click',function(e){
				//根据点击位置，确定搜索框弹出位置
				var l =  e.clientX;
				var t =  e.clientY;
				
				if($('#div_for_search').is(":hidden")){
					$('#div_for_search').css({
						left : l,
						top : t}).show();
				}else{
					$('#div_for_search').hide();
				}
			});
		}
	}
})();