equal
deleted
inserted
replaced
24 |
24 |
25 import os |
25 import os |
26 |
26 |
27 from nevow import tags, loaders |
27 from nevow import tags, loaders |
28 import simplejson as json |
28 import simplejson as json |
|
29 import runtime.NevowServer as NS |
29 |
30 |
30 svgfile = '%(svgfile)s' |
31 svgfile = '%(svgfile)s' |
31 |
32 |
32 svguiWidgets = {} |
33 svguiWidgets = {} |
33 |
34 |
111 |
112 |
112 class SVGUI_HMI(website.PLCHMI): |
113 class SVGUI_HMI(website.PLCHMI): |
113 jsClass = u"LiveSVGPage.LiveSVGWidget" |
114 jsClass = u"LiveSVGPage.LiveSVGWidget" |
114 |
115 |
115 docFactory = loaders.stan(tags.div(render=tags.directive('liveElement'))[ |
116 docFactory = loaders.stan(tags.div(render=tags.directive('liveElement'))[ |
116 tags.xml(loaders.xmlfile(os.path.join(WorkingDir, svgfile))), |
117 tags.xml(loaders.xmlfile(os.path.join(NS.WorkingDir, svgfile))), |
117 ]) |
118 ]) |
118 |
119 |
119 def HMIinitialisation(self): |
120 def HMIinitialisation(self): |
120 gadgets = [] |
121 gadgets = [] |
121 for gadget in svguiWidgets.values(): |
122 for gadget in svguiWidgets.values(): |