comparison pyink/MBScene.py @ 1208:96ca8a1cf449

Remove unused classes
author Thinker K.F. Li <thinker@codemud.net>
date Tue, 04 Jan 2011 10:50:16 +0800
parents 489e6e474fdf
children 41d13feeecc4
comparison
equal deleted inserted replaced
1207:489e6e474fdf 1208:96ca8a1cf449
47 self.scenes = [] 47 self.scenes = []
48 self.group = node 48 self.group = node
49 pass 49 pass
50 pass 50 pass
51 51
52 class Scene:
53 def __init__(self, node, start,end,typ):
54 self.node = node
55 self.start = int(start)
56 self.end = int(end)
57 self.type = typ
58 pass
59 pass
60 class DOM(pybInkscape.PYSPObject):
61 def __init__(self,obj=None):
62 self.proxy = obj
63 pass
64
65 def duplicate(self,doc):
66 return DOM(self.repr.duplicate(doc))
67
68 class ObjectWatcher(pybInkscape.PYNodeObserver): 52 class ObjectWatcher(pybInkscape.PYNodeObserver):
69 def __init__(self,obj,type,func,arg): 53 def __init__(self,obj,type,func,arg):
70 self.obj = obj 54 self.obj = obj
71 self.type = type 55 self.type = type
72 self.func = func 56 self.func = func
92 obj.addSubtreeObserver(obs) 76 obj.addSubtreeObserver(obs)
93 77
94 78
95 _scenes = '{http://madbutterfly.sourceforge.net/DTD/madbutterfly.dtd}scenes' 79 _scenes = '{http://madbutterfly.sourceforge.net/DTD/madbutterfly.dtd}scenes'
96 _scene = '{http://madbutterfly.sourceforge.net/DTD/madbutterfly.dtd}scene' 80 _scene = '{http://madbutterfly.sourceforge.net/DTD/madbutterfly.dtd}scene'
97 class LayerAttributeWatcher(pybInkscape.PYNodeObserver):
98 def __init__(self,ui):
99 self.ui = ui
100 def notifyChildAdded(self,node,child,prev):
101 pass
102
103 def notifyChildRemoved(self,node,child,prev):
104 pass
105
106 def notifyChildOrderChanged(self,node,child,prev):
107 pass
108
109 def notifyContentChanged(self,node,old_content,new_content):
110 pass
111
112 def notifyAttributeChanged(self,node, name, old_value, new_value):
113 self.ui.updateUI()
114 pass
115
116 class LayerAddRemoveWatcher(pybInkscape.PYNodeObserver):
117 def __init__(self,ui):
118 self.ui = ui
119 pass
120
121 def notifyChildAdded(self,node,child,prev):
122 self.ui.updateUI()
123 pass
124
125 def notifyChildRemoved(self,node,child,prev):
126 self.ui.updateUI()
127 pass
128
129 def notifyChildOrderChanged(self,node,child,prev):
130 self.ui.updateUI()
131 pass
132
133 def notifyContentChanged(self,node,old_content,new_content):
134 self.ui.updateUI()
135 pass
136
137 def notifyAttributeChanged(self,node, name, old_value, new_value):
138 self.ui.updateUI()
139 pass
140 81
141 def _travel_DOM(node): 82 def _travel_DOM(node):
142 nodes = [node] 83 nodes = [node]
143 while nodes: 84 while nodes:
144 node = nodes.pop(0) 85 node = nodes.pop(0)