Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Clicks on an image don't always fire
Message
Information générale
Forum:
Visual FoxPro
Catégorie:
Autre
Versions des environnements
Visual FoxPro:
VFP 9 SP2
OS:
Vista
Network:
Windows 2008 Server
Database:
MS SQL Server
Divers
Thread ID:
01353639
Message ID:
01353939
Vues:
22
>>Hey Russell,
>>
>>>But, regardless of that, I still had to change the _DblClick sys var so that rapid clicks on the new image-based button will behave like rapid clicks on the button.
>>>
>>
>>Why not just have the DblClick event call the Click event? I would try and avoid changing a global setting like _DblClick.
>>
>>
>>FUNCTION DblClick
>>   This.Click()
>>ENDFUNC
>>
>
>I did think about that. However, this means that two clicks would be required to perform the normal action. The buttons are taking an image and enlarging it 10% or reducing it 10%. So they'd have to click twice to get one 10% enlargement. Of course, knowing it was double click calling a click, I could enlarge 20%, but then how would they enlarge just 10%? Slower single clicks, that's how, but it seemed it would be a problematic and not very friendly interface. I decided to change the _DblClick var for this page only (the graphic and the buttons in question reside on a page of a page frame). I change it via the Activate and change it back via the Deactivate. This gets the problem solved. Thanks for the suggestion, though. You gonna be at AFUG next week?

I don't think it has to be that cumbersome. If you double click, the click fires too, so if you call the click from the dblclick (as suggested) when you double click, tripple click, quadruple click on the image, the click will fire as many times as you expect it would. Without having any special workaraound code in the dblclick to handle it. I have used this technique for years to eliminate the dblclick on a checkbox.

I'm not sure on AFUG yet. I fly out the next morning for Phoenix. I'll try to make it.
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform