"+data.text+"");}}).get(); } }); var CopyBlocker = new Class({ Implements: [Options,Events], options: { "specer":"spacer.png", "move":true,//キーで移動 "cover":true//画像によるカバー }, initialize: function(key,options) { this.setOptions(options); this.parent = $(document.body); if(this.options.cover){ this.wrapper = new Element("img",{"src":this.options.specer,"id":"copyblocker","styles":{"position":"absolute","top":0,"left":0,"z-index":999,"width":this.parent.getSize().x,"height":this.parent.getSize().y}}); this.wrapper.inject(this.parent,"top"); } this.target = Browser.Engine.trident?this.parent:window; this.target.addEvents({ 'keydown':function(event){ //A=65 C=67 if(event.control == true && event.code == 65 || event.control == true && event.code == 67) return false; if(this.options.move){ switch(event.code){ case(66): history.back(); break;//B case(78): history.go(1); break;//N } } }, "copy":function(){ return false;}, "resize":function(){ if(this.options.cover) this.wrapper.setStyles({"width":this.parent.getSize().x,"height":this.parent.getSize().y}); }.bind(this) }); } }); //]]>