<?xml version="1.0" encoding="UTF-8"?>
<bindings xmlns="http://www.mozilla.org/xbl">
<binding id="default">
	<implementation>
		<constructor>//<![CDATA[
		if (!("elementFromPoint" in this.ownerDocument))
			this.ownerDocument.elementFromPoint = function() {
				return this.documentElement;
			}
		
		var self = this;
		
		window.addEventListener("load", function() {
			var box = self.ownerDocument.getBoxObjectFor(self);			
			self.ownerDocument.elementFromPoint = (function(old, self, x1, y1, x2, y2) {
				return function(x,y) {
					if (x1 <= x && x <= x2 && y1 <= y && y <= y2)
						return self;
					else
						return old.call(this, x, y);
				}
			})(self.ownerDocument.elementFromPoint, self, box.x, box.y, box.x+box.width, box.y+box.height);
		}, false);
		//]]></constructor>
	</implementation>
</binding>
</bindings>