File: setup.h

package info (click to toggle)
cgoban 1.9.14-18
  • links: PTS
  • area: main
  • in suites: bullseye, buster, sid, stretch
  • size: 3,448 kB
  • sloc: ansic: 36,037; sh: 707; makefile: 259
file content (59 lines) | stat: -rw-r--r-- 1,444 bytes parent folder | download | duplicates (12)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
/*
 * src/gmp/setup.h, part of Complete Goban (game program)
 * Copyright (C) 1995 William Shubert.
 * See "configure.h.in" for more copyright information.
 */


#ifndef  _GMP_SETUP_H_
#define  _GMP_SETUP_H_  1


/**********************************************************************
 * Data types
 **********************************************************************/

typedef enum  {
  gmpSetup_program, gmpSetup_device, gmpSetup_human, gmpSetup_nngs,
  gmpSetup_igs, gmpSetup_local, gmpSetup_remote
} GmpSetupType;


typedef struct  GmpSetupPlayer_struct  {
  GmpSetupType  type;
  ClpEntry  *optionEntry, *progNameEntry, *devNameEntry;
  Str  progName, devName;
  But  *box;
  But  *typeMenu;
  But  *strDesc1, *strIn1;
  But  *strDesc2, *strIn2;
} GmpSetupPlayer;


typedef struct GmpSetup_struct  {
  Cgoban  *cg;

  /* TRUE if you are waiting for a callback from gameSetup. */
  bool  gameWaiting;

  ButWin  *win;
  But  *bg;
  But  *title;
  But  *ok, *help, *cancel;

  GmpSetupPlayer  players[2];

  MAGIC_STRUCT
} GmpSetup;


/**********************************************************************
 * Functions
 **********************************************************************/
extern GmpSetup  *gmpSetup_create(Cgoban *cg);
extern void  gmpSetup_destroy(GmpSetup *gs);
extern int  gmp_forkProgram(Cgoban *cg, int *inFile, int *outFile,
			    const char *progName, int mainTime, int byTime);


#endif  /* _GMP_SETUP_H_ */