home *** CD-ROM | disk | FTP | other *** search
/ MACD 4 / MACD4.iso / Emulatory / AROS / intuition / setwindowtitles.c < prev    next >
Encoding:
C/C++ Source or Header  |  1978-03-06  |  2.5 KB  |  98 lines

  1. /*
  2.     (C) 1995-96 AROS - The Amiga Replacement OS
  3.     $Id: setwindowtitles.c,v 1.4 1996/11/08 11:28:04 aros Exp $
  4.     $Log: setwindowtitles.c,v $
  5.     Revision 1.4  1996/11/08 11:28:04  aros
  6.     All OS function use now Amiga types
  7.  
  8.     Moved intuition-driver protos to intuition_intern.h
  9.  
  10.     Revision 1.3  1996/10/24 15:51:25  aros
  11.     Use the official AROS macros over the __AROS versions.
  12.  
  13.     Revision 1.2  1996/08/29 13:57:38  digulla
  14.     Commented
  15.     Moved common code from driver to Intuition
  16.  
  17.     Revision 1.1  1996/08/23 17:28:18  digulla
  18.     Several new functions; some still empty.
  19.  
  20.  
  21.     Desc:
  22.     Lang: english
  23. */
  24. #include "intuition_intern.h"
  25.  
  26. /*****************************************************************************
  27.  
  28.     NAME */
  29.     #include <clib/intuition_protos.h>
  30.  
  31.     AROS_LH3(void, SetWindowTitles,
  32.  
  33. /*  SYNOPSIS */
  34.     AROS_LHA(struct Window *, window, A0),
  35.     AROS_LHA(UBYTE         *, windowTitle, A1),
  36.     AROS_LHA(UBYTE         *, screenTitle, A2),
  37.  
  38. /*  LOCATION */
  39.     struct IntuitionBase *, IntuitionBase, 46, Intuition)
  40.  
  41. /*  FUNCTION
  42.     Changes the current window and/or the screen title.
  43.  
  44.     INPUTS
  45.     window - Change the title for this window or the screen which the
  46.         window contains.
  47.     windowTitle - New title for the window or ((UBYTE *)~0L) to keep the
  48.         old title or NULL for no title. If you specify a string,
  49.         this string is *NOT* copied.
  50.     screenTitle - New title for the screen of the window or ((UBYTE *)~0L)
  51.         to keep the old title or NULL for no title. If you specify
  52.         a title for the screen, this title will be shown when the
  53.         window becomes active. If you specify a string, this string
  54.         is *NOT* copied.
  55.  
  56.     RESULT
  57.     None.
  58.  
  59.     NOTES
  60.     You should be careful with specifying a screen title because that
  61.     may irritate the user.
  62.  
  63.     EXAMPLE
  64.  
  65.     BUGS
  66.  
  67.     SEE ALSO
  68.  
  69.     INTERNALS
  70.  
  71.     HISTORY
  72.     29-10-95    digulla automatically created from
  73.                 intuition_lib.fd and clib/intuition_protos.h
  74.  
  75. *****************************************************************************/
  76. {
  77.     AROS_LIBFUNC_INIT
  78.     AROS_LIBBASE_EXT_DECL(struct IntuitionBase *,IntuitionBase)
  79.  
  80.     /* Call driver before changing the window to allow it to examine
  81.     the old values. */
  82.     intui_SetWindowTitles (window, windowTitle, screenTitle);
  83.  
  84.     /* Change window's title */
  85.     if (!windowTitle)
  86.     window->Title = NULL;
  87.     else if (windowTitle != (UBYTE *)~0L)
  88.     window->Title = windowTitle;
  89.  
  90.     /* Change screen's title */
  91.     if (!screenTitle)
  92.     window->ScreenTitle = NULL;
  93.     else if (screenTitle != (UBYTE *)~0L)
  94.     window->ScreenTitle = screenTitle;
  95.  
  96.     AROS_LIBFUNC_EXIT
  97. } /* SetWindowTitles */
  98.