Panel getItemText



  • This would be a useful function when using panels to create custom combo boxes.



  • Actually, if you're using a combobox type Panel, you'll probably have a array containing the items in the data object. In this case, you can write a simple function yourself:

    
    inline function getItemText(panel)
    {
        return panel.data.items[panel.getValue()];
    };
    

    I am not sure if adding a function to the API will be useful because as soon as you customise the data model, you're back on your own.



  • Good idea!


Log in to reply
 

4
Online

702
Users

2.8k
Topics

23.7k
Posts