home *** CD-ROM | disk | FTP | other *** search
/ Big Green CD 8 / BGCD_8_Dev.iso / NEXTSTEP / Utilities / FileSpy-1.1-MIHS / cInfo.m next >
Encoding:
Text File  |  1996-04-12  |  2.2 KB  |  84 lines

  1. /*
  2.  *   This sourcecode is part of FileSpy, a logfile observing utility.
  3.  *   Copyright (C) 1996  Felix Rauch
  4.  *
  5.  *   This program is free software; you can redistribute it and/or modify
  6.  *   it under the terms of the GNU General Public License as published by
  7.  *   the Free Software Foundation; either version 2 of the License, or
  8.  *   (at your option) any later version.
  9.  *   
  10.  *   Notice that this program may not be possessed, used, copied,
  11.  *   distributed or modified by people having to do with nuclear
  12.  *   weapons. See the file CONDITIONS for details.
  13.  *
  14.  *   This program is distributed in the hope that it will be useful,
  15.  *   but WITHOUT ANY WARRANTY; without even the implied warranty of
  16.  *   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
  17.  *   GNU General Public License for more details.
  18.  *
  19.  *   You should have received a copy of the GNU General Public License
  20.  *   along with this program; if not, write to the Free Software
  21.  *   Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
  22.  *
  23.  *   To contact the original author, try:
  24.  *   e-mail: Felix.Rauch@nice.ch
  25.  *   Traditional mail:    Felix Rauch
  26.  *            Sempacherstrasse 33
  27.  *            8032 Zurich
  28.  *            Switzerland
  29.  */
  30.  
  31. #import "Controller.h"
  32.  
  33. @implementation Controller(Info)
  34.  
  35. - loadInfo
  36. {
  37.     if(!infoPanel) {
  38. #ifdef DEBUG
  39.     char tmpStr[strlen(versionString) + 1];
  40. #endif
  41.     if(![NXApp loadNibSection:"Info.nib" owner:self withNames:NO fromZone:[self zone]]) {
  42.         NXLogError("Can't find Info.nib!");
  43.     }
  44. #ifdef DEBUG
  45.     strcpy(tmpStr, versionString);
  46.     strcat(tmpStr, "D");
  47.     [versionTextField setStringValue:tmpStr];
  48. #else
  49.     [versionTextField setStringValue:versionString];
  50. #endif
  51.     }
  52.     return self;
  53. }
  54.  
  55. - showInfo:sender    // loads and shows infopanel. if we're debuging, append "D" to version-number-string
  56. {
  57.     [self loadInfo];
  58.     [infoPanel makeKeyAndOrderFront:sender];
  59.     return self;
  60. }
  61.  
  62. - showConditions:sender
  63. {
  64.     [self loadInfo];
  65.     [conditionsWindow makeKeyAndOrderFront:sender];
  66.     return self;
  67. }
  68.  
  69. - showCopying:sender
  70. {
  71.     [self loadInfo];
  72.     [copyingWindow makeKeyAndOrderFront:sender];
  73.     return self;
  74. }
  75.  
  76. - showHelp:sender
  77. {
  78.     [self loadInfo];
  79.     [helpWindow makeKeyAndOrderFront:sender];
  80.     return self;
  81. }
  82.  
  83. @end
  84.