Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Move object container inside a container
Message
 
 
À
15/12/2008 14:28:57
Information générale
Forum:
Visual FoxPro
Catégorie:
Gestionnaire d'écran & Écrans
Versions des environnements
Visual FoxPro:
VFP 9 SP2
OS:
Windows XP SP2
Network:
Windows XP
Database:
Visual FoxPro
Application:
Desktop
Divers
Thread ID:
01367578
Message ID:
01367581
Vues:
6
What is the purpose of DO WHILE MDOWN() loop?

>Hi...
>
>I'm using a container with width = 4000.. inside of other one of width=500px and by the press of mouse I'm moving across X axys using the follow routine:
>
>Sometime this routine behaves weird (no response) and heavy... And I'd like to know if someone know or could point me what could I change to use this smartier than that...
>
>TIA.. Claudio
>
>
procedure mousedown
>LPARAMETERS nButton, nShift, nXCoord, nYCoord
>Local lnOldPos, ;
>    lnAvgCharWidth, ;
>    lnMinPos, ;
>    lnMaxPos, ;
>    lnCurPos, ;
>    lnParentLeft
>lnAvgCharheight      = FONTMETRIC(1)
>lnAvgCharwidth       = FONTMETRIC(6)
>lnParentLeft         = this.otimeline.top
>lnMinPos             = (this.width-This.otimeline.width-2)
>lnMaxPos             = 3
>lnCurPos             = this.otimeline.top
>lnCurPosy            = Mrow(thisform.name, 3)
>lnCurPosx            = Mcol(thisform.name, 3)
>lnCurINIy            = Mrow(thisform.name, 3)
>lnCurINIx            = Mcol(thisform.name, 3)
>lnrowini             = this.otimeline.top
>lncolini             = this.otimeline.left
>
>Do  WHILE MDOWN() 
>    This.otimeline.Move(MAX(lnMinPos, MIN(lnCurPosx, lnMaxPos)),lnParentLeft)
>    lnCurPosx = lncolini + ( Mcol(thisform.name, 3) - lnCurINIx )
>Enddo
>endproc
If it's not broken, fix it until it is.


My Blog
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform