BlackBerry Forums Support Community               

Closed Thread
 
LinkBack Thread Tools
Old 12-13-2009, 03:36 AM   #1 (permalink)
New Member
 
Join Date: Nov 2009
Model: 8310
PIN: N/A
Carrier: zain
Posts: 6
Post Thanks: 0
Thanked 0 Times in 0 Posts
Default Prevent horizontal manager from up/down based navigation

Please Login to Remove!

Hello All,

I have horizontal manager which has two lists. My problem is when you scroll down and hit the last item of the left list the manager move the focus to the right list. I need to stop this navigation and let the left/right trackball navigation only.
Offline  
Old 12-18-2009, 05:28 AM   #2 (permalink)
New Member
 
Join Date: Apr 2009
Model: 8800
PIN: N/A
Carrier: Software developer
Posts: 14
Post Thanks: 0
Thanked 0 Times in 0 Posts
Default

Add another focuable field (but not visible to user) such as a LabelField with empty string to the bottom of the first list. Then each time it is focused after the last item of your first list, set focus to that item.
Offline  
Old 12-20-2009, 08:22 AM   #3 (permalink)
New Member
 
Join Date: Nov 2009
Model: 8310
PIN: N/A
Carrier: zain
Posts: 6
Post Thanks: 0
Thanked 0 Times in 0 Posts
Default

Thanks for your help, I 've found clean way to do it by overriding navigationMovement method inside the ListField:

protected boolean navigationMovement(int dx, int dy, int status, int time) {
if( getSelectedIndex() + dy >= getSize() ) {
return true;

}

return super.navigationMovement(dx, dy, status, time);

}
Offline  
Closed Thread


Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On





Copyright 2004-2014 BlackBerryForums.com.
The names RIM and BlackBerry are registered Trademarks of BlackBerry Inc.