예제 #1
0
        public void ShowPicker()
        {
            currentPopup = popup.Template();
            currentPopup.Show();
            currentListView = currentPopup.GetComponentInChildren <ListViewInt>();

            // fill list with values
            currentListView.DataSource = Enumerable.Range(1, 100).ToObservableList();

            // deselect
            currentListView.SelectedIndex = -1;
            currentListView.OnSelectObject.AddListener(Callback);
        }
예제 #2
0
        /// <summary>
        /// Show picker.
        /// </summary>
        public void ShowPicker()
        {
            currentPopup = PopupTemplate.Clone();
            currentPopup.Show();
            currentListView = currentPopup.GetComponentInChildren <ListViewInt>();

            // fill list with values
            currentListView.DataSource = Utilites.CreateList(100, x => x);

            // deselect
            currentListView.SelectedIndex = -1;
            currentListView.OnSelectObject.AddListener(Callback);
        }