diff options
| author | Jack Jansen <jack.jansen@cwi.nl> | 2003-06-13 14:31:19 (GMT) |
|---|---|---|
| committer | Jack Jansen <jack.jansen@cwi.nl> | 2003-06-13 14:31:19 (GMT) |
| commit | 8475d0256a9aafebe9685e5abcf8bcfc7f32f374 (patch) | |
| tree | 04e80eea24742ddd5a66c2b18b7700f0f0f88f01 /Lib/plat-mac/lib-scriptpackages/SystemEvents/System_Events_Suite.py | |
| parent | c8882b10c490298c670cec8ad6239acfaf14a66a (diff) | |
| download | cpython-8475d0256a9aafebe9685e5abcf8bcfc7f32f374.zip cpython-8475d0256a9aafebe9685e5abcf8bcfc7f32f374.tar.gz cpython-8475d0256a9aafebe9685e5abcf8bcfc7f32f374.tar.bz2 | |
Re-gegernated with the new gensuitemodule.
Diffstat (limited to 'Lib/plat-mac/lib-scriptpackages/SystemEvents/System_Events_Suite.py')
| -rw-r--r-- | Lib/plat-mac/lib-scriptpackages/SystemEvents/System_Events_Suite.py | 35 |
1 files changed, 23 insertions, 12 deletions
diff --git a/Lib/plat-mac/lib-scriptpackages/SystemEvents/System_Events_Suite.py b/Lib/plat-mac/lib-scriptpackages/SystemEvents/System_Events_Suite.py index 3fa5893..d5b4bfc 100644 --- a/Lib/plat-mac/lib-scriptpackages/SystemEvents/System_Events_Suite.py +++ b/Lib/plat-mac/lib-scriptpackages/SystemEvents/System_Events_Suite.py @@ -12,7 +12,25 @@ _code = 'sevs' class System_Events_Suite_Events: - pass + def do_script(self, _object, _attributes={}, **_arguments): + """do script: Execute an OSA script. + Required argument: the object for the command + Keyword argument _attributes: AppleEvent attribute dictionary + """ + _code = 'misc' + _subcode = 'dosc' + + 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['----'] class application(aetools.ComponentItem): @@ -22,23 +40,21 @@ class _Prop__3c_Inheritance_3e_(aetools.NProperty): """<Inheritance> - All of the properties of the superclass. """ which = 'c@#^' want = 'capp' +_3c_Inheritance_3e_ = _Prop__3c_Inheritance_3e_() class _Prop_folder_actions_enabled(aetools.NProperty): """folder actions enabled - Are Folder Actions currently being processed? """ which = 'faen' want = 'bool' +folder_actions_enabled = _Prop_folder_actions_enabled() class _Prop_properties(aetools.NProperty): """properties - every property of the System Events application """ which = 'pALL' want = '****' -class _Prop_system_wide_UI_element(aetools.NProperty): - """system wide UI element - the UI element for the entire system """ - which = 'swui' - want = 'uiel' -# element 'alis' as ['name', 'indx', 'rele', 'rang', 'test'] +properties = _Prop_properties() # element 'cdis' as ['name', 'indx', 'rele', 'rang', 'test'] # element 'cfol' as ['name', 'indx', 'rele', 'rang', 'test'] # element 'cobj' as ['name', 'indx', 'rele', 'rang', 'test'] -# element 'cwin' as ['name', 'indx', 'rele', 'rang', 'test'] +# element 'cwin' as ['name', 'indx', 'rele', 'rang', 'test', 'ID '] # element 'docu' as ['name', 'indx', 'rele', 'rang', 'test'] # element 'file' as ['name', 'indx', 'rele', 'rang', 'test'] # element 'foac' as ['name', 'indx', 'rele', 'rang', 'test'] @@ -46,7 +62,6 @@ class _Prop_system_wide_UI_element(aetools.NProperty): # element 'pcap' as ['name', 'indx', 'rele', 'rang', 'test'] # element 'pcda' as ['name', 'indx', 'rele', 'rang', 'test'] # element 'prcs' as ['name', 'indx', 'rele', 'rang', 'test'] -# element 'uiel' as ['name', 'indx', 'rele', 'rang', 'test'] applications = application application._superclassnames = [] @@ -59,11 +74,8 @@ application._privpropdict = { '_3c_Inheritance_3e_' : _Prop__3c_Inheritance_3e_, 'folder_actions_enabled' : _Prop_folder_actions_enabled, 'properties' : _Prop_properties, - 'system_wide_UI_element' : _Prop_system_wide_UI_element, } application._privelemdict = { - 'UI_element' : Processes_Suite.UI_element, - 'alias' : Disk_Folder_File_Suite.alias, 'application_process' : Processes_Suite.application_process, 'desk_accessory_process' : Processes_Suite.desk_accessory_process, 'disk' : Disk_Folder_File_Suite.disk, @@ -88,7 +100,6 @@ _propdeclarations = { 'c@#^' : _Prop__3c_Inheritance_3e_, 'faen' : _Prop_folder_actions_enabled, 'pALL' : _Prop_properties, - 'swui' : _Prop_system_wide_UI_element, } _compdeclarations = { |
