summaryrefslogtreecommitdiffstats
path: root/private/os2/inc/sesgrp.h
blob: 4ca436494b0e4b2dcd8b229976177f8d6358fda9 (plain) (blame)
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
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
/*++

Copyright (c) 1990  Microsoft Corporation

Module Name:

    sesgrp.h

Abstract:

    This module defines the OS/2 subsystem memory view of Session-Group

Author:

    Michael Jarus (mjarus) 20-Nov-1991

Revision History:

--*/


/*
 *  This file defines the SesGrp : a section, which holds all common
 *  parameters for the entire session (SES_GROUP).
 *
 *  It's initilized to zero by the os2srv (which also init the NLS and
 *  some other parameters).
 *
 *  Parameters can be put into SesGrp in os2ses/client only after it
 *  gets the section from the os2srv (after ntinitss.CtrlListen is called).
 */

typedef struct _OS2_SES_GROUP_PARMS
{
    USHORT      FirstProcess;
    ULONG       InTermination;

    HANDLE      LockProcess;
    ULONG       PrinterMonitor;
    ULONG       OutputModeFlags;    // Console Output Mode
    ULONG       DefaultWinOutputMode;   // Default Win Console Input Mode
    ULONG       WinProcessNumberInSession;
    ULONG       WinSyncProcessNumberInSession;

    /*
     *  handles (and flags) for in/out/Std,
     */

    HANDLE      hConsoleInput;
    HANDLE      hConsoleOutput;
    HANDLE      StdIn;
    HANDLE      StdOut;
    HANDLE      StdErr;
    USHORT      StdInFlag;          // TRUE if console (not redirected)
    USHORT      StdOutFlag;
    USHORT      StdErrFlag;
    USHORT      StdInFileType;      // FileType for HandleTable
    USHORT      StdOutFileType;
    USHORT      StdErrFileType;
    USHORT      StdInHandleCount;   // Count of open handle
    USHORT      StdOutHandleCount;
    USHORT      StdErrHandleCount;

    /*
     *  VIO Parameters
     */

    ULONG       PauseScreenUpdate;
    USHORT      BytesPerCell;
    USHORT      VioLengthMask;
    WCHAR       WinSpaceChar;
    WCHAR       WinBlankChar;
    VIOMODEINFO Os2ModeInfo;
    SHORT       MinRowNum;
    SMALL_RECT  ScreenRect;         // Screen Rect for WriteConsoleOutput
    VIOCURSORINFO CursorInfo;       // Cursor Info
    SHORT       ScreenColNum;       // col number
    SHORT       ScreenRowNum;       // row number
    ULONG       ScreenSize;         // screen size in bytes
    SHORT       CellHSize;          // Horizontal Cell size
    SHORT       CellVSize;          // Vertical Cell size
    USHORT      VioLength2CellShift;
    ULONG       dwWinCursorSize;
    BOOLEAN     bWinCursorVisible;

    /*
     *  TTY Parameters
     */

    ULONG       AnsiMode;           // state of AnsiFlag
    UCHAR       AnsiCellAttr[3];    // attribute of TTY (3 bytes for MSKK)
    UCHAR       ansi_base;
    UCHAR       ansi_foreground;
    UCHAR       ansi_background;
    UCHAR       ansi_reverse;
    UCHAR       ansi_bold;
    UCHAR       ansi_cancel;
    UCHAR       ansi_faint;
    UCHAR       ansi_italic;
    UCHAR       ansi_blink;
    UCHAR       ansi_blue;
    COORD       WinCoord;
    USHORT      WinAttr;

    /*
     *  LVB Parameters
     */

    ULONG       MaxLVBsize;
    ULONG       LVBsize;
    BOOLEAN     LVBOn;

    /*
     *  POPUP Parameters
     */

    HANDLE      hConsolePopUp;
    HANDLE      PopUpProcess;
    USHORT      PopUpFlag;

    /*
     *  Kbd parameters
     */

    ULONG       KbdInFocus;
    PVOID       PhyKbd;
    ULONG       KeysOnFlag;
    ULONG       KeyboardCountry;
    ULONG       KeyboardType;
    USHORT      NoKbdFocus;
    USHORT      ModeFlag;           //  0 - ASCII, 1 - Binary

    /*
     *  NLS definitions.
     *  If you add anything or change the order, do it also in server\srvnls.c
     */

    ULONG       Os2srvUseRegisterInfo;  // set when NLS parms are from the registry
                                        // reset when they are inherit from Win32
    ULONG       Win32CountryCode;       // Win32 NLS parms: country code
    ULONG       Win32OEMCP;             //                  OEM CP
    ULONG       Win32ACP;               //                  ACP
    ULONG       Win32LANGID;            //                  LANGID
    ULONG       Win32LCID;              //                  LCID
    ULONG       CountryCode;            // Os2ss NLS parms: country code
    ULONG       DosCP;                  //                  Dos CP
    ULONG       PrimaryCP;              //                  Primary CP
    ULONG       SecondaryCP;            //                  Secondary CP
    ULONG       VioCP;                  //                  Vio CP
    ULONG       KbdCP;                  //                  Kbd CP
    ULONG       Os2ssLCID;              //                  LCID
    ULONG       LanguageID;             //                  message file LanguageID
    UCHAR       KeyboardLayout[2];      //                  Keyboard Layout
#if PMNT
    UCHAR       KeyboardName[4];        //                  Keyboard Name
#endif // PMNT
    OD2_DBCS_VECTOR_ENTRY   PriDBCSVec;
    OD2_DBCS_VECTOR_ENTRY   SecDBCSVec;
    UCHAR       PriCollateTable[256];   //                  Primary Collate Table
    UCHAR       SecCollateTable[256];   //                  Secondary Collate Table
    UCHAR       PriCaseMapTable[256];   //                  Primary Case Map Table
    UCHAR       SecCaseMapTable[256];   //                  Secondary Case Map Table
    COUNTRYINFO CountryInfo;            //                  Country Info
    ULONG       DBCSCountryFlag;        //
    UCHAR       SystemDirectory[CCHMAXSYSTEMPATH];

    /*
     *  End of NLS definitions.
     */

} OS2_SES_GROUP_PARMS, *POS2_SES_GROUP_PARMS;

    /*
     *  KeyboardType
     */

#define OS2SS_EN_KBD 0
#define OS2SS_AT_KBD 1
#define OS2SS_ENNEW_KBD 2