home *** CD-ROM | disk | FTP | other *** search
/ CD Actual 45 / cda45.iso / intro.dxr / scripts_15_scroll.ls < prev    next >
Encoding:
Text File  |  2000-04-18  |  487 b   |  21 lines

  1. property texto, direccion
  2.  
  3. on getPropertyDescriptionList me
  4.   lista = [:]
  5.   addProp(lista, #texto, [#format: #text, #default: "descripcion", #comment: "Cast para el scroll"])
  6.   addProp(lista, #direccion, [#format: #symbol, #default: #arriba, #range: [#arriba, #abajo], #comment: "Direccion"])
  7.   return lista
  8. end
  9.  
  10. on mouseDown me
  11.   if direccion = #arriba then
  12.     d = -1
  13.   else
  14.     d = 1
  15.   end if
  16.   repeat while the mouseDown
  17.     scrollByLine(texto, d)
  18.     updateStage()
  19.   end repeat
  20. end
  21.