0
|
1 |
"
|
6
|
2 |
COPYRIGHT (c) 1989 by Claus Gittinger
|
90
|
3 |
All Rights Reserved
|
0
|
4 |
|
|
5 |
This software is furnished under a license and may be used
|
|
6 |
only in accordance with the terms of that license and with the
|
|
7 |
inclusion of the above copyright notice. This software may not
|
|
8 |
be provided or otherwise made available to, or used by, any
|
|
9 |
other person. No title to or ownership of the software is
|
|
10 |
hereby transferred.
|
|
11 |
"
|
|
12 |
|
|
13 |
Object subclass:#Workstation
|
|
14 |
instanceVariableNames:''
|
|
15 |
classVariableNames:''
|
|
16 |
poolDictionaries:''
|
|
17 |
category:'Interface-Graphics'
|
|
18 |
!
|
|
19 |
|
|
20 |
Workstation comment:'
|
6
|
21 |
COPYRIGHT (c) 1989 by Claus Gittinger
|
90
|
22 |
All Rights Reserved
|
54
|
23 |
|
135
|
24 |
$Header: /cvs/stx/stx/libview/Attic/Workstation.st,v 1.12 1995-05-03 00:26:48 claus Exp $
|
0
|
25 |
'!
|
|
26 |
|
|
27 |
Smalltalk at:#Display put:nil!
|
|
28 |
|
46
|
29 |
!Workstation class methodsFor:'documentation'!
|
|
30 |
|
|
31 |
copyright
|
|
32 |
"
|
|
33 |
COPYRIGHT (c) 1989 by Claus Gittinger
|
90
|
34 |
All Rights Reserved
|
46
|
35 |
|
|
36 |
This software is furnished under a license and may be used
|
|
37 |
only in accordance with the terms of that license and with the
|
|
38 |
inclusion of the above copyright notice. This software may not
|
|
39 |
be provided or otherwise made available to, or used by, any
|
|
40 |
other person. No title to or ownership of the software is
|
|
41 |
hereby transferred.
|
|
42 |
"
|
|
43 |
!
|
|
44 |
|
|
45 |
version
|
|
46 |
"
|
135
|
47 |
$Header: /cvs/stx/stx/libview/Attic/Workstation.st,v 1.12 1995-05-03 00:26:48 claus Exp $
|
46
|
48 |
"
|
|
49 |
!
|
|
50 |
|
|
51 |
documentation
|
|
52 |
"
|
|
53 |
this class is only here, to get an instance of XWorkstation
|
|
54 |
named Display - this cannot be done in XWorkstation since Display
|
|
55 |
is defined in X.h/Xlib.h -- sigh
|
|
56 |
"
|
|
57 |
! !
|
|
58 |
|
0
|
59 |
!Workstation class methodsFor:'initialization'!
|
|
60 |
|
|
61 |
initialize
|
104
|
62 |
|workstationType|
|
0
|
63 |
|
|
64 |
"initialize the default display - this must be done only once"
|
|
65 |
|
|
66 |
Display isNil ifTrue:[
|
90
|
67 |
GLXWorkstation notNil ifTrue:[
|
|
68 |
workstationType := GLXWorkstation.
|
|
69 |
] ifFalse:[
|
|
70 |
workstationType := XWorkstation
|
|
71 |
].
|
72
|
72 |
|
90
|
73 |
workstationType notNil ifTrue:[
|
|
74 |
"make sure its initialized ..."
|
|
75 |
workstationType initialize.
|
0
|
76 |
|
90
|
77 |
"set the corresponding classes ..."
|
12
|
78 |
|
90
|
79 |
Display := workstationType basicNew initializeFor:nil.
|
|
80 |
Display notNil ifTrue:[
|
|
81 |
DisplayRootView initialize.
|
|
82 |
]
|
135
|
83 |
].
|
|
84 |
|
|
85 |
"
|
|
86 |
preparation for NeXTStep interfacing;
|
|
87 |
(but if X is linked in, this will be our default Display)
|
|
88 |
"
|
|
89 |
NeXTWorkstation notNil ifTrue:[
|
|
90 |
NeXTWorkstation initialize.
|
|
91 |
|
|
92 |
Display isNil ifTrue:[
|
90
|
93 |
Display := NeXTWorkstation basicNew initialize.
|
|
94 |
]
|
135
|
95 |
].
|
|
96 |
OS2Workstation notNil ifTrue:[
|
|
97 |
OS2Workstation initialize.
|
|
98 |
|
|
99 |
Display isNil ifTrue:[
|
|
100 |
Display := OS2Workstation basicNew initialize.
|
|
101 |
]
|
|
102 |
].
|
|
103 |
Win32Workstation notNil ifTrue:[
|
|
104 |
Win32Workstation initialize.
|
|
105 |
|
|
106 |
Display isNil ifTrue:[
|
|
107 |
Display := Win32Workstation basicNew initialize.
|
|
108 |
]
|
90
|
109 |
]
|
0
|
110 |
]
|
|
111 |
!
|
|
112 |
|
|
113 |
reinitialize
|
|
114 |
"reinitialize after a snapin"
|
|
115 |
|
|
116 |
Display notNil ifTrue:[
|
90
|
117 |
Display reinitialize.
|
0
|
118 |
]
|
|
119 |
! !
|