diff options
author | Guido van Rossum <guido@python.org> | 2006-04-21 15:44:20 (GMT) |
---|---|---|
committer | Guido van Rossum <guido@python.org> | 2006-04-21 15:44:20 (GMT) |
commit | 6da48561cb7844526164d3a656c6d16afe904e3d (patch) | |
tree | 76b85ad3717da33ef7c6246807204b902a3ac920 /Lib/plat-mac/lib-scriptpackages/SystemEvents | |
parent | c350d1a1106658d968badf2c35f5b10ddaa59a3e (diff) | |
download | cpython-6da48561cb7844526164d3a656c6d16afe904e3d.zip cpython-6da48561cb7844526164d3a656c6d16afe904e3d.tar.gz cpython-6da48561cb7844526164d3a656c6d16afe904e3d.tar.bz2 |
Fix test_scriptpackage with pure will power.
I really don't know why I bother; these are all generated files.
But I don't recall how to regenerate them nor how to fix the generator.
The hardest part was fixing two mutual recursive imports;
somehow changing "import foo" into "from . import foo" where
foo and bar import each other AND both are imported from __init__.py
caused things to break. Bah.
Diffstat (limited to 'Lib/plat-mac/lib-scriptpackages/SystemEvents')
8 files changed, 51 insertions, 40 deletions
diff --git a/Lib/plat-mac/lib-scriptpackages/SystemEvents/Disk_Folder_File_Suite.py b/Lib/plat-mac/lib-scriptpackages/SystemEvents/Disk_Folder_File_Suite.py index a9ac3dd..a0b199f 100644 --- a/Lib/plat-mac/lib-scriptpackages/SystemEvents/Disk_Folder_File_Suite.py +++ b/Lib/plat-mac/lib-scriptpackages/SystemEvents/Disk_Folder_File_Suite.py @@ -5,6 +5,11 @@ Generated from /System/Library/CoreServices/System Events.app AETE/AEUT resource version 1/0, language 0, script 0 """ +# Crutch for recursive import +import sys +import SystemEvents +SystemEvents.Disk_Folder_File_Suite = sys.modules[__name__] + import aetools import MacOS @@ -210,10 +215,10 @@ class _Prop_version(aetools.NProperty): files = file application._superclassnames = [] -import Standard_Suite -import Folder_Actions_Suite -import Login_Items_Suite -import Processes_Suite +from . import Standard_Suite +from . import Folder_Actions_Suite +from . import Login_Items_Suite +from . import Processes_Suite application._privpropdict = { '_3c_Inheritance_3e_' : _Prop__3c_Inheritance_3e_, 'folder_actions_enabled' : _Prop_folder_actions_enabled, diff --git a/Lib/plat-mac/lib-scriptpackages/SystemEvents/Folder_Actions_Suite.py b/Lib/plat-mac/lib-scriptpackages/SystemEvents/Folder_Actions_Suite.py index c2c7e5e..cb07a14 100644 --- a/Lib/plat-mac/lib-scriptpackages/SystemEvents/Folder_Actions_Suite.py +++ b/Lib/plat-mac/lib-scriptpackages/SystemEvents/Folder_Actions_Suite.py @@ -5,6 +5,11 @@ Generated from /System/Library/CoreServices/System Events.app AETE/AEUT resource version 1/0, language 0, script 0 """ +# Crutch for recursive import +import sys +import SystemEvents +SystemEvents.Folder_Actions_Suite = sys.modules[__name__] + import aetools import MacOS @@ -208,10 +213,11 @@ class _Prop_POSIX_path(aetools.NProperty): scripts = script application._superclassnames = [] -import Disk_Folder_File_Suite -import Standard_Suite -import Login_Items_Suite -import Processes_Suite +import sys +from . import Disk_Folder_File_Suite +from . import Standard_Suite +from . import Login_Items_Suite +from . import Processes_Suite application._privpropdict = { '_3c_Inheritance_3e_' : _Prop__3c_Inheritance_3e_, 'folder_actions_enabled' : _Prop_folder_actions_enabled, diff --git a/Lib/plat-mac/lib-scriptpackages/SystemEvents/Login_Items_Suite.py b/Lib/plat-mac/lib-scriptpackages/SystemEvents/Login_Items_Suite.py index ed09245..0409558 100644 --- a/Lib/plat-mac/lib-scriptpackages/SystemEvents/Login_Items_Suite.py +++ b/Lib/plat-mac/lib-scriptpackages/SystemEvents/Login_Items_Suite.py @@ -40,7 +40,7 @@ class _Prop_path(aetools.NProperty): want = 'utxt' login_items = login_item -import Standard_Suite +from . import Standard_Suite login_item._superclassnames = ['item'] login_item._privpropdict = { '_3c_Inheritance_3e_' : _Prop__3c_Inheritance_3e_, diff --git a/Lib/plat-mac/lib-scriptpackages/SystemEvents/Power_Suite.py b/Lib/plat-mac/lib-scriptpackages/SystemEvents/Power_Suite.py index ef539b1..bfdf536 100644 --- a/Lib/plat-mac/lib-scriptpackages/SystemEvents/Power_Suite.py +++ b/Lib/plat-mac/lib-scriptpackages/SystemEvents/Power_Suite.py @@ -105,11 +105,11 @@ properties = _Prop_properties() applications = application application._superclassnames = [] -import Disk_Folder_File_Suite -import Standard_Suite -import Folder_Actions_Suite -import Login_Items_Suite -import Processes_Suite +from . import Disk_Folder_File_Suite +from . import Standard_Suite +from . import Folder_Actions_Suite +from . import Login_Items_Suite +from . import Processes_Suite application._privpropdict = { '_3c_Inheritance_3e_' : _Prop__3c_Inheritance_3e_, 'folder_actions_enabled' : _Prop_folder_actions_enabled, diff --git a/Lib/plat-mac/lib-scriptpackages/SystemEvents/Processes_Suite.py b/Lib/plat-mac/lib-scriptpackages/SystemEvents/Processes_Suite.py index 9dcb85f..a55c0a1 100644 --- a/Lib/plat-mac/lib-scriptpackages/SystemEvents/Processes_Suite.py +++ b/Lib/plat-mac/lib-scriptpackages/SystemEvents/Processes_Suite.py @@ -121,10 +121,10 @@ class _Prop_visible(aetools.NProperty): processes = process application._superclassnames = [] -import Disk_Folder_File_Suite -import Standard_Suite -import Folder_Actions_Suite -import Login_Items_Suite +from . import Disk_Folder_File_Suite +from . import Standard_Suite +from . import Folder_Actions_Suite +from . import Login_Items_Suite application._privpropdict = { '_3c_Inheritance_3e_' : _Prop__3c_Inheritance_3e_, 'folder_actions_enabled' : _Prop_folder_actions_enabled, 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 d5b4bfc..cf3e213 100644 --- a/Lib/plat-mac/lib-scriptpackages/SystemEvents/System_Events_Suite.py +++ b/Lib/plat-mac/lib-scriptpackages/SystemEvents/System_Events_Suite.py @@ -65,11 +65,11 @@ properties = _Prop_properties() applications = application application._superclassnames = [] -import Disk_Folder_File_Suite -import Standard_Suite -import Folder_Actions_Suite -import Login_Items_Suite -import Processes_Suite +from . import Disk_Folder_File_Suite +from . import Standard_Suite +from . import Folder_Actions_Suite +from . import Login_Items_Suite +from . import Processes_Suite application._privpropdict = { '_3c_Inheritance_3e_' : _Prop__3c_Inheritance_3e_, 'folder_actions_enabled' : _Prop_folder_actions_enabled, diff --git a/Lib/plat-mac/lib-scriptpackages/SystemEvents/Text_Suite.py b/Lib/plat-mac/lib-scriptpackages/SystemEvents/Text_Suite.py index 9f109e1..ec66c2c 100644 --- a/Lib/plat-mac/lib-scriptpackages/SystemEvents/Text_Suite.py +++ b/Lib/plat-mac/lib-scriptpackages/SystemEvents/Text_Suite.py @@ -101,7 +101,7 @@ attachment._privelemdict = { 'paragraph' : paragraph, 'word' : word, } -import Standard_Suite +from . import Standard_Suite attribute_run._superclassnames = ['item'] attribute_run._privpropdict = { '_3c_Inheritance_3e_' : _Prop__3c_Inheritance_3e_, diff --git a/Lib/plat-mac/lib-scriptpackages/SystemEvents/__init__.py b/Lib/plat-mac/lib-scriptpackages/SystemEvents/__init__.py index 95f985c..ce3b0e2 100644 --- a/Lib/plat-mac/lib-scriptpackages/SystemEvents/__init__.py +++ b/Lib/plat-mac/lib-scriptpackages/SystemEvents/__init__.py @@ -3,14 +3,14 @@ Package generated from /System/Library/CoreServices/System Events.app """ import aetools Error = aetools.Error -import Standard_Suite -import Text_Suite -import Disk_Folder_File_Suite -import Folder_Actions_Suite -import Login_Items_Suite -import Power_Suite -import Processes_Suite -import System_Events_Suite +from . import Standard_Suite +from . import Text_Suite +from . import Disk_Folder_File_Suite +from . import Folder_Actions_Suite +from . import Login_Items_Suite +from . import Power_Suite +from . import Processes_Suite +from . import System_Events_Suite _code_to_module = { @@ -37,14 +37,14 @@ _code_to_fullname = { 'sevs' : ('SystemEvents.System_Events_Suite', 'System_Events_Suite'), } -from Standard_Suite import * -from Text_Suite import * -from Disk_Folder_File_Suite import * -from Folder_Actions_Suite import * -from Login_Items_Suite import * -from Power_Suite import * -from Processes_Suite import * -from System_Events_Suite import * +from SystemEvents.Standard_Suite import * +from SystemEvents.Text_Suite import * +from SystemEvents.Disk_Folder_File_Suite import * +from SystemEvents.Folder_Actions_Suite import * +from SystemEvents.Login_Items_Suite import * +from SystemEvents.Power_Suite import * +from SystemEvents.Processes_Suite import * +from SystemEvents.System_Events_Suite import * def getbaseclasses(v): if not getattr(v, '_propdict', None): |