~unity-team/ubuntu-ui-toolkit/fix-1242647

« back to all changes in this revision

Viewing changes to examples/ubuntu-ui-toolkit-gallery/OptionSelectors.qml

  • Committer: Nic
  • Date: 2013-12-19 15:01:08 UTC
  • Revision ID: nicolas.doffay@canonical.com-20131219150108-dolv8qr5ytf4o31g
Print index in gallery when changing multiple selection.

Show diffs side-by-side

added added

removed removed

Lines of Context:
55
55
                        i18n.tr("Value 2"),
56
56
                        i18n.tr("Value 3"),
57
57
                        i18n.tr("Value 4")]
58
 
                onDelegateClicked: print("OPTION IS SELECTED: " + isSelected(index));
 
58
                onDelegateClicked: print("OPTION " + index +" IS SELECTED: " + isSelected(index));
59
59
                Component.onCompleted: {
60
60
                    for (var i = 0; i < 4; i++) {
61
61
                        print("OPTION ON CREATION: " + isSelected(i));
71
71
                multiSelection: true
72
72
                colourImage: true
73
73
                delegate: OptionSelectorDelegate { text: name; subText: description; iconSource: image; selected: selected }
74
 
                onDelegateClicked: print("OPTION IS SELECTED: " + isSelected(index));
 
74
                onDelegateClicked: print("OPTION " + index +" IS SELECTED: " + isSelected(index));
75
75
            }
76
76
 
77
77
            ListModel {