Web   ·   Wiki   ·   Activities   ·   Blog   ·   Lists   ·   Chat   ·   Meeting   ·   Bugs   ·   Git   ·   Translate   ·   Archive   ·   People   ·   Donate
summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAgustin Zubiaga <aguz@sugarlabs.org>2012-05-28 01:33:38 (GMT)
committer Agustin Zubiaga <aguz@sugarlabs.org>2012-05-28 01:33:38 (GMT)
commit453d8f15cfae89de2a134b7ac085a5ba030068a0 (patch)
tree718f25d287ef9595807c04aa1f289dede6574cb4
parent6a79db9e131b629e66737eb32c74db430c8e7e5b (diff)
parent097e0e25e04db0855298c0ed92ba7c9ed306c5e3 (diff)
Merge branch 'master' of git.sugarlabs.org:animate/mainline
-rw-r--r--TODO3
-rw-r--r--frames_list.py11
2 files changed, 10 insertions, 4 deletions
diff --git a/TODO b/TODO
index c41bc84..58239db 100644
--- a/TODO
+++ b/TODO
@@ -1,9 +1,8 @@
New functions:
- Save data in journal
- Select time between frames
- - Select the frames when the activitie loads them.
Fixes:
- Enable drag and drop between frames.
- Correct frame selection in ping pong mode
Bugs:
- Void.
+ - Doesn't scroll to the seleceted item
diff --git a/frames_list.py b/frames_list.py
index 3286e3d..5df5ba6 100644
--- a/frames_list.py
+++ b/frames_list.py
@@ -53,7 +53,13 @@ class FramesList(gtk.ScrolledWindow):
model.remove(_iter)
count = 1
for i in self.store:
- i[0] = count
+ print i
+ selected = False
+ if i[0] != count:
+ i[0] = count
+ if not selected:
+ self.selection.select_iter(_iter)
+ selected = True
count += 1
self.frames = count - 1
@@ -67,7 +73,8 @@ class FramesList(gtk.ScrolledWindow):
preview_pixbuf = pixbuf.scale_simple(200,
200 * height / width,
gtk.gdk.INTERP_TILES)
- self.store.append([self.frames, preview_pixbuf])
+ _iter = self.store.append([self.frames, preview_pixbuf])
+ self.selection.select_iter(_iter)
if self._animation and not self._animation_connected:
self._animation.connect("current-frame-updated", self._select_frame)
self._animation_connected = True