public object Convert(object value, Type targetType, object parameter, System.Globalization.CultureInfo culture) { if ((null == value) || (false == (value is Model.ArtsResource))) { return(string.Empty); } Model.ArtsResource rsrc = value as Model.ArtsResource; string s = string.Format("{0}:{1}", rsrc.Id, rsrc.Description); return(s); }
private void reset(int backgroundId) { if (Common.Instance.IsValidSE(backgroundId)) { SelectedItem = SEList[backgroundId]; } else { if (null == SEList) { SelectedItem = null; } else if (SEList.Length > 0) { SelectedItem = SEList[0]; } else { SelectedItem = null; } } }
private void reset(int pictureId) { if (Common.Instance.IsValidPicture(pictureId)) { SelectedItem = PictureList[pictureId]; } else { if (null == PictureList) { SelectedItem = null; } else if (PictureList.Length > 0) { SelectedItem = PictureList[0]; } else { SelectedItem = null; } } }
private void reset(int miniPictureId) { if (Common.Instance.IsValidMiniPicture(miniPictureId)) { SelectedItem = MiniPictureList[miniPictureId]; } else { if (null == MiniPictureList) { SelectedItem = null; } else if (MiniPictureList.Length > 0) { SelectedItem = MiniPictureList[0]; } else { SelectedItem = null; } } }