(function(){
    window.o = {};
})();

(function(win, doc){
    var Search = function(){
        this.wrap = doc.getElementById('j-searchBox');
        this.openBtn = doc.getElementById('j-nav-searchBtn');
        this.closeBtn = doc.getElementById('j-search-closeBtn');

        this.bindEvent();
    };

    Search.prototype.bindEvent = function(){
        if(this.wrap.style.display === 'none') {
            return;
        }

        var self = this;
        var openBtn = this.openBtn;
        var closeBtn = this.closeBtn;

        if(doc.addEventListener){
            openBtn.addEventListener('click', function(){
                self.show();
            }, false);
            closeBtn.addEventListener('click', function(){
                self.hide();
            }, false);
        } else {
            openBtn.attachEvent('click', function(){
                self.show();
            });
            closeBtn.attachEvent('click', function(){
                self.hide();
            });
        }
    };

    Search.prototype.show = function(){
        this.wrap.className += (' ' + 'is-show');
    };

    Search.prototype.hide = function(){
        var className = this.wrap.className;
        var index = className.indexOf('is-show');

        if(index > 0) {
            className = className.slice(0, index - 1);
        } else {
            className = '';
        }

        this.wrap.className = className;
    };

    win.o.Search = Search;

})(window, document);

(function(win, doc){
    var search = null;
    doc.onreadystatechange = function(){
        if(doc.readyState === 'complete') {
            search = new win.o.Search();
        }
    }
})(window, document);
@@ -528,46 +528,8 @@
 n;%0A%0A
-        if(doc.addEventListener)%7B%0A    
     
@@ -582,36 +582,32 @@
 ()%7B%0A            
-    
 self.show();%0A   
@@ -603,36 +603,32 @@
 show();%0A        
-   
- 
 %7D, false);%0A     
@@ -618,28 +618,24 @@
  %7D, false);%0A
-    
         clos
@@ -669,36 +669,32 @@
 k', function()%7B%0A
-    
             self
@@ -706,28 +706,24 @@
 ();%0A        
-    
 %7D, false);%0A 
@@ -725,232 +725,8 @@
 e);%0A
-        %7D else %7B%0A            openBtn.attachEvent('click', function()%7B%0A                self.show();%0A            %7D);%0A            closeBtn.attachEvent('click', function()%7B%0A                self.hide();%0A            %7D);%0A        %7D%0A
     

remove compatible js code for ie8, it's needless.