home *** CD-ROM | disk | FTP | other *** search
/ Tricks of the Mac Game Programming Gurus / TricksOfTheMacGameProgrammingGurus.iso / Tools / Preditor 2.0 / Macros / WriteOpen < prev   
Encoding:
Text File  |  1991-07-22  |  1.0 KB  |  50 lines  |  [TEXT/TCEd]

  1. #
  2. #    WriteOpen
  3. #
  4. #    Last Modified: Friday, June 27, 1991 at 11:46 PM
  5. #    Macro Files for Preditor
  6. #
  7. #    Writes a list of "Open…" commands which can be executed
  8. #    the next time Preditor starts.  Targets a file called
  9. #    "Preditor.resume".
  10. #
  11. #    To Install:
  12. #
  13. #    1)    Create an empty file called Preditor.resume
  14. #
  15. #    2)    Add the line:
  16. #
  17. #            ":Preditor Folder:Preditor.resume"()
  18. #
  19. #        to the end of the Predior.startup file.
  20. #
  21. #    3)    Also add:
  22. #
  23. #            AddMenu "Quit" 32 1
  24. #                WriteOpen()
  25. #            EndMenu
  26. #
  27. #        to the Preditor.startup file (or any .startup file)
  28. #
  29. #    Command-Q will now run WriteOpen, which saves the list
  30. #    of open files and quits.  When Preditor starts up again
  31. #    the files that were open will be opened again.
  32. #
  33. #    © Copyright Evatac Software  1988-1991
  34. #    All rights reserved
  35. #
  36.  
  37. resumeFile = "Preditor.resume"
  38.  
  39. Open(~Preditor + resumeFile, "a")
  40.  
  41.  
  42. Clear(•:∞, resumeFile)
  43. Insert("### Preditor Resume Macro\n\n", §, resumeFile)
  44. For (file, ~Windows)
  45.     Insert("Open(\"" + file + "\")\n", §, resumeFile)
  46. End
  47.  
  48. Close("y", resumeFile)
  49. Quit("")
  50.