← Back to team overview

ubuntu-phone team mailing list archive

[qml] Popover and OptionSelector

 

I'm trying to create a combobox-like widget. I have a button that calls
PopupUtils.show() to display a popover, but have not worked out how to
save the selection. I need to be able to save the selection and also
change the button's label in response to a selection.

The popover looks like this:
        Component {
            id: popoverComponent
            Popover {
                id: popover
        
                OptionSelector {
                    model: ["BTC", "mBTC", "μBTC"]
                    expanded: true
        
                    onDelegateClicked: PopupUtils.close(popover)
                }
            }
        }

Any tips?

Attachment: signature.asc
Description: This is a digitally signed message part


Follow ups