com.nokia.mid.ui
Interface ElementListener


public interface ElementListener

ElementListener enables an application to discover when the user has selected an element from a CategoryBar.


Field Summary
static int BACK
          Constant indicating that the predefined BACK element has been selected.
 
Method Summary
 void notifyElementSelected(CategoryBar bar, int selectedIndex)
          Notifies the listener that an element belonging to the given CategoryBar was selected.
 

Field Detail

BACK

static final int BACK
Constant indicating that the predefined BACK element has been selected.

When this value is passed to an ElementListener, it indicates that the user wishes to exit the CategoryBar. If the topmost screen in the application's UI hierarchy is currently being displayed then this event is also a signal for the application to close if appropriate.

See Also:
Constant Field Values
Method Detail

notifyElementSelected

void notifyElementSelected(CategoryBar bar,
                           int selectedIndex)
Notifies the listener that an element belonging to the given CategoryBar was selected.

Every CategoryBar features a predefined element that cannot be removed. If this element is selected then the special value BACK is supplied in the selectedIndex parameter.

Parameters:
bar - the instance of CategoryBar whose element was selected.
selectedIndex - the index of the selected element, or BACK in the case that the predefined BACK element was selected.


Copyright © 2012 Nokia Corporation. All rights reserved.

Nokia is registered trademark of Nokia Corporation. Java and all Java-based marks are trademarks or registered trademarks of Oracle Corporation. Other product and company names mentioned herein may be trademarks or trade names of their respective owners. This document is confidential information of Nokia Corporation.

Disclaimer
The information in this document is provided "as is," with no warranties whatsoever, including any warranty of merchantability, fitness for any particular purpose, or any warranty otherwise arising out of any proposal, specification, or sample. Furthermore, information provided in this document is preliminary, and may be changed substantially prior to final release.

Nokia Corporation disclaims all liability, including liability for infringement of any proprietary rights, relating to this document and implementation of any information presented in this document.

Nokia Corporation retains the right to make changes to this document at any time, without notice.

License
Subject to above disclaimer, a license is hereby granted to use this documentation solely under existing Limited License Agreement and non-disclosure agreement between the companies for the agreed application development for Series 40 Nokia phones. No other licenses e.g. to any intellectual property rights are granted herein. Any use of the screen shots of this documentation, including any icons thereof, is subject to Nokia's prior written approval.