Ejemplo n.º 1
0
        private void OnGridDoubleClicked(TableContainer sender, TableRow row)
        {
            bool flag = false;

            if (sender.ID == 99576784u)
            {
                DualPanelHouseholds.DualPaneSimPickerRowController dualPaneSimPickerRowController = row.RowController as DualPanelHouseholds.DualPaneSimPickerRowController;
                ObjectPicker.RowInfo info = dualPaneSimPickerRowController.Info;
                this.mSelectedSims.Remove(info);
                flag = true;
            }
            else
            {
                DualPanelHouseholds.DualPaneSimPickerRowController dualPaneSimPickerRowController2 = row.RowController as DualPanelHouseholds.DualPaneSimPickerRowController;
                if (dualPaneSimPickerRowController2.Enabled)
                {
                    ObjectPicker.RowInfo info2 = dualPaneSimPickerRowController2.Info;
                    this.mSelectedSims.Add(info2);
                    flag = true;
                }
            }
            if (flag)
            {
                Audio.StartSound("ui_panel_shift");
                this.mLeftArrow.Enabled  = false;
                this.mRightArrow.Enabled = false;
                this.RepopulateSourceTable();
                this.RepopulateSelectedSimTable();
            }
        }
Ejemplo n.º 2
0
 private void OnSelectionChanged(WindowBase sender, UISelectionChangeEventArgs eventArgs)
 {
     if (!(sender == this.mSelectedTable))
     {
         if (this.mSourceTable.SelectedItem >= 0)
         {
             TableRow row = this.mSourceTable.GetRow(this.mSourceTable.SelectedItem);
             if (row != null)
             {
                 DualPanelHouseholds.DualPaneSimPickerRowController dualPaneSimPickerRowController = row.RowController as DualPanelHouseholds.DualPaneSimPickerRowController;
                 if (dualPaneSimPickerRowController != null && dualPaneSimPickerRowController.Enabled)
                 {
                     this.mRightArrow.Enabled = true;
                     return;
                 }
                 this.mRightArrow.Enabled = false;
                 return;
             }
         }
         else
         {
             this.mRightArrow.Enabled = false;
         }
         return;
     }
     if (this.mSelectedTable.SelectedItem >= 0 && this.mSelectedTable.GetRow(this.mSelectedTable.SelectedItem) != null)
     {
         this.mLeftArrow.Enabled = true;
         return;
     }
     this.mLeftArrow.Enabled = false;
 }
Ejemplo n.º 3
0
 private void RepopulateSelectedSimTable()
 {
     this.mSelectedTable.Clear();
     new List <ObjectPicker.RowInfo>();
     foreach (ObjectPicker.RowInfo current in this.mSelectedSims)
     {
         TableRow tableRow = this.mSelectedTable.CreateRow();
         DualPanelHouseholds.DualPaneSimPickerRowController rowController = new DualPanelHouseholds.DualPaneSimPickerRowController(tableRow, this.mSelectedTable, current);
         tableRow.RowController = rowController;
         this.mSelectedTable.AddRow(tableRow);
     }
 }
Ejemplo n.º 4
0
 private void OnArrowClick(WindowBase sender, UIButtonClickEventArgs eventArgs)
 {
     if (sender.ID == 99576788u)
     {
         TableRow row = this.mSelectedTable.GetRow(this.mSelectedTable.SelectedItem);
         DualPanelHouseholds.DualPaneSimPickerRowController dualPaneSimPickerRowController = row.RowController as DualPanelHouseholds.DualPaneSimPickerRowController;
         ObjectPicker.RowInfo info = dualPaneSimPickerRowController.Info;
         this.mSelectedSims.Remove(info);
     }
     else
     {
         TableRow row2 = this.mSourceTable.GetRow(this.mSourceTable.SelectedItem);
         DualPanelHouseholds.DualPaneSimPickerRowController dualPaneSimPickerRowController2 = row2.RowController as DualPanelHouseholds.DualPaneSimPickerRowController;
         ObjectPicker.RowInfo info2 = dualPaneSimPickerRowController2.Info;
         this.mSelectedSims.Add(info2);
     }
     this.mLeftArrow.Enabled  = false;
     this.mRightArrow.Enabled = false;
     this.RepopulateSourceTable();
     this.RepopulateSelectedSimTable();
 }
Ejemplo n.º 5
0
        private void RepopulateSourceTable()
        {
            int row = -1;
            int num = -1;

            this.mSourceTable.GetFirstVisibleCell(ref num, ref row);
            this.mSourceTable.Clear();
            foreach (ObjectPicker.RowInfo current in this.mSims)
            {
                if (!this.mSelectedSims.Contains(current))
                {
                    TableRow tableRow = this.mSourceTable.CreateRow();
                    DualPanelHouseholds.DualPaneSimPickerRowController dualPaneSimPickerRowController = new DualPanelHouseholds.DualPaneSimPickerRowController(tableRow, this.mSourceTable, current);
                    tableRow.RowController = dualPaneSimPickerRowController;
                    dualPaneSimPickerRowController.Enabled = true;
                    this.mSourceTable.AddRow(tableRow);
                }
            }
            this.mSourceTable.ClearSelection();
            this.mRightArrow.Enabled = false;
            this.mSourceTable.Flush();
            this.mSourceTable.ScrollRowToTop(row);
        }
Ejemplo n.º 6
0
 private void RepopulateSelectedSimTable()
 {
     this.mSelectedTable.Clear();
     new List<ObjectPicker.RowInfo>();
     foreach (ObjectPicker.RowInfo current in this.mSelectedSims)
     {
         TableRow tableRow = this.mSelectedTable.CreateRow();
         DualPanelHouseholds.DualPaneSimPickerRowController rowController = new DualPanelHouseholds.DualPaneSimPickerRowController(tableRow, this.mSelectedTable, current);
         tableRow.RowController = rowController;
         this.mSelectedTable.AddRow(tableRow);
     }
 }
Ejemplo n.º 7
0
 private void RepopulateSourceTable()
 {
     int row = -1;
     int num = -1;
     this.mSourceTable.GetFirstVisibleCell(ref num, ref row);
     this.mSourceTable.Clear();
     foreach (ObjectPicker.RowInfo current in this.mSims)
     {
         if (!this.mSelectedSims.Contains(current))
         {
             TableRow tableRow = this.mSourceTable.CreateRow();
             DualPanelHouseholds.DualPaneSimPickerRowController dualPaneSimPickerRowController = new DualPanelHouseholds.DualPaneSimPickerRowController(tableRow, this.mSourceTable, current);
             tableRow.RowController = dualPaneSimPickerRowController;
             dualPaneSimPickerRowController.Enabled = true;
             this.mSourceTable.AddRow(tableRow);
         }
     }
     this.mSourceTable.ClearSelection();
     this.mRightArrow.Enabled = false;
     this.mSourceTable.Flush();
     this.mSourceTable.ScrollRowToTop(row);
 }