home *** CD-ROM | disk | FTP | other *** search
/ The Fred Fish Collection 1.5 / ffcollection-1-5-1992-11.iso / ff_progs / prog_c / window.lzh / WINDOW / POSTER < prev    next >
Encoding:
Text File  |  1991-11-01  |  2.6 KB  |  75 lines

  1. Article 5072 of net.micro.amiga:
  2. Relay-Version: version B 2.10.3 4.3bsd-beta 6/6/85; site well.UUCP
  3. Path: well!ptsfa!qantel!lll-lcc!lll-crg!rutgers!caip!cbmvax!andy
  4. From: andy@cbmvax.cbm.UUCP (Andy Finkel)
  5. Newsgroups: net.micro.amiga
  6. Subject: Creating a DOS Window in a Custom Screen
  7. Message-ID: <901@cbmvax.cbmvax.cbm.UUCP>
  8. Date: 15 Oct 86 17:04:17 GMT
  9. Date-Received: 16 Oct 86 11:44:54 GMT
  10. Reply-To: andy@cbmvax.UUCP (Andy Finkel)
  11. Organization: Commodore Technology, West Chester, PA
  12. Lines: 302
  13.  
  14. Tricks with AmigaDOS, part II.
  15.  
  16. As you may recall, part one was all about finding the window pointer and
  17. console.device IO Request Block from a DOS window.  Part II is about how
  18. to go the other way: make an Intuition window into a DOS window.  
  19.  
  20. Specifically, this is used to get a DOS window to open in a custom
  21. screen. There are reasons why this is something you might want to do...
  22. like, oh, using the Execute command to initialize a new disk in a program
  23. that doesn't use the Workbench screen.
  24.  
  25. We all knew it was possible...remember the first ABasic ? (by MetaCompCo)
  26.  
  27.  
  28. For those of you writing shells...under V1.2 the ability to switch a
  29. window in or out of RAW mode via an AmigaDOS packet can be used to
  30. good advantage when combined with this.
  31.  
  32.  
  33. There are 3 files:  window.c which contains most of the program, console.asm
  34. which contains the assembler interface calls to the BCPL routines of 
  35. AmigaDOS, and window.i, the include file I use when I am doing tricks
  36. like this.
  37.  
  38. Break up the file into its component parts, compile, assemble, and link.
  39.  
  40. Two warning...under the pressure of 1.2 I've only compiled it under the
  41. Greenhills C cross compiler running on the Sun...so some slight changes
  42. may be needed for other compilers.  I'm only linking with the amiga.lib 
  43. on this one.
  44.  
  45. The other warning...to finish this quickly (as some people need it now)
  46. I used 3 of the BCPL global routines.  (Sorry).  Actually, I
  47. only had to use 2 (finddevice and loaddevice) but as long as I
  48. was doing it, I went ahead and used the DOS sendpacket).  Assembler versions
  49. of those functions are possible (I think, sigh).
  50.  
  51. Anyway, another completed chapter in the mysteries of AmigaDos.
  52.  
  53.                 andy finkel
  54.                 Commodore-Amiga
  55.  
  56.  
  57.  
  58. ----------------------CUT HERE------------------------------------------
  59. -------------------------CUT HERE *********************
  60.  
  61. -- 
  62.  
  63.             andy finkel
  64.             Commodore(Amiga)
  65.             {ihnp4|seismo|allegra}!cbmvax!andy
  66.         or     pyramid!amiga!andy
  67.  
  68. Any expressed opinions are mine; but feel free to share.
  69.  
  70. I disclaim all responsibilities, all shapes, all sizes, all colors.
  71.  
  72. "Remember, no matter where you grow, there you are." - Buckaroo Bonsai.
  73.  
  74.  
  75.