From ericpmoyer at gmail.com Thu Oct 22 09:34:12 2009 From: ericpmoyer at gmail.com (Eric Moyer) Date: Thu, 22 Oct 2009 00:34:12 -0700 Subject: [sbe-discussion] Fixing Lights Out mouseMove Bug (PBE) Message-ID: <000e01ca52ea$0edb04e0$2c910ea0$@com> In the 2009-10-11 version of PBE, the Lights Out game has a bug where moving the mouse between the click and the release will cause the clicked cell to toggle. The problem can be fixed by overriding LOCell>>mouseMove: with an empty method containing: mouseMove: anEvent I'm new to SmallTalk/Pharo, so I don't know if there's a stylistically better way to block the message, but the above fix does the trick. I think it's worth fixing in PBE, rather than risk newcomers thinking that the odd behavior is somehow a bug in the environment rather than the app. On a more subtle note, for some reason the minus sign in the PBE PDF (see Method 2.6) turns into a double-minus if copied/pasted into Pharo (or any simple text application) on Windows, resulting in the line c position: ((i -- 1) * c width) @ ((j -- 1) * c height) + origin. Instead of the intended c position: ((i - 1) * c width) @ ((j -1) * c height) + origin. There are a few instances of that behavior in the Lights Out code. The resulting code evaluates to i minus -1 instead of the intended i-1, with very awkward results. Cheers, Eric -------------- next part -------------- An HTML attachment was scrubbed... URL: