void mnuContextNone_Click(object sender, EventArgs e) { try { DataOperation.SetFavoriteRate(0, repMovie, ref this.dataSource); if (this.RemoveOnNoneFavorite == true) { int index = repMovie.CurrentItemIndex; DataOperation.RemoveElement(ref this.dataSource, index); this.DataSource = this.dataSource; } if (repMovie.ItemCount == 0) { MessageBox.Show(Messages.FavoriteListEmpty, Messages.MessageBoxTitle, MessageBoxButtons.OK, MessageBoxIcon.Warning); this.FindForm().Close(); } } catch (Exception ex) { MessageBox.Show(ex.Message, Messages.MessageBoxTitle, MessageBoxButtons.OK, MessageBoxIcon.Warning); } }
void mnuContextNone_Click(object sender, EventArgs e) { try { DataOperation.SetFavoriteRate(0, ref this.movie, lblFavValue); } catch (Exception ex) { MessageBox.Show(ex.Message, Messages.MessageBoxTitle, MessageBoxButtons.OK, MessageBoxIcon.Warning); } }
void mnuContext1_Click(object sender, EventArgs e) { try { DataOperation.SetFavoriteRate(1, repMovie, ref this.dataSource); } catch (Exception ex) { MessageBox.Show(ex.Message, Messages.MessageBoxTitle, MessageBoxButtons.OK, MessageBoxIcon.Warning); } }