24 # Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. |
24 # Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. |
25 |
25 |
26 import os |
26 import os |
27 import sys |
27 import sys |
28 import shutil |
28 import shutil |
|
29 import wx |
|
30 from gnosis.xml.pickle import * |
|
31 from gnosis.xml.pickle.util import setParanoia |
29 |
32 |
30 import util.paths as paths |
33 import util.paths as paths |
31 |
34 from util.TranslationCatalogs import AddCatalog |
32 base_folder = paths.AbsParentDir(__file__, 2) |
35 from ConfigTreeNode import ConfigTreeNode |
33 CanFestivalPath = os.path.join(base_folder, "CanFestival-3") |
36 from PLCControler import \ |
34 sys.path.append(os.path.join(CanFestivalPath, "objdictgen")) |
37 LOCATION_CONFNODE, \ |
35 |
38 LOCATION_MODULE, \ |
36 import wx |
39 LOCATION_GROUP, \ |
37 |
40 LOCATION_VAR_INPUT, \ |
38 from nodelist import NodeList |
41 LOCATION_VAR_OUTPUT, \ |
|
42 LOCATION_VAR_MEMORY |
|
43 |
|
44 try: |
|
45 from nodelist import NodeList |
|
46 except ImportError: |
|
47 base_folder = paths.AbsParentDir(__file__, 2) |
|
48 CanFestivalPath = os.path.join(base_folder, "CanFestival-3") |
|
49 sys.path.append(os.path.join(CanFestivalPath, "objdictgen")) |
|
50 |
|
51 from nodelist import NodeList |
|
52 |
|
53 |
39 from nodemanager import NodeManager |
54 from nodemanager import NodeManager |
40 import config_utils |
55 import config_utils |
41 import gen_cfile |
56 import gen_cfile |
42 import eds_utils |
57 import eds_utils |
43 import canfestival_config as local_canfestival_config |
58 import canfestival_config as local_canfestival_config |
44 from ConfigTreeNode import ConfigTreeNode |
59 |
45 from commondialogs import CreateNodeDialog |
60 from commondialogs import CreateNodeDialog |
46 from subindextable import IECTypeConversion, SizeConversion |
61 from subindextable import IECTypeConversion, SizeConversion |
47 |
|
48 from PLCControler import LOCATION_CONFNODE, LOCATION_MODULE, LOCATION_GROUP, LOCATION_VAR_INPUT, LOCATION_VAR_OUTPUT, LOCATION_VAR_MEMORY |
|
49 from SlaveEditor import SlaveEditor, MasterViewer |
62 from SlaveEditor import SlaveEditor, MasterViewer |
50 from NetworkEditor import NetworkEditor |
63 from NetworkEditor import NetworkEditor |
51 |
64 |
52 from gnosis.xml.pickle import * |
65 |
53 from gnosis.xml.pickle.util import setParanoia |
66 AddCatalog(os.path.join(CanFestivalPath, "objdictgen", "locale")) |
54 setParanoia(0) |
67 setParanoia(0) |
55 |
68 |
56 from util.TranslationCatalogs import AddCatalog |
|
57 AddCatalog(os.path.join(CanFestivalPath, "objdictgen", "locale")) |
|
58 |
69 |
59 # -------------------------------------------------- |
70 # -------------------------------------------------- |
60 # Location Tree Helper |
71 # Location Tree Helper |
61 # -------------------------------------------------- |
72 # -------------------------------------------------- |
62 |
73 |