Thread: TrackwheelClick
View Single Post
Old 09-23-2004, 10:41 AM   #12
movalys_matt
Knows Where the Search Button Is
 
Join Date: Aug 2004
Posts: 29
Default

doooooooooooooooooooooooooooooone

okay boys and girls, here is my solution

int endExec = 0;
long resetDate = 0;
boolean firstExecution = true;

public boolean trackwheelClick(int status, int time) {
if(firstExecution){
resetDate = System.currentTimeMillis() - time;
firstExecution = false;
}
if(time>endExec){
...
//execute an action here
...
endExec= (int)(System.currentTimeMillis() - resetDate);
}
return true;
}

it seems to be working
BUT (because there is always stg to be improved)
it would be more beautiful(with butterflies and little flowers) if I could get the resetDate directly form the device itself.
Offline