Issue 227: Allow two-way scrolling on a kinetic list if do_x and do_y are both true
Status:  Done
Owner:
Closed:  Jun 2010
Reported by jaybradl...@gmail.com, Apr 7, 2010
What steps will reproduce the problem?

1. If do_x and do_y are both true for MTKineticList then only do_y will be
respected because of the use of "elif" instead of "if"

What is the expected output? What do you see instead?

It should be possible to scroll kinetic lists in the x and y axes
simultaneously if do_x and do_y are both true.

What version of the product are you using? On what operating system?

Linux (Fedora 11) Git HEAD

Please provide any additional information below.

diff --git a/pymt/ui/widgets/composed/kineticlist.py
b/pymt/ui/widgets/composed/kineticlist.py
index 4167392..1ca1e1d 100644
--- a/pymt/ui/widgets/composed/kineticlist.py
+++ b/pymt/ui/widgets/composed/kineticlist.py
@@ -444,7 +444,7 @@ class MTKineticList(MTStencilContainer):
                 self.yoffset = boundary(self.yoffset, -size + self.height, 0)
                 self._scrollbar_size = self.height / size
                 self._scrollbar_index = -self.yoffset / size
-        elif self.do_x:
+        if self.do_x:
             if size < self.width:
                 self.xoffset = 0
             else:
@@ -512,7 +512,7 @@ class MTKineticList(MTStencilContainer):
                 size = [sb_size, self.height - mbottom - mtop]
                 pos[1] += size[1] * self._scrollbar_index
                 size[1] = size[1] * self._scrollbar_size
-            elif self.do_x:
+            if self.do_x:
                 pos = [self.x + mleft, self.y + self.height - mtop - sb_size]
                 size = [self.width - mleft - mright, sb_size]
                 pos[0] += size[0] * self._scrollbar_index
Apr 7, 2010
Project Member #1 txprog
(No comment was entered for this change.)
Status: Accepted
Owner: txprog
Labels: Component-Core Milestone-0.4.1
May 25, 2010
Project Member #2 txprog
This patch alone is not sufficient, since scrollbar is not duplicated for both axes.
Status: Started
Jun 1, 2010
Project Member #3 txprog
(No comment was entered for this change.)
Labels: Milestone-0.5
Jun 21, 2010
Project Member #4 txprog
KineticList will be deprecated in the next version.
The new MTList widget is now able to do this.
Status: Done