forum.vdsworld.com Forum Index forum.vdsworld.com
Visit VDSWORLD.com
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 


Mouse Over Problem

 
Post new topic   Reply to topic    forum.vdsworld.com Forum Index -> General Help
View previous topic :: View next topic  
Author Message
Rubes_sw
Valued Contributor
Valued Contributor


Joined: 11 Jun 2001
Posts: 625
Location: Northern Ireland

PostPosted: Tue Dec 17, 2002 3:57 pm    Post subject: Mouse Over Problem Reply with quote

Does anyone have any script that will:

Detect if the mouse is over my dialog, no matter where my dialog is on the screen???


Nathan
Back to top
View user's profile Send private message Send e-mail Visit poster's website
LiquidCode
Moderator Team


Joined: 05 Dec 2000
Posts: 1753
Location: Space and Time

PostPosted: Tue Dec 17, 2002 4:18 pm    Post subject: Reply with quote

Here ya go. Smile

Code:

  DIALOG CREATE,Mouse Over Dialog,-1,0,240,160
  DIALOG ADD,STYLE,STYLE1,,18,B,,0000A0
  DIALOG ADD,TEXT,TEXT1,36,62,112,13,Pass mouse over dialog
  DIALOG ADD,TEXT,TEXT2,70,76,84,29,TEXT2,,STYLE1
  DIALOG SHOW

:evloop
    wait event,0
   %e = @event()
   goto %e
   rem here starts the mouseover code

:timer
   %%top = @sum(@Winpos(@Winexist(Mouse Over Dialog),T),4)
   %%left = @Winpos(@Winexist(Mouse Over Dialog),L)
   %%wide = @diff(@Winpos(@Winexist(Mouse Over Dialog),W),3)
   %%high = @Winpos(@Winexist(Mouse Over Dialog),H)
   %y = @mousepos(y)
   %x = @mousepos(x)
   if @equal(1111,@greater(%x,@sum(%%left,0))@greater(@sum(@sum(%%left,%%wide),0),%x)@greater(%y,@sum(%%top,0))@greater(@sum(@sum(%%top,%%high),0),%y))
      dialog set,text2,OVER
   else
      dialog set,text2,OUT
   end
   goto evloop
   
:Close

_________________
Chris
Http://theblindhouse.com
Back to top
View user's profile Send private message Send e-mail Visit poster's website
Display posts from previous:   
Post new topic   Reply to topic    forum.vdsworld.com Forum Index -> General Help All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You can attach files in this forum
You can download files in this forum

Twitter@vdsworld       RSS

Powered by phpBB © 2001, 2005 phpBB Group