| 1 | n/a | """Suite WorldWideWeb suite, as defined in Spyglass spec.: |
|---|
| 2 | n/a | Level 1, version 1 |
|---|
| 3 | n/a | |
|---|
| 4 | n/a | Generated from /Volumes/Sap/Applications (Mac OS 9)/Netscape Communicator\xe2\x84\xa2 Folder/Netscape Communicator\xe2\x84\xa2 |
|---|
| 5 | n/a | AETE/AEUT resource version 1/0, language 0, script 0 |
|---|
| 6 | n/a | """ |
|---|
| 7 | n/a | |
|---|
| 8 | n/a | import aetools |
|---|
| 9 | n/a | import MacOS |
|---|
| 10 | n/a | |
|---|
| 11 | n/a | _code = 'WWW!' |
|---|
| 12 | n/a | |
|---|
| 13 | n/a | class WorldWideWeb_suite_Events: |
|---|
| 14 | n/a | |
|---|
| 15 | n/a | _argmap_OpenURL = { |
|---|
| 16 | n/a | 'to' : 'INTO', |
|---|
| 17 | n/a | 'toWindow' : 'WIND', |
|---|
| 18 | n/a | 'flags' : 'FLGS', |
|---|
| 19 | n/a | 'post_data' : 'POST', |
|---|
| 20 | n/a | 'post_type' : 'MIME', |
|---|
| 21 | n/a | 'progressApp' : 'PROG', |
|---|
| 22 | n/a | } |
|---|
| 23 | n/a | |
|---|
| 24 | n/a | def OpenURL(self, _object, _attributes={}, **_arguments): |
|---|
| 25 | n/a | """OpenURL: Opens a URL. Allows for more options than GetURL event |
|---|
| 26 | n/a | Required argument: URL |
|---|
| 27 | n/a | Keyword argument to: file destination |
|---|
| 28 | n/a | Keyword argument toWindow: window iD |
|---|
| 29 | n/a | Keyword argument flags: Binary: any combination of 1, 2 and 4 is allowed: 1 and 2 mean force reload the document. 4 is ignored |
|---|
| 30 | n/a | Keyword argument post_data: Form posting data |
|---|
| 31 | n/a | Keyword argument post_type: MIME type of the posting data. Defaults to application/x-www-form-urlencoded |
|---|
| 32 | n/a | Keyword argument progressApp: Application that will display progress |
|---|
| 33 | n/a | Keyword argument _attributes: AppleEvent attribute dictionary |
|---|
| 34 | n/a | Returns: ID of the loading window |
|---|
| 35 | n/a | """ |
|---|
| 36 | n/a | _code = 'WWW!' |
|---|
| 37 | n/a | _subcode = 'OURL' |
|---|
| 38 | n/a | |
|---|
| 39 | n/a | aetools.keysubst(_arguments, self._argmap_OpenURL) |
|---|
| 40 | n/a | _arguments['----'] = _object |
|---|
| 41 | n/a | |
|---|
| 42 | n/a | |
|---|
| 43 | n/a | _reply, _arguments, _attributes = self.send(_code, _subcode, |
|---|
| 44 | n/a | _arguments, _attributes) |
|---|
| 45 | n/a | if _arguments.get('errn', 0): |
|---|
| 46 | n/a | raise aetools.Error, aetools.decodeerror(_arguments) |
|---|
| 47 | n/a | # XXXX Optionally decode result |
|---|
| 48 | n/a | if _arguments.has_key('----'): |
|---|
| 49 | n/a | return _arguments['----'] |
|---|
| 50 | n/a | |
|---|
| 51 | n/a | _argmap_ShowFile = { |
|---|
| 52 | n/a | 'MIME_type' : 'MIME', |
|---|
| 53 | n/a | 'Window_ID' : 'WIND', |
|---|
| 54 | n/a | 'URL' : 'URL ', |
|---|
| 55 | n/a | } |
|---|
| 56 | n/a | |
|---|
| 57 | n/a | def ShowFile(self, _object, _attributes={}, **_arguments): |
|---|
| 58 | n/a | """ShowFile: Similar to OpenDocuments, except that it specifies the parent URL, and MIME type of the file |
|---|
| 59 | n/a | Required argument: File to open |
|---|
| 60 | n/a | Keyword argument MIME_type: MIME type |
|---|
| 61 | n/a | Keyword argument Window_ID: Window to open the file in |
|---|
| 62 | n/a | Keyword argument URL: Use this as a base URL |
|---|
| 63 | n/a | Keyword argument _attributes: AppleEvent attribute dictionary |
|---|
| 64 | n/a | Returns: Window ID of the loaded window. 0 means ShowFile failed, FFFFFFF means that data was not appropriate type to display in the browser. |
|---|
| 65 | n/a | """ |
|---|
| 66 | n/a | _code = 'WWW!' |
|---|
| 67 | n/a | _subcode = 'SHWF' |
|---|
| 68 | n/a | |
|---|
| 69 | n/a | aetools.keysubst(_arguments, self._argmap_ShowFile) |
|---|
| 70 | n/a | _arguments['----'] = _object |
|---|
| 71 | n/a | |
|---|
| 72 | n/a | |
|---|
| 73 | n/a | _reply, _arguments, _attributes = self.send(_code, _subcode, |
|---|
| 74 | n/a | _arguments, _attributes) |
|---|
| 75 | n/a | if _arguments.get('errn', 0): |
|---|
| 76 | n/a | raise aetools.Error, aetools.decodeerror(_arguments) |
|---|
| 77 | n/a | # XXXX Optionally decode result |
|---|
| 78 | n/a | if _arguments.has_key('----'): |
|---|
| 79 | n/a | return _arguments['----'] |
|---|
| 80 | n/a | |
|---|
| 81 | n/a | _argmap_cancel_progress = { |
|---|
| 82 | n/a | 'in_window' : 'WIND', |
|---|
| 83 | n/a | } |
|---|
| 84 | n/a | |
|---|
| 85 | n/a | def cancel_progress(self, _object=None, _attributes={}, **_arguments): |
|---|
| 86 | n/a | """cancel progress: Interrupts the download of the document in the given window |
|---|
| 87 | n/a | Required argument: progress ID, obtained from the progress app |
|---|
| 88 | n/a | Keyword argument in_window: window ID of the progress to cancel |
|---|
| 89 | n/a | Keyword argument _attributes: AppleEvent attribute dictionary |
|---|
| 90 | n/a | """ |
|---|
| 91 | n/a | _code = 'WWW!' |
|---|
| 92 | n/a | _subcode = 'CNCL' |
|---|
| 93 | n/a | |
|---|
| 94 | n/a | aetools.keysubst(_arguments, self._argmap_cancel_progress) |
|---|
| 95 | n/a | _arguments['----'] = _object |
|---|
| 96 | n/a | |
|---|
| 97 | n/a | |
|---|
| 98 | n/a | _reply, _arguments, _attributes = self.send(_code, _subcode, |
|---|
| 99 | n/a | _arguments, _attributes) |
|---|
| 100 | n/a | if _arguments.get('errn', 0): |
|---|
| 101 | n/a | raise aetools.Error, aetools.decodeerror(_arguments) |
|---|
| 102 | n/a | # XXXX Optionally decode result |
|---|
| 103 | n/a | if _arguments.has_key('----'): |
|---|
| 104 | n/a | return _arguments['----'] |
|---|
| 105 | n/a | |
|---|
| 106 | n/a | def find_URL(self, _object, _attributes={}, **_arguments): |
|---|
| 107 | n/a | """find URL: If the file was downloaded by Netscape, you can call FindURL to find out the URL used to download the file. |
|---|
| 108 | n/a | Required argument: File spec |
|---|
| 109 | n/a | Keyword argument _attributes: AppleEvent attribute dictionary |
|---|
| 110 | n/a | Returns: The URL |
|---|
| 111 | n/a | """ |
|---|
| 112 | n/a | _code = 'WWW!' |
|---|
| 113 | n/a | _subcode = 'FURL' |
|---|
| 114 | n/a | |
|---|
| 115 | n/a | if _arguments: raise TypeError, 'No optional args expected' |
|---|
| 116 | n/a | _arguments['----'] = _object |
|---|
| 117 | n/a | |
|---|
| 118 | n/a | |
|---|
| 119 | n/a | _reply, _arguments, _attributes = self.send(_code, _subcode, |
|---|
| 120 | n/a | _arguments, _attributes) |
|---|
| 121 | n/a | if _arguments.get('errn', 0): |
|---|
| 122 | n/a | raise aetools.Error, aetools.decodeerror(_arguments) |
|---|
| 123 | n/a | # XXXX Optionally decode result |
|---|
| 124 | n/a | if _arguments.has_key('----'): |
|---|
| 125 | n/a | return _arguments['----'] |
|---|
| 126 | n/a | |
|---|
| 127 | n/a | def get_window_info(self, _object=None, _attributes={}, **_arguments): |
|---|
| 128 | n/a | """get window info: Returns the information about the window as a list. Currently the list contains the window title and the URL. You can get the same information using standard Apple Event GetProperty. |
|---|
| 129 | n/a | Required argument: window ID |
|---|
| 130 | n/a | Keyword argument _attributes: AppleEvent attribute dictionary |
|---|
| 131 | n/a | Returns: undocumented, typecode 'list' |
|---|
| 132 | n/a | """ |
|---|
| 133 | n/a | _code = 'WWW!' |
|---|
| 134 | n/a | _subcode = 'WNFO' |
|---|
| 135 | n/a | |
|---|
| 136 | n/a | if _arguments: raise TypeError, 'No optional args expected' |
|---|
| 137 | n/a | _arguments['----'] = _object |
|---|
| 138 | n/a | |
|---|
| 139 | n/a | |
|---|
| 140 | n/a | _reply, _arguments, _attributes = self.send(_code, _subcode, |
|---|
| 141 | n/a | _arguments, _attributes) |
|---|
| 142 | n/a | if _arguments.get('errn', 0): |
|---|
| 143 | n/a | raise aetools.Error, aetools.decodeerror(_arguments) |
|---|
| 144 | n/a | # XXXX Optionally decode result |
|---|
| 145 | n/a | if _arguments.has_key('----'): |
|---|
| 146 | n/a | return _arguments['----'] |
|---|
| 147 | n/a | |
|---|
| 148 | n/a | def list_windows(self, _no_object=None, _attributes={}, **_arguments): |
|---|
| 149 | n/a | """list windows: Lists the IDs of all the hypertext windows |
|---|
| 150 | n/a | Keyword argument _attributes: AppleEvent attribute dictionary |
|---|
| 151 | n/a | Returns: List of unique IDs of all the hypertext windows |
|---|
| 152 | n/a | """ |
|---|
| 153 | n/a | _code = 'WWW!' |
|---|
| 154 | n/a | _subcode = 'LSTW' |
|---|
| 155 | n/a | |
|---|
| 156 | n/a | if _arguments: raise TypeError, 'No optional args expected' |
|---|
| 157 | n/a | if _no_object is not None: raise TypeError, 'No direct arg expected' |
|---|
| 158 | n/a | |
|---|
| 159 | n/a | |
|---|
| 160 | n/a | _reply, _arguments, _attributes = self.send(_code, _subcode, |
|---|
| 161 | n/a | _arguments, _attributes) |
|---|
| 162 | n/a | if _arguments.get('errn', 0): |
|---|
| 163 | n/a | raise aetools.Error, aetools.decodeerror(_arguments) |
|---|
| 164 | n/a | # XXXX Optionally decode result |
|---|
| 165 | n/a | if _arguments.has_key('----'): |
|---|
| 166 | n/a | return _arguments['----'] |
|---|
| 167 | n/a | |
|---|
| 168 | n/a | _argmap_parse_anchor = { |
|---|
| 169 | n/a | 'relative_to' : 'RELA', |
|---|
| 170 | n/a | } |
|---|
| 171 | n/a | |
|---|
| 172 | n/a | def parse_anchor(self, _object, _attributes={}, **_arguments): |
|---|
| 173 | n/a | """parse anchor: Resolves the relative URL |
|---|
| 174 | n/a | Required argument: Main URL |
|---|
| 175 | n/a | Keyword argument relative_to: Relative URL |
|---|
| 176 | n/a | Keyword argument _attributes: AppleEvent attribute dictionary |
|---|
| 177 | n/a | Returns: Parsed URL |
|---|
| 178 | n/a | """ |
|---|
| 179 | n/a | _code = 'WWW!' |
|---|
| 180 | n/a | _subcode = 'PRSA' |
|---|
| 181 | n/a | |
|---|
| 182 | n/a | aetools.keysubst(_arguments, self._argmap_parse_anchor) |
|---|
| 183 | n/a | _arguments['----'] = _object |
|---|
| 184 | n/a | |
|---|
| 185 | n/a | |
|---|
| 186 | n/a | _reply, _arguments, _attributes = self.send(_code, _subcode, |
|---|
| 187 | n/a | _arguments, _attributes) |
|---|
| 188 | n/a | if _arguments.get('errn', 0): |
|---|
| 189 | n/a | raise aetools.Error, aetools.decodeerror(_arguments) |
|---|
| 190 | n/a | # XXXX Optionally decode result |
|---|
| 191 | n/a | if _arguments.has_key('----'): |
|---|
| 192 | n/a | return _arguments['----'] |
|---|
| 193 | n/a | |
|---|
| 194 | n/a | def register_URL_echo(self, _object=None, _attributes={}, **_arguments): |
|---|
| 195 | n/a | """register URL echo: Registers the \xd2echo\xd3 application. Each download from now on will be echoed to this application. |
|---|
| 196 | n/a | Required argument: Application signature |
|---|
| 197 | n/a | Keyword argument _attributes: AppleEvent attribute dictionary |
|---|
| 198 | n/a | """ |
|---|
| 199 | n/a | _code = 'WWW!' |
|---|
| 200 | n/a | _subcode = 'RGUE' |
|---|
| 201 | n/a | |
|---|
| 202 | n/a | if _arguments: raise TypeError, 'No optional args expected' |
|---|
| 203 | n/a | _arguments['----'] = _object |
|---|
| 204 | n/a | |
|---|
| 205 | n/a | |
|---|
| 206 | n/a | _reply, _arguments, _attributes = self.send(_code, _subcode, |
|---|
| 207 | n/a | _arguments, _attributes) |
|---|
| 208 | n/a | if _arguments.get('errn', 0): |
|---|
| 209 | n/a | raise aetools.Error, aetools.decodeerror(_arguments) |
|---|
| 210 | n/a | # XXXX Optionally decode result |
|---|
| 211 | n/a | if _arguments.has_key('----'): |
|---|
| 212 | n/a | return _arguments['----'] |
|---|
| 213 | n/a | |
|---|
| 214 | n/a | _argmap_register_protocol = { |
|---|
| 215 | n/a | 'for_protocol' : 'PROT', |
|---|
| 216 | n/a | } |
|---|
| 217 | n/a | |
|---|
| 218 | n/a | def register_protocol(self, _object=None, _attributes={}, **_arguments): |
|---|
| 219 | n/a | """register protocol: Registers application as a \xd2handler\xd3 for this protocol with a given prefix. The handler will receive \xd2OpenURL\xd3, or if that fails, \xd2GetURL\xd3 event. |
|---|
| 220 | n/a | Required argument: Application sig |
|---|
| 221 | n/a | Keyword argument for_protocol: protocol prefix: \xd2finger:\xd3, \xd2file\xd3, |
|---|
| 222 | n/a | Keyword argument _attributes: AppleEvent attribute dictionary |
|---|
| 223 | n/a | Returns: TRUE if registration has been successful |
|---|
| 224 | n/a | """ |
|---|
| 225 | n/a | _code = 'WWW!' |
|---|
| 226 | n/a | _subcode = 'RGPR' |
|---|
| 227 | n/a | |
|---|
| 228 | n/a | aetools.keysubst(_arguments, self._argmap_register_protocol) |
|---|
| 229 | n/a | _arguments['----'] = _object |
|---|
| 230 | n/a | |
|---|
| 231 | n/a | |
|---|
| 232 | n/a | _reply, _arguments, _attributes = self.send(_code, _subcode, |
|---|
| 233 | n/a | _arguments, _attributes) |
|---|
| 234 | n/a | if _arguments.get('errn', 0): |
|---|
| 235 | n/a | raise aetools.Error, aetools.decodeerror(_arguments) |
|---|
| 236 | n/a | # XXXX Optionally decode result |
|---|
| 237 | n/a | if _arguments.has_key('----'): |
|---|
| 238 | n/a | return _arguments['----'] |
|---|
| 239 | n/a | |
|---|
| 240 | n/a | _argmap_register_viewer = { |
|---|
| 241 | n/a | 'MIME_type' : 'MIME', |
|---|
| 242 | n/a | 'with_file_type' : 'FTYP', |
|---|
| 243 | n/a | } |
|---|
| 244 | n/a | |
|---|
| 245 | n/a | def register_viewer(self, _object, _attributes={}, **_arguments): |
|---|
| 246 | n/a | """register viewer: Registers an application as a \xd4special\xd5 viewer for this MIME type. The application will be launched with ViewDoc events |
|---|
| 247 | n/a | Required argument: Application sig |
|---|
| 248 | n/a | Keyword argument MIME_type: MIME type viewer is registering for |
|---|
| 249 | n/a | Keyword argument with_file_type: Mac file type for the downloaded files |
|---|
| 250 | n/a | Keyword argument _attributes: AppleEvent attribute dictionary |
|---|
| 251 | n/a | Returns: TRUE if registration has been successful |
|---|
| 252 | n/a | """ |
|---|
| 253 | n/a | _code = 'WWW!' |
|---|
| 254 | n/a | _subcode = 'RGVW' |
|---|
| 255 | n/a | |
|---|
| 256 | n/a | aetools.keysubst(_arguments, self._argmap_register_viewer) |
|---|
| 257 | n/a | _arguments['----'] = _object |
|---|
| 258 | n/a | |
|---|
| 259 | n/a | |
|---|
| 260 | n/a | _reply, _arguments, _attributes = self.send(_code, _subcode, |
|---|
| 261 | n/a | _arguments, _attributes) |
|---|
| 262 | n/a | if _arguments.get('errn', 0): |
|---|
| 263 | n/a | raise aetools.Error, aetools.decodeerror(_arguments) |
|---|
| 264 | n/a | # XXXX Optionally decode result |
|---|
| 265 | n/a | if _arguments.has_key('----'): |
|---|
| 266 | n/a | return _arguments['----'] |
|---|
| 267 | n/a | |
|---|
| 268 | n/a | _argmap_register_window_close = { |
|---|
| 269 | n/a | 'for_window' : 'WIND', |
|---|
| 270 | n/a | } |
|---|
| 271 | n/a | |
|---|
| 272 | n/a | def register_window_close(self, _object=None, _attributes={}, **_arguments): |
|---|
| 273 | n/a | """register window close: Netscape will notify registered application when this window closes |
|---|
| 274 | n/a | Required argument: Application signature |
|---|
| 275 | n/a | Keyword argument for_window: window ID |
|---|
| 276 | n/a | Keyword argument _attributes: AppleEvent attribute dictionary |
|---|
| 277 | n/a | Returns: true if successful |
|---|
| 278 | n/a | """ |
|---|
| 279 | n/a | _code = 'WWW!' |
|---|
| 280 | n/a | _subcode = 'RGWC' |
|---|
| 281 | n/a | |
|---|
| 282 | n/a | aetools.keysubst(_arguments, self._argmap_register_window_close) |
|---|
| 283 | n/a | _arguments['----'] = _object |
|---|
| 284 | n/a | |
|---|
| 285 | n/a | |
|---|
| 286 | n/a | _reply, _arguments, _attributes = self.send(_code, _subcode, |
|---|
| 287 | n/a | _arguments, _attributes) |
|---|
| 288 | n/a | if _arguments.get('errn', 0): |
|---|
| 289 | n/a | raise aetools.Error, aetools.decodeerror(_arguments) |
|---|
| 290 | n/a | # XXXX Optionally decode result |
|---|
| 291 | n/a | if _arguments.has_key('----'): |
|---|
| 292 | n/a | return _arguments['----'] |
|---|
| 293 | n/a | |
|---|
| 294 | n/a | def unregister_URL_echo(self, _object, _attributes={}, **_arguments): |
|---|
| 295 | n/a | """unregister URL echo: cancels URL echo |
|---|
| 296 | n/a | Required argument: application signature |
|---|
| 297 | n/a | Keyword argument _attributes: AppleEvent attribute dictionary |
|---|
| 298 | n/a | """ |
|---|
| 299 | n/a | _code = 'WWW!' |
|---|
| 300 | n/a | _subcode = 'UNRU' |
|---|
| 301 | n/a | |
|---|
| 302 | n/a | if _arguments: raise TypeError, 'No optional args expected' |
|---|
| 303 | n/a | _arguments['----'] = _object |
|---|
| 304 | n/a | |
|---|
| 305 | n/a | |
|---|
| 306 | n/a | _reply, _arguments, _attributes = self.send(_code, _subcode, |
|---|
| 307 | n/a | _arguments, _attributes) |
|---|
| 308 | n/a | if _arguments.get('errn', 0): |
|---|
| 309 | n/a | raise aetools.Error, aetools.decodeerror(_arguments) |
|---|
| 310 | n/a | # XXXX Optionally decode result |
|---|
| 311 | n/a | if _arguments.has_key('----'): |
|---|
| 312 | n/a | return _arguments['----'] |
|---|
| 313 | n/a | |
|---|
| 314 | n/a | _argmap_unregister_protocol = { |
|---|
| 315 | n/a | 'for_protocol' : 'PROT', |
|---|
| 316 | n/a | } |
|---|
| 317 | n/a | |
|---|
| 318 | n/a | def unregister_protocol(self, _object=None, _attributes={}, **_arguments): |
|---|
| 319 | n/a | """unregister protocol: reverses the effects of \xd2register protocol\xd3 |
|---|
| 320 | n/a | Required argument: Application sig. |
|---|
| 321 | n/a | Keyword argument for_protocol: protocol prefix. If none, unregister for all protocols |
|---|
| 322 | n/a | Keyword argument _attributes: AppleEvent attribute dictionary |
|---|
| 323 | n/a | Returns: TRUE if successful |
|---|
| 324 | n/a | """ |
|---|
| 325 | n/a | _code = 'WWW!' |
|---|
| 326 | n/a | _subcode = 'UNRP' |
|---|
| 327 | n/a | |
|---|
| 328 | n/a | aetools.keysubst(_arguments, self._argmap_unregister_protocol) |
|---|
| 329 | n/a | _arguments['----'] = _object |
|---|
| 330 | n/a | |
|---|
| 331 | n/a | |
|---|
| 332 | n/a | _reply, _arguments, _attributes = self.send(_code, _subcode, |
|---|
| 333 | n/a | _arguments, _attributes) |
|---|
| 334 | n/a | if _arguments.get('errn', 0): |
|---|
| 335 | n/a | raise aetools.Error, aetools.decodeerror(_arguments) |
|---|
| 336 | n/a | # XXXX Optionally decode result |
|---|
| 337 | n/a | if _arguments.has_key('----'): |
|---|
| 338 | n/a | return _arguments['----'] |
|---|
| 339 | n/a | |
|---|
| 340 | n/a | _argmap_unregister_viewer = { |
|---|
| 341 | n/a | 'MIME_type' : 'MIME', |
|---|
| 342 | n/a | } |
|---|
| 343 | n/a | |
|---|
| 344 | n/a | def unregister_viewer(self, _object, _attributes={}, **_arguments): |
|---|
| 345 | n/a | """unregister viewer: Revert to the old way of handling this MIME type |
|---|
| 346 | n/a | Required argument: Application sig |
|---|
| 347 | n/a | Keyword argument MIME_type: MIME type to be unregistered |
|---|
| 348 | n/a | Keyword argument _attributes: AppleEvent attribute dictionary |
|---|
| 349 | n/a | Returns: TRUE if the event was successful |
|---|
| 350 | n/a | """ |
|---|
| 351 | n/a | _code = 'WWW!' |
|---|
| 352 | n/a | _subcode = 'UNRV' |
|---|
| 353 | n/a | |
|---|
| 354 | n/a | aetools.keysubst(_arguments, self._argmap_unregister_viewer) |
|---|
| 355 | n/a | _arguments['----'] = _object |
|---|
| 356 | n/a | |
|---|
| 357 | n/a | |
|---|
| 358 | n/a | _reply, _arguments, _attributes = self.send(_code, _subcode, |
|---|
| 359 | n/a | _arguments, _attributes) |
|---|
| 360 | n/a | if _arguments.get('errn', 0): |
|---|
| 361 | n/a | raise aetools.Error, aetools.decodeerror(_arguments) |
|---|
| 362 | n/a | # XXXX Optionally decode result |
|---|
| 363 | n/a | if _arguments.has_key('----'): |
|---|
| 364 | n/a | return _arguments['----'] |
|---|
| 365 | n/a | |
|---|
| 366 | n/a | _argmap_unregister_window_close = { |
|---|
| 367 | n/a | 'for_window' : 'WIND', |
|---|
| 368 | n/a | } |
|---|
| 369 | n/a | |
|---|
| 370 | n/a | def unregister_window_close(self, _object=None, _attributes={}, **_arguments): |
|---|
| 371 | n/a | """unregister window close: Undo for register window close |
|---|
| 372 | n/a | Required argument: Application signature |
|---|
| 373 | n/a | Keyword argument for_window: window ID |
|---|
| 374 | n/a | Keyword argument _attributes: AppleEvent attribute dictionary |
|---|
| 375 | n/a | Returns: true if successful |
|---|
| 376 | n/a | """ |
|---|
| 377 | n/a | _code = 'WWW!' |
|---|
| 378 | n/a | _subcode = 'UNRC' |
|---|
| 379 | n/a | |
|---|
| 380 | n/a | aetools.keysubst(_arguments, self._argmap_unregister_window_close) |
|---|
| 381 | n/a | _arguments['----'] = _object |
|---|
| 382 | n/a | |
|---|
| 383 | n/a | |
|---|
| 384 | n/a | _reply, _arguments, _attributes = self.send(_code, _subcode, |
|---|
| 385 | n/a | _arguments, _attributes) |
|---|
| 386 | n/a | if _arguments.get('errn', 0): |
|---|
| 387 | n/a | raise aetools.Error, aetools.decodeerror(_arguments) |
|---|
| 388 | n/a | # XXXX Optionally decode result |
|---|
| 389 | n/a | if _arguments.has_key('----'): |
|---|
| 390 | n/a | return _arguments['----'] |
|---|
| 391 | n/a | |
|---|
| 392 | n/a | def webActivate(self, _object=None, _attributes={}, **_arguments): |
|---|
| 393 | n/a | """webActivate: Makes Netscape the frontmost application, and selects a given window. This event is here for suite completeness/ cross-platform compatibility only, you should use standard AppleEvents instead. |
|---|
| 394 | n/a | Required argument: window to bring to front |
|---|
| 395 | n/a | Keyword argument _attributes: AppleEvent attribute dictionary |
|---|
| 396 | n/a | """ |
|---|
| 397 | n/a | _code = 'WWW!' |
|---|
| 398 | n/a | _subcode = 'ACTV' |
|---|
| 399 | n/a | |
|---|
| 400 | n/a | if _arguments: raise TypeError, 'No optional args expected' |
|---|
| 401 | n/a | _arguments['----'] = _object |
|---|
| 402 | n/a | |
|---|
| 403 | n/a | |
|---|
| 404 | n/a | _reply, _arguments, _attributes = self.send(_code, _subcode, |
|---|
| 405 | n/a | _arguments, _attributes) |
|---|
| 406 | n/a | if _arguments.get('errn', 0): |
|---|
| 407 | n/a | raise aetools.Error, aetools.decodeerror(_arguments) |
|---|
| 408 | n/a | # XXXX Optionally decode result |
|---|
| 409 | n/a | if _arguments.has_key('----'): |
|---|
| 410 | n/a | return _arguments['----'] |
|---|
| 411 | n/a | |
|---|
| 412 | n/a | |
|---|
| 413 | n/a | # |
|---|
| 414 | n/a | # Indices of types declared in this module |
|---|
| 415 | n/a | # |
|---|
| 416 | n/a | _classdeclarations = { |
|---|
| 417 | n/a | } |
|---|
| 418 | n/a | |
|---|
| 419 | n/a | _propdeclarations = { |
|---|
| 420 | n/a | } |
|---|
| 421 | n/a | |
|---|
| 422 | n/a | _compdeclarations = { |
|---|
| 423 | n/a | } |
|---|
| 424 | n/a | |
|---|
| 425 | n/a | _enumdeclarations = { |
|---|
| 426 | n/a | } |
|---|