home *** CD-ROM | disk | FTP | other *** search
/ Collection of Internet / Collection of Internet.iso / msdos / lynx / source / doslynx / src / turlvi27.cpp < prev    next >
Encoding:
C/C++ Source or Header  |  1994-10-25  |  1.1 KB  |  34 lines

  1. //    Copyright (c) 1994, University of Kansas, All Rights Reserved
  2. //
  3. //    Class:        TURLView
  4. //    Include File:    turlview.h
  5. //    Purpose:    Provide a view for any URL
  6. //    Remarks/Portability/Dependencies/Restrictions:
  7. //    Revision History:
  8. //        04-06-93    created
  9. #include"turlview.h"
  10. #include"trace.h"
  11. #include<string.h>
  12.  
  13. void TURLView::isImage(const char *cp_imagefile)    {
  14. //    Purpose:    Inform the view that there is an image and not any
  15. //            displayable text.  We will save the image name and
  16. //            displaying of the image will be handled in the
  17. //            constructor.
  18. //    Arguments:    cp_imagefile    The path of the file containing the
  19. //                    image to display.
  20. //    Return Value:    void
  21. //    Remarks/Portability/Dependencies/Restrictions:
  22. //        Really does noting but save the name of the image by
  23. //        allocation.  Other code will free the name once we are done
  24. //        with it.
  25. //    Revision History:
  26. //        04-06-93    created
  27.  
  28.     //    Just copy the name.
  29.     cp_imagename = new char[strlen(cp_imagefile) + 1];
  30.     strcpy(cp_imagename, cp_imagefile);
  31. #ifndef RELEASE
  32.     trace("Image file " << cp_imagename << " registered for display.");
  33. #endif // RELEASE
  34. }