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

Native Development

Reply
Developer
bskania
Posts: 105
Registered: ‎04-24-2012
My Device: blackberry developer
Accepted Solution

List view problem in current bb10 beta version 3

Hello,

 

I am developing one project in bb10. Its working properly in the bb10 beta version 2.

Now I am converting this to bb10 beta version 3.

In that I am having a list view. i.e filtered list view.

On click of header the child should be visible.

for that selectionchanged signal I had used.

but Its not called in bb10 beta version 3.

I had searched in known issue also, but its not anywhere written as known issue.

 

 

Thanks in advance.

bskania.

Developer
peter9477
Posts: 6,473
Registered: ‎12-08-2010
My Device: PlayBook, Z10

Re: List view problem in current bb10 beta version 3

Rather than merely checking "Known Issues", did you carefully study the entire set of pages under Upgrading to beta 3 ?


Peter Hansen -- (BB10 and dev-related blog posts at http://peterhansen.ca.)
Author of White Noise and Battery Guru for BB10 and for PlayBook | Get more from your battery!
Developer
bskania
Posts: 105
Registered: ‎04-24-2012
My Device: blackberry developer

Re: List view problem in current bb10 beta version 3

yes I had checked that.
But there is no change mentioned for the selectionchanged.
Developer
Algorithmus
Posts: 16
Registered: ‎09-17-2012
My Device: Developer

Re: List view problem in current bb10 beta version 3

I had a similar problem, but did not include ListItem.onActivationChanged. I added it, and now it works.

Developer
bskania
Posts: 105
Registered: ‎04-24-2012
My Device: blackberry developer

Re: List view problem in current bb10 beta version 3

can you please provide some sort of code? where and how you had added onActivationChanged.?
Developer
Algorithmus
Posts: 16
Registered: ‎09-17-2012
My Device: Developer

Re: List view problem in current bb10 beta version 3

I don't know how you're implementing yours, but I followed the code off of the Cascadescookbookcpp sample app. There should be a file in there that defines the default behavior of the recipe list items.

Developer
nicklas
Posts: 150
Registered: ‎02-01-2009
My Device: Torch, PlayBook and Dev Alpha

Re: List view problem in current bb10 beta version 3

Now it's different in the beta 3:

 

ListView {
  listItemComponents: [
    ListItemComponent {
      type: "item"
      MyItem {
      }
    }
  ]

  onTriggered: {
    clearSelection();
    select(indexPath);
  }
}

 And for MyItem

Container {
  ImageView {
    id: background
    visible: false
  
    verticalAlignment: VerticalAlignment.Fill
    horizontalAlignment: HorizontalAlignment.Fill
  
    imageSource: "asset:///images/background.png"
    scalingMethod: ScalingMethod.Fill
  }
  
  function setHighlight (highlighted) {
    if (highlighted)
      background.visible = true;
    else
      background.visible = false;
  }

  ListItem.onActivationChanged: {
    setHighlight (ListItem.active);
  }

  ListItem.onSelectionChanged: {
    setHighlight (ListItem.selected);
  }
}

 Nicolas

 

Developer
bskania
Posts: 105
Registered: ‎04-24-2012
My Device: blackberry developer

Re: List view problem in current bb10 beta version 3

Thanks for your help.