home *** CD-ROM | disk | FTP | other *** search
/ GameStar 2004 July & August / Gamestar_64_2004-07-08_dvd.iso / Programy / winamp501_full.exe / $_14327_ / seek.maki (.txt) < prev    next >
Winamp Compiled Maki Script  |  2003-11-16  |  2KB  |  77 lines

  1. /* Note: a decompiler is no invitation to steal code.
  2.    Please respect the the copyright */
  3.  
  4. #include "std.mi"
  5. Global Group Group2;
  6. Global Slider Slider3;
  7. Global Int Int4;
  8. Global Timer Timer5;
  9. Global Text Text6;
  10. Global Layer Layer7;
  11.  
  12.  
  13. System.onScriptLoaded()
  14. {
  15. Group2 = System.getScriptGroup();
  16. Slider3 = Group2.findObject(( "SeekerGhost"));
  17. Text6 = Group2.findObject(( "songticker"));
  18. Layer7 = Group2.findObject(( "player\.seekbar\.pos"));
  19. Timer5 = ( new Timer);
  20. Timer5.setDelay(1000);
  21. return Null;
  22. }
  23.  
  24. Timer5.onTimer()
  25. {
  26. Text6.setText(( ""));
  27. Timer5.stop();
  28. return Null;
  29. }
  30.  
  31. System.onScriptUnloading()
  32. {
  33. delete Timer5;
  34. return Null;
  35. }
  36.  
  37. Slider3.onSetPosition(int newpos)
  38. {
  39. Int Int19;
  40. Float Float14;
  41. Float Float17;
  42. if(Int4) {
  43. Float14 = newpos;
  44. Float14 = ( ( Float14 / 255) * 100);
  45. Float17 = System.getPlayItemLength();
  46. if(( Float17 != 0)) {
  47. Int19 = ( ( Float17 * Float14) / 100);
  48. Timer5.start();
  49. Text6.setText(( ( ( ( ( ( ( "SEEK\:") + System.integerToTime(Int19)) + ( "\/")) + System.integerToTime(Float17)) + ( "\ \(")) + System.integerToString(Float14)) + ( "\%\)\ ")));
  50. }
  51. }
  52. return Null;
  53. }
  54.  
  55. Slider3.onLeftButtonDown(int x, int y)
  56. {
  57. Int4 = 1;
  58. return Null;
  59. }
  60.  
  61. Slider3.onLeftButtonUp(int x, int y)
  62. {
  63. Int4 = 0;
  64. Timer5.start();
  65. Text6.setText(( ""));
  66. return Null;
  67. }
  68.  
  69. Slider3.onSetFinalPosition(int pos)
  70. {
  71. Timer5.start();
  72. Text6.setText(( ""));
  73. return Null;
  74. }
  75.  
  76.  
  77.