Public bug reported:

            OptionSelector {
                onSelectedIndexChanged: {
                    console.log("SelectedIndex Changed")
                }
                onTriggered:  {
                    console.log("On Triggered")
                }
                onDelegateClicked: {
                    console.log("Delegate Clicked: " + index)
                }


With this example we see that onTriggered and onDelegateClicked are being fired 
before selectedIndex has been updated. This makes the onTriggered quite 
useless, as the important info of which is the selectedIndex is not there yet. 
onDelegateClicked suffers from the same problem, although it's index argument 
allows to workaround this bug.

IMHO having the selectedIndex updated before triggering these signals is
a justifiable and sane behavior.

** Affects: ubuntu-ui-toolkit (Ubuntu)
     Importance: Undecided
         Status: New

-- 
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
https://bugs.launchpad.net/bugs/1577351

Title:
  OptionSelector: selectedIndex should be updated before onTriggered and
  onDelegateClicked

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/ubuntu-ui-toolkit/+bug/1577351/+subscriptions

-- 
ubuntu-bugs mailing list
ubuntu-bugs@lists.ubuntu.com
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs

Reply via email to