On Sun, Sep 26, 2010 at 3:12 PM, Marc Tompkins <marc.tompk...@gmail.com>wrote:

> On Sun, Sep 26, 2010 at 1:01 PM, Bill Allen <walle...@gmail.com> wrote:
>
>>
>> Any thoughts how I am going wrong here?
>>
>> Looks like you've got two different names for the first mouse click...
>
>         mouse_pos1 = mouse_pos
>>
>
> but
>
> if mouse_pos[1] < height/2 and mouse_pos2[1] > height/2:
>>
>
>
> Bingo!  Yes, that's the problem.  Should have  been if mouse_pos1[1] <
height/2 and mouse_pos2[1] > height/2:  rather than if mouse_pos[1] <
height/2 and mouse_pos2[1] > height/2:

That was basically a typo to which I had become completely blind.  I did it
in the second case as well, but it did not affect the result in that case,
making it even harder for me to spot.

I hate it when I do something like that!    A combination of poor choice of
names for the variables and programming tunnel vision....

Many thanks,
Bill
_______________________________________________
Tutor maillist  -  Tutor@python.org
To unsubscribe or change subscription options:
http://mail.python.org/mailman/listinfo/tutor

Reply via email to