Path: utzoo!utgpu!news-server.csri.toronto.edu!cs.utexas.edu!swrinde!zaphod.mps.ohio-state.edu!pacific.mps.ohio-state.edu!linac!mp.cs.niu.edu!ux1.cso.uiuc.edu!uxa.cso.uiuc.edu!dmmg1176 From: dmmg1176@uxa.cso.uiuc.edu (David M Marcovitz) Newsgroups: comp.sys.mac.programmer Subject: Re: Double Click in Think C Message-ID: <1991Apr15.155413.11238@ux1.cso.uiuc.edu> Date: 15 Apr 91 15:54:13 GMT References: <1991Apr9.203739.29376@ux1.cso.uiuc.edu> Sender: usenet@ux1.cso.uiuc.edu (News) Organization: University of Illinois at Urbana Lines: 23 This is a "summary" of the responses I got about how to do a double-click in THINK C. The main issue is that a double click is two distinct clicks. The first click should be treated like a normal click, and the second click should be handled in a special way (if you want). Thus, in a double click, the first click is processed assuming there may or may not be a second click. If the firts click highlights something and the second opens it, a double click should not just open the object; it should highlight it first. Given this, the method I suggested in the first note (saving the time of the last click and checking to see if the new click is less than GetDblTime() away from that) will work. However, in THINK C, there is a variable gClicks that will count how many clicks it took to get you to the current event. These variables can be checked in the DoMouseDown method of the object. -- David M. Marcovitz | internet: marcovitz@uiuc.edu Computer-based Education Research Lab | dmmg1176@uxa.cso.uiuc.edu University of Illinois | novanet: marco / cca / cerl