Rect.Contains Bug

I have some code where when the mouse goes over two GUI windows, it disables a visualizer cube movement. But for some reason, the second window activates the cube BELOW itself. Heres some of the code:

function Update () {  
        var window1 = ChooseCurrentBlock.chooseBlockWindow;
	var window2 = WorldEditWindow.worldEditWindowRect;
	if ((window1.Contains(Input.mousePosition) == false) && (window2.Contains(Input.mousePosition) == true)) {
		disableVisualzerCubeMovement = true;
	} else if ((window1.Contains(Input.mousePosition) == true) && (window2.Contains(Input.mousePosition) == false)) {
		disableVisualzerCubeMovement = true;
	} else {
		disableVisualzerCubeMovement = false;

There’s no bug; you’re mixing two different types of coordinates. Input.mousePosition returns coordinates in screen space, whereas OnGUI code uses GUI space. Always use Event.current.mousePosition when dealing with OnGUI code, not Input.