diff options
| author | Simon Robertshaw <simon@hardwired.org.uk> | 2011-10-26 13:50:50 (GMT) |
|---|---|---|
| committer | Simon Robertshaw <simon@hardwired.org.uk> | 2011-10-26 13:50:50 (GMT) |
| commit | e46ef289e142982d7bd592faa7b0f85470364c01 (patch) | |
| tree | cda253e03788f7db0a7cdcd05662f66b4455e298 /src/python/stdlib/plat-mac/lib-scriptpackages/_builtinSuites | |
| parent | d0d0d62bbcbb5c3417f8cba419c83bac192ea985 (diff) | |
| download | powder-e46ef289e142982d7bd592faa7b0f85470364c01.zip powder-e46ef289e142982d7bd592faa7b0f85470364c01.tar.gz | |
Remove Python console stuff
Diffstat (limited to 'src/python/stdlib/plat-mac/lib-scriptpackages/_builtinSuites')
| -rw-r--r-- | src/python/stdlib/plat-mac/lib-scriptpackages/_builtinSuites/__init__.py | 31 | ||||
| -rw-r--r-- | src/python/stdlib/plat-mac/lib-scriptpackages/_builtinSuites/builtin_Suite.py | 140 |
2 files changed, 0 insertions, 171 deletions
diff --git a/src/python/stdlib/plat-mac/lib-scriptpackages/_builtinSuites/__init__.py b/src/python/stdlib/plat-mac/lib-scriptpackages/_builtinSuites/__init__.py deleted file mode 100644 index b675b98..0000000 --- a/src/python/stdlib/plat-mac/lib-scriptpackages/_builtinSuites/__init__.py +++ /dev/null @@ -1,31 +0,0 @@ -""" -Manually generated suite used as base class for StdSuites Required and Standard -suites. This is needed because the events and enums in this suite belong -in the Required suite according to the Apple docs, but they often seem to be -in the Standard suite. -""" - -from warnings import warnpy3k -warnpy3k("In 3.x, the _builtinSuites module is removed.", stacklevel=2) - -import aetools -import builtin_Suite - - -_code_to_module = { - 'reqd' : builtin_Suite, - 'core' : builtin_Suite, -} - - - -_code_to_fullname = { - 'reqd' : ('_builtinSuites.builtin_Suite', 'builtin_Suite'), - 'core' : ('_builtinSuites.builtin_Suite', 'builtin_Suite'), -} - -from builtin_Suite import * - -class _builtinSuites(builtin_Suite_Events, - aetools.TalkTo): - _signature = 'ascr' diff --git a/src/python/stdlib/plat-mac/lib-scriptpackages/_builtinSuites/builtin_Suite.py b/src/python/stdlib/plat-mac/lib-scriptpackages/_builtinSuites/builtin_Suite.py deleted file mode 100644 index e3ee271..0000000 --- a/src/python/stdlib/plat-mac/lib-scriptpackages/_builtinSuites/builtin_Suite.py +++ /dev/null @@ -1,140 +0,0 @@ -"""Suite builtin_Suite: Every application supports open, reopen, print, run, and quit -Level 1, version 1 -""" - -import aetools -import MacOS - -_code = 'aevt' - -class builtin_Suite_Events: - - def open(self, _object, _attributes={}, **_arguments): - """open: Open the specified object(s) - Required argument: list of objects to open - Keyword argument _attributes: AppleEvent attribute dictionary - """ - _code = 'aevt' - _subcode = 'odoc' - - if _arguments: raise TypeError, 'No optional args expected' - _arguments['----'] = _object - - - _reply, _arguments, _attributes = self.send(_code, _subcode, - _arguments, _attributes) - if _arguments.get('errn', 0): - raise aetools.Error, aetools.decodeerror(_arguments) - # XXXX Optionally decode result - if _arguments.has_key('----'): - return _arguments['----'] - - def run(self, _no_object=None, _attributes={}, **_arguments): - """run: Run an application. Most applications will open an empty, untitled window. - Keyword argument _attributes: AppleEvent attribute dictionary - """ - _code = 'aevt' - _subcode = 'oapp' - - if _arguments: raise TypeError, 'No optional args expected' - if _no_object is not None: raise TypeError, 'No direct arg expected' - - - _reply, _arguments, _attributes = self.send(_code, _subcode, - _arguments, _attributes) - if _arguments.get('errn', 0): - raise aetools.Error, aetools.decodeerror(_arguments) - # XXXX Optionally decode result - if _arguments.has_key('----'): - return _arguments['----'] - - def reopen(self, _no_object=None, _attributes={}, **_arguments): - """reopen: Reactivate a running application. Some applications will open a new untitled window if no window is open. - Keyword argument _attributes: AppleEvent attribute dictionary - """ - _code = 'aevt' - _subcode = 'rapp' - - if _arguments: raise TypeError, 'No optional args expected' - if _no_object is not None: raise TypeError, 'No direct arg expected' - - - _reply, _arguments, _attributes = self.send(_code, _subcode, - _arguments, _attributes) - if _arguments.get('errn', 0): - raise aetools.Error, aetools.decodeerror(_arguments) - # XXXX Optionally decode result - if _arguments.has_key('----'): - return _arguments['----'] - - def _print(self, _object, _attributes={}, **_arguments): - """print: Print the specified object(s) - Required argument: list of objects to print - Keyword argument _attributes: AppleEvent attribute dictionary - """ - _code = 'aevt' - _subcode = 'pdoc' - - if _arguments: raise TypeError, 'No optional args expected' - _arguments['----'] = _object - - - _reply, _arguments, _attributes = self.send(_code, _subcode, - _arguments, _attributes) - if _arguments.get('errn', 0): - raise aetools.Error, aetools.decodeerror(_arguments) - # XXXX Optionally decode result - if _arguments.has_key('----'): - return _arguments['----'] - - _argmap_quit = { - 'saving' : 'savo', - } - - def quit(self, _no_object=None, _attributes={}, **_arguments): - """quit: Quit an application - Keyword argument saving: specifies whether to save currently open documents - Keyword argument _attributes: AppleEvent attribute dictionary - """ - _code = 'aevt' - _subcode = 'quit' - - aetools.keysubst(_arguments, self._argmap_quit) - if _no_object is not None: raise TypeError, 'No direct arg expected' - - aetools.enumsubst(_arguments, 'savo', _Enum_savo) - - _reply, _arguments, _attributes = self.send(_code, _subcode, - _arguments, _attributes) - if _arguments.get('errn', 0): - raise aetools.Error, aetools.decodeerror(_arguments) - # XXXX Optionally decode result - if _arguments.has_key('----'): - return _arguments['----'] - - _argmap_close = { - 'saving' : 'savo', - 'saving_in' : 'kfil', - } - -_Enum_savo = { - 'yes' : 'yes ', # Save objects now - 'no' : 'no ', # Do not save objects - 'ask' : 'ask ', # Ask the user whether to save -} - -# -# Indices of types declared in this module -# -_classdeclarations = { -} - -_propdeclarations = { -} - -_compdeclarations = { -} - -_enumdeclarations = { - 'savo' : _Enum_savo, -} |
