equal
deleted
inserted
replaced
72 pointerCount : Longword; |
72 pointerCount : Longword; |
73 fingers: array of TTouch_Data; |
73 fingers: array of TTouch_Data; |
74 moveCursor : boolean; |
74 moveCursor : boolean; |
75 invertCursor : boolean; |
75 invertCursor : boolean; |
76 |
76 |
77 xTouchClick,yTouchClick : LongInt; |
|
78 timeSinceClick : Longword; |
|
79 |
|
80 //Pinch to zoom |
77 //Pinch to zoom |
81 pinchSize : LongInt; |
78 pinchSize : LongInt; |
82 baseZoomValue: GLFloat; |
79 baseZoomValue: GLFloat; |
83 |
80 |
84 //aiming |
81 //aiming |
315 end; |
312 end; |
316 end; |
313 end; |
317 |
314 |
318 procedure onTouchClick(finger: TTouch_Data); |
315 procedure onTouchClick(finger: TTouch_Data); |
319 begin |
316 begin |
320 //if (RealTicks - timeSinceClick < 300) and (sqrt(sqr(finger.X-xTouchClick) + sqr(finger.Y-yTouchClick)) < 30) then |
|
321 // begin |
|
322 // onTouchDoubleClick(finger); |
|
323 // timeSinceClick:= 0;//we make an assumption there won't be an 'click' in the first 300 ticks(milliseconds) |
|
324 // exit; |
|
325 // end; |
|
326 |
|
327 xTouchClick:= finger.x; |
|
328 yTouchClick:= finger.y; |
|
329 timeSinceClick:= RealTicks; |
|
330 |
317 |
331 if bShowAmmoMenu then |
318 if bShowAmmoMenu then |
332 begin |
319 begin |
333 if isOnRect(AmmoRect, finger) then |
320 if isOnRect(AmmoRect, finger) then |
334 begin |
321 begin |
635 end; |
622 end; |
636 |
623 |
637 procedure initModule; |
624 procedure initModule; |
638 var |
625 var |
639 index: Longword; |
626 index: Longword; |
640 //uRenderCoordScaleX, uRenderCoordScaleY: Longword; |
|
641 begin |
627 begin |
642 buttonsDown:= 0; |
628 buttonsDown:= 0; |
643 pointerCount:= 0; |
629 pointerCount:= 0; |
644 |
630 |
645 setLength(fingers, 4); |
631 setLength(fingers, 4); |