Forward Mouse Events - JQuery Plugin

Forward Mouse Events

A plugin for making an overlayed element pass events through it and make the element under it to receive the events. Re-written for JQuery from an ExtJS plugin. The plugin now supports dblclick also.
Element1Element2 Overlay

Example Container
Overlay
                            <div id="ForwardEventsExample">
								<span id="ForwardEventsElement1">Element1</span><span id="ForwardEventsElement2">Element2</span>
								<span id="ForwardEventsOverlay">Overlay</span>
								<br /><br />
								Example Container
							</div>
							<div id="ForwardEventsLog" class="ExampleLog">Overlay</div>
                        
                       
	                        $(function () {
			                    function Log(element, message, enableCount){
									if(message){			
										if(enableCount){
											var count = $(element).data("LogCount");
											if(!count)
												count = 0;
											$(element).html(count++ + " --> " + message + "<br />" + $(element).html()).data("LogCount", count); 
										}
										else{
											$(element).html(message + "<br />" + $(element).html()); 
										}
									}
									else {
										LogConsole(element);
									}
								}
						
								$("#ForwardEventsOverlay").forwardMouseEvents();
								$("#ForwardEventsElement1,#ForwardEventsElement2").bind('mouseover mouseout click dblclick mouseup mousedown',function (e) {				
									
									// Skip events that moves to/from overlay elements
									if(e.type == 'mouseout' && e.relatedTarget === $("#ForwardEventsOverlay")[0]) 
										return;
									if(e.type == 'mouseover' && e.relatedTarget === $("#ForwardEventsOverlay")[0])
										return;
									Log("#ForwardEventsLog", e.type + " "+ $(e.target).attr('id') + 
											" --> ClientX :  " + e.clientX + " | ClientY : " + e.clientY + 
											" | PageX : " + e.pageX + " | PageY : " + e.pageY + 
											" | CurrentTarget : "+ $(e.currentTarget).attr('id') + " | RelatedTarget : " + $(e.relatedTarget).attr('id'), true);
								});
	                        });	                   
                        
                            #ForwardEventsExample
							{
								position:relative;
								width:660px;
								height: 120px;
								margin-bottom:20px;
								padding:20px;	
								border:solid 1px #999999;
							}
							#ForwardEventsElement1, #ForwardEventsElement2
							{
								width:75px;
								height:75px;
								background: #EEEEFF;
								border: solid 1px #C0C0C0;
								display:inline-block;
								vertical-align:top;	
							}
							.ForwardEventsElementHover
							{
								background: #E0E0FF !important;
								border: solid 1px #AAAAAA !important;
							}
							.ForwardEventsElementClick
							{
								background: #FFEEEE !important;	
							}

							#ForwardEventsOverlay
							{
								width:75px;
								height:75px;
								background: #999999;
								position: absolute;
								top:60px;
								left:62px;	
								opacity: 0.5;
								filter: alpha(opacity=50);								
							}