194
|
1 |
Object subclass:#SmalltalkAppletStub
|
|
2 |
instanceVariableNames:'parameter documentBase codeBase appletContext'
|
|
3 |
classVariableNames:''
|
|
4 |
poolDictionaries:''
|
234
|
5 |
category:'Java-Views-Support'
|
194
|
6 |
!
|
|
7 |
|
|
8 |
|
|
9 |
!SmalltalkAppletStub methodsFor:'accessing'!
|
|
10 |
|
|
11 |
appletContext
|
|
12 |
"return the value of the instance variable 'appletContext' (automatically generated)"
|
|
13 |
|
|
14 |
^ appletContext
|
|
15 |
|
|
16 |
"Created: 1.8.1997 / 15:56:20 / cg"
|
|
17 |
!
|
|
18 |
|
|
19 |
appletContext:something
|
|
20 |
"set the value of the instance variable 'appletContext' (automatically generated)"
|
|
21 |
|
|
22 |
appletContext := something.
|
|
23 |
|
|
24 |
"Created: 1.8.1997 / 15:56:20 / cg"
|
|
25 |
!
|
|
26 |
|
|
27 |
codeBase
|
|
28 |
"return the value of the instance variable 'codeBase' (automatically generated)"
|
|
29 |
|
|
30 |
^ codeBase
|
|
31 |
|
|
32 |
"Created: 1.8.1997 / 15:56:20 / cg"
|
|
33 |
!
|
|
34 |
|
|
35 |
codeBase:something
|
|
36 |
"set the value of the instance variable 'codeBase' (automatically generated)"
|
|
37 |
|
|
38 |
codeBase := something.
|
|
39 |
|
|
40 |
"Created: 1.8.1997 / 15:56:20 / cg"
|
|
41 |
!
|
|
42 |
|
|
43 |
documentBase
|
|
44 |
"return the value of the instance variable 'documentBase' (automatically generated)"
|
|
45 |
|
|
46 |
^ documentBase
|
|
47 |
|
|
48 |
"Created: 1.8.1997 / 15:56:20 / cg"
|
|
49 |
!
|
|
50 |
|
|
51 |
documentBase:something
|
|
52 |
"set the value of the instance variable 'documentBase' (automatically generated)"
|
|
53 |
|
|
54 |
documentBase := something.
|
|
55 |
|
|
56 |
"Created: 1.8.1997 / 15:56:20 / cg"
|
|
57 |
!
|
|
58 |
|
|
59 |
parameter
|
|
60 |
"return the value of the instance variable 'parameter' (automatically generated)"
|
|
61 |
|
|
62 |
^ parameter
|
|
63 |
|
|
64 |
"Created: 1.8.1997 / 15:56:19 / cg"
|
|
65 |
!
|
|
66 |
|
|
67 |
parameter:something
|
|
68 |
"set the value of the instance variable 'parameter' (automatically generated)"
|
|
69 |
|
|
70 |
parameter := something.
|
|
71 |
|
|
72 |
"Created: 1.8.1997 / 15:56:20 / cg"
|
|
73 |
! !
|
|
74 |
|
217
|
75 |
!SmalltalkAppletStub methodsFor:'applet actions'!
|
|
76 |
|
|
77 |
appletResize:newWidth _:newHeight
|
|
78 |
self halt.
|
|
79 |
|
|
80 |
"Created: 13.8.1997 / 00:18:41 / cg"
|
|
81 |
! !
|
|
82 |
|
194
|
83 |
!SmalltalkAppletStub methodsFor:'java accessing'!
|
|
84 |
|
255
|
85 |
doesNotUnderstand:aMessage
|
259
|
86 |
|selector base|
|
255
|
87 |
|
|
88 |
selector := aMessage selector.
|
|
89 |
selector == #'getParameter(Ljava/lang/String;)Ljava/lang/String;' ifTrue:[
|
|
90 |
^ self getParameter:(aMessage arguments at:1)
|
|
91 |
].
|
|
92 |
selector == #'getAppletContext()Ljava/applet/AppletContext;' ifTrue:[
|
|
93 |
^ self getAppletContext
|
|
94 |
].
|
259
|
95 |
selector == #'getCodeBase()Ljava/net/URL;' ifTrue:[
|
|
96 |
^ self getCodeBase.
|
|
97 |
].
|
255
|
98 |
selector == #'appletResize(II)V' ifTrue:[
|
|
99 |
self appletResize:(aMessage arguments at:1) _:(aMessage arguments at:2).
|
|
100 |
^ nil "/ void
|
|
101 |
].
|
|
102 |
^ super doesNotUnderstand:aMessage
|
|
103 |
|
|
104 |
"Created: / 7.1.1998 / 17:13:11 / cg"
|
259
|
105 |
"Modified: / 12.1.1998 / 23:50:40 / cg"
|
255
|
106 |
!
|
|
107 |
|
194
|
108 |
getAppletContext
|
|
109 |
^ appletContext
|
|
110 |
|
|
111 |
"Created: 1.8.1997 / 15:57:20 / cg"
|
|
112 |
!
|
|
113 |
|
|
114 |
getCodeBase
|
|
115 |
^ codeBase
|
|
116 |
|
|
117 |
"Created: 1.8.1997 / 15:57:11 / cg"
|
|
118 |
!
|
|
119 |
|
|
120 |
getDocumentBase
|
|
121 |
^ documentBase
|
|
122 |
|
|
123 |
"Created: 1.8.1997 / 15:57:05 / cg"
|
|
124 |
!
|
|
125 |
|
|
126 |
getParameter:arg
|
217
|
127 |
|s|
|
|
128 |
|
203
|
129 |
(parameter includesKey:arg) ifFalse:[
|
217
|
130 |
"/ self halt:'no parameter for: ' , arg displayString.
|
218
|
131 |
^ nil.
|
|
132 |
|
217
|
133 |
s := Dialog request:('applet wants parameter for ' , (Java as_ST_String:arg)).
|
|
134 |
^ Java as_String:s.
|
203
|
135 |
].
|
194
|
136 |
^ parameter at:arg ifAbsent:nil
|
|
137 |
|
|
138 |
"Created: 1.8.1997 / 15:56:51 / cg"
|
218
|
139 |
"Modified: 14.8.1997 / 01:28:56 / cg"
|
194
|
140 |
! !
|
|
141 |
|
|
142 |
!SmalltalkAppletStub class methodsFor:'documentation'!
|
|
143 |
|
|
144 |
version
|
259
|
145 |
^ '$Header: /home/jv/Projects/SmalltalkX/repositories/cvs/stx/libjava/SmalltalkAppletStub.st,v 1.7 1998/01/12 22:57:46 cg Exp $'
|
194
|
146 |
! !
|