Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Dodefault nodefault dodefault
Message
De
12/08/2009 20:24:39
Dragan Nedeljkovich (En ligne)
Now officially retired
Zrenjanin, Serbia
 
 
À
11/08/2009 10:55:15
Information générale
Forum:
Visual FoxPro
Catégorie:
Programmation Orientée Object
Versions des environnements
Visual FoxPro:
VFP 9 SP1
OS:
Windows XP SP2
Database:
Visual FoxPro
Divers
Thread ID:
01417200
Message ID:
01417767
Vues:
47
>I'm not sure everybody will agree that it is a bug. It may be argued that it is by design. (But bad design in my opinion.)
>
>However, I have done some testing on combinations. Andy had tested two levels. I have tested three levels. I have included here a picture with (hopefully all relevant) combinations and their results.
>The tested event is a Textbox.Keypress event. This event has the advantage that a case of two occurences of intrinsic native behavior is visible because the keypress is doubled. E.g. when typing ‘a’ the result will be ‘aa’.
>
>Subclass 1 is based on the native textbox base class. Subclass 2 is based on subclass 1. Subclass 3 is based on subclass 2. A test form only contains an object based on subclass 3.
>
>Note: A subclass 1 object (e.g. in a form) can be recognized by its parentclass name. It will then be 'container' or 'textbox' or 'grid' or whatever base class name it's based on. An empty parentclass name indicates that the object was derived directly from a base class.
>
>And yet another note: When adding an object that's based on a base class to a form (its parentclass name will be empty) and adding the line [ dodefault(nKeyCode, nShiftAltCtrl) ] to the keypress event, it will fire the intrinsic native behavior twice! So, this 'bug' is even possible if no subclassing is done.

May I suggest a test? Bindevent() to that. See how many times it executes.

back to same old

the first online autobiography, unfinished by design
What, me reckless? I'm full of recks!
Balkans, eh? Count them.
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform