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

Java Development

Reply
Regular Contributor
musmankhan90
Posts: 92
Registered: ‎03-09-2013
My Device: bold 9800
My Carrier: blackberry

Using Label.Focusable opens Menu List Tray

Hello Every one,

                           I am making my LabelField Clickable, but when i click on LabelField, it cliked, but also open menu Tray option as well. Kindly tell me the reason, i have already made search but didn't get satisfoctory reason for that.

 

labelClicked.PNG

 

LabelField miniStatement = new LabelField("Mient\nThis is some description here",LabelField.FOCUSABLE_MASK|Field.FIELD_HCENTER){
            public void paint(Graphics g){
                g.setColor(Color.WHITE); super.paint(g);
                }
            protected boolean navigationClick(int status, int time)
            {  
                    Dialog.alert("I am Clicked");    
                                }
                     return false;
            }
        };

Please use plain text.
Developer
simon_hain
Posts: 15,814
Registered: ‎07-29-2008
My Device: Z10 LE
My Carrier: O2 Germany

Re: Using Label.Focusable opens Menu List Tray

return true to indicate that you handled the event yourself.
----------------------------------------------------------
feel free to press the like button on the right side to thank the user that helped you.
please mark posts as solved if you found a solution.
@SimonHain on twitter
Please use plain text.