# HG changeset patch # User Thinker K.F. Li # Date 1289985899 -28800 # Node ID a05ec4fb1c20fbc504152d9843b22def41c6f74b # Parent 6612fd386ea96077acc4135b368337868cf5ae45 update framelines according content 0f layers diff -r 6612fd386ea9 -r a05ec4fb1c20 pyink/MBScene.py --- a/pyink/MBScene.py Wed Nov 17 17:14:22 2010 +0800 +++ b/pyink/MBScene.py Wed Nov 17 17:24:59 2010 +0800 @@ -505,7 +505,7 @@ btn.modify_bg(gtk.STATE_NORMAL, btn.get_colormap().alloc_color("gray")) return btn - def create_framelines(self): + def _create_framelines(self): import frameline self.scrollwin = gtk.ScrolledWindow() self.scrollwin.set_policy(gtk.POLICY_AUTOMATIC, gtk.POLICY_AUTOMATIC) @@ -534,9 +534,15 @@ pass pass - def update_all_framelines(self): - for layer in self.layers: + ## \brief Update conetent of frameliens according layers. + # + def _update_framelines(self): + for layer_i, layer in enumerate(self.layers): for scene in layer.scenes: + frameline = self._framelines[layer_i] + for scene_i in range(scene.start, scene.stop + 1): + frameline.add_keyframe(scene_i) + pass pass pass pass @@ -680,8 +686,8 @@ def show(self): self.OK = True self.parseScene() - # self.showGrid() - self.create_framelines() + self._create_framelines() + self._update_framelines() vbox = gtk.VBox(False,0) self.desktop.getToplevel().child.child.pack_end(vbox,expand=False) self.window = vbox