From: Wouter V. <m97...@us...> - 2013-10-08 18:20:03
|
This is an automated email from the git hooks/post-receive script. It was generated because a ref change was pushed to the repository containing the project "openMSX (main)". The branch, master has been updated via 63a5d077e86380b5f30d4dd2fe4d2109ed59cb97 (commit) from 4418645d96cd113ad9933e8e695a2ee802b1ae24 (commit) Those revisions listed above that are new to this repository have not appeared on any other notification email; so we list those revisions in full, below. - Log ----------------------------------------------------------------- commit 63a5d077e86380b5f30d4dd2fe4d2109ed59cb97 Author: wouter <ver...@gm...> Date: Tue Oct 8 20:18:16 2013 +0200 Implemented a touchpad emulation detail See RFE#252, returned x/y values when tablet is not touched. ----------------------------------------------------------------------- Summary of changes: src/input/Touchpad.cc | 9 +++++---- 1 files changed, 5 insertions(+), 4 deletions(-) diff --git a/src/input/Touchpad.cc b/src/input/Touchpad.cc index 0c697b8..79d8844 100644 --- a/src/input/Touchpad.cc +++ b/src/input/Touchpad.cc @@ -173,10 +173,11 @@ void Touchpad::write(byte value, EmuTime::param time) start = time; // to keep EOC=0 for 56 cycles } else { // CS 1->0 - // TODO what value do the X/Y-channels return when - // the panel is not touched? - shift = (channel == 0) ? x - : (channel == 3) ? y + // Tested by SD-Snatcher (see RFE #252): + // When not touched X is always 0, and Y floats + // between 147 and 149 (mostly 148). + shift = (channel == 0) ? (touch ? x : 0) + : (channel == 3) ? (touch ? y : 148) : 0; // channel 1 and 2 return 0 } } hooks/post-receive -- openMSX (main) |