/// <summary> /// The rep key selected. /// </summary> /// <param name="selectedRepKey"> /// The selected rep key. /// </param> public void RepKeySelected(string selectedRepKey) { if (selectedRepKey == null) { return; } if (this.MultiSelectMode == false) { this.SelectedRepKeys.Clear(); this.SelectedRepKeys.Add(selectedRepKey); this.Delegate?.DidSelectRepKeys(this, this.SelectedRepKeys); } else { if (this.SelectedRepKeys.Contains(selectedRepKey) == false) { this.SelectedRepKeys.Add(selectedRepKey); } } // TODO: What to do with these? #if PORTING NSNotificationCenter.DefaultCenter().PostNotificationNameTheObject(Constants.UPMRepContanerChangeNotification, this); #endif }
/// <summary> /// The rep key deselected. /// </summary> /// <param name="deselectedRepKey"> /// The deselected rep key. /// </param> public void RepKeyDeselected(string deselectedRepKey) { if (deselectedRepKey == null) { return; } this.SelectedRepKeys.Remove(deselectedRepKey); if (this.MultiSelectMode == false) { this.Delegate?.DidSelectRepKeys(this, this.SelectedRepKeys); } #if PORTING NSNotificationCenter.DefaultCenter().PostNotificationNameTheObject(Constants.UPMRepContanerChangeNotification, this); #endif }