Welcome!

Welcome to the official BlackBerry Support Community Forums.

This is your resource to discuss support topics with your peers, and learn from each other.

inside custom component

Adobe AIR Development

Reply
Contributor
imrahil
Posts: 12
Registered: ‎01-16-2011
My Device: Z10 Limited Edition
My Carrier: Play
Accepted Solution

ListDialog scroll problem

Hi all,

I just created simple app with ListDialog - code is taken from docs (https://developer.blackberry.com/air/documentation/bb10/create_popup_list_dialog.html)

 

package
{
    import flash.display.Sprite;
    import flash.events.MouseEvent;
    import qnx.fuse.ui.buttons.LabelButton;
    import qnx.fuse.ui.dialog.ListDialog;
    import flash.events.TimerEvent;
    import flash.utils.Timer;

    [SWF(height="1280", width="768", backgroundColor="#0D1722", frameRate="30")]
    public class TestApp extends Sprite
    {
        private var myList:ListDialog;

        public function TestApp()
        {
            var categoryBtn:LabelButton = new LabelButton();
            categoryBtn.label = "Category";
            categoryBtn.addEventListener(MouseEvent.CLICK, onCategoryBtnClick);
            addChild(categoryBtn);
        }

        private function onCategoryBtnClick(event:MouseEvent):void
        {
            myList = new ListDialog();
            myList.title = "Something...";
            myList.addButton("OK");
            myList.addButton("Cancel");
            myList.items = ['Milkshake', 'Cola', 'Lemonade', 'Water', 'Root Beer', 'Orange Juice', 'Apple Juice', 'Milkshake', 'Cola', 'Lemonade', 'Water', 'Root Beer', 'Orange Juice', 'Apple Juice', 'Milkshake', 'Cola', 'Lemonade', 'Water', 'Root Beer', 'Orange Juice', 'Apple Juice'];
            myList.show();
        }
    }
}

 

But in simulator or on device it's not possible to scroll this list.. it just bounce...

 

Anyone met this problem?

Please use plain text.
Developer
jtegen
Posts: 6,541
Registered: ‎10-27-2010
My Device: HTC One, PlayBook, LE Z10, DE Q10
My Carrier: Verizon

Re: ListDialog scroll problem

Bounces when you try to select it?

I see that occur from time to time on the overflow list.

I've been told the list stuff has been enhanced and we are suppose to get an update Wednesday, so I would try it again then. If it continues, report it as a bug since I could not reproduce it 100% of the time.
Please use plain text.
Contributor
imrahil
Posts: 12
Registered: ‎01-16-2011
My Device: Z10 Limited Edition
My Carrier: Play

Re: ListDialog scroll problem

funny.... I found a solution by myself.

 

I created class CustomListDialog with only one line in constructor:

 

        public function CustomListDialog()
        {
            _list.rowHeight = 190;
        }

 if rowHeight is lower than 190, scrolling on list doesn't work. 190 and higher everything is fine :smileyhappy:

Please use plain text.
Developer
jtegen
Posts: 6,541
Registered: ‎10-27-2010
My Device: HTC One, PlayBook, LE Z10, DE Q10
My Carrier: Verizon

Re: ListDialog scroll problem

Wow, odd. Good to know.
Please use plain text.
Contributor
imrahil
Posts: 12
Registered: ‎01-16-2011
My Device: Z10 Limited Edition
My Carrier: Play

Re: ListDialog scroll problem

Additional info: problem occurs only in vertical mode. In horizontal everything works fine...
Please use plain text.