Search content:

 

Personal Menu
Username:
Password:
Save password

Become a member

Forgot Password?

 

Don't miss these
Saving Data in Shockwave
Select All Behavior (Ctrl + A)
Direct TTS (Text to speech)
Label Search code
27 Sum Game-Numbers
DM Stars Field Effect
Slider Puzzle by J.R.D.R.
Easy Dialog
Rename for lingo animations
Components XObject
MediaMacros Xtras Mall
 

 

 

Behavior Exit Windows

Added on 6/8/2000

 

Compatibilities:
behavior D7 D8 PC

Required Xtras:
Buddy API

Rating:

Author: KumarK

Exits Windows

---- written for Director 8 ---
---- Kumar.K kumark@icode.com ----

-- custom properties --
property exitwin,whereto

------ Get Behavior Description List ------
on getPropertyDescriptionList me
  set description = [:]
  wayslist=["reboot","restart","logoff","shutdown"]
  addProp description, #exitwin, [#format:#String, #comment: "Options to Exit Windows?", #range:wayslist,#default:wayslist[1]]
  if the currentspritenum = 0 then
    addProp description, #WhereTo, [#comment: "Where To Attach ?" ,#format:#String,
    #range:["On EnterFrame","On ExitFrame"],#default:"On EnterFrame"]
  else
    addProp description, #WhereTo, [#comment: "Where To Attach ?" ,#format:#String,
    #range:["On MouseUp","On MouseDown","On MouseEnter","On MouseLeave"],#default:"On MouseUp"]    
  end if    
  return description
end getPropertyDescriptionList
------ Get Behavior Description List ------

-- Get Behavior description --
on getBehaviorDescription
  return "This Behavior Exits windows. " & RETURN & RETURN &
  "This Behavior requires Buddy API Xtra to work, so please ensure You Have Buddy API Xtra." & RETURN & RETURN &
  "Parameters" & RETURN &
  "* exit windows option." & RETURN &
  "* Where to attach this Script"
end
-- Get Behavior description --

-- Events --
on EnterFrame me
  if WhereTo = "On EnterFrame" then
    exitwindows
  end if
end EnterFrame

on ExitFrame me
  if WhereTo = "On EnterFrame" then
    exitwindows
  end if
end ExitFrame

on MouseUp
  if WhereTo = "On MouseUp" then
    exitwindows
  end if
end MouseUp

on MouseDown
  if WhereTo = "On MouseDown" then
    exitwindows
  end if
end MouseDown

on MouseEnter
  if WhereTo = "On MouseEnter" then
    exitwindows
  end if
end MouseEnter

on MouseLeave
  if WhereTo = "On MouseLeave" then
    exitwindows
  end if
end MouseLeave
------ Events ------

-- exitwindows --
on exitwindows
  case exitwin of
    "reboot":baExitWindows( "reboot" )
    "restart":baExitWindows( "restart" )
    "logoff":baExitWindows( "logoff" )
    "shutdown":baExitWindows( "shutdown" )  
  end case
end
-- exitwindows --


 


Upload Provided by ABCUpload ASP

Contact

MMI
22 West Court Sq
Suite 2C
Newnan, GA 30263
USA

Fax - (206) 339-5833

Send e-mail