开发者

Firing event in list in blackberry

开发者 https://www.devze.com 2023-01-28 11:18 出处:网络
I have implemented a list in开发者_开发问答 blackberry. How do I fire event \'on click\' of the list?The ListField has a protected method that you can overwrite,

I have implemented a list in开发者_开发问答 blackberry. How do I fire event 'on click' of the list?


The ListField has a protected method that you can overwrite,

protected boolean navigationClick(int status, int time).

Within the method navigationClick method you can get the selected list item (row) with the method getSelectedIndex().

So you'll have something such as:

protected boolean navigationClick(int status, int time) {
int sectionIndex = getSelectedIndex();
0

精彩评论

暂无评论...
验证码 换一张
取 消