public void AddItem (ExcludeItem exclude_item) { excludes.Add (exclude_item); ((ListStore)this.Model).AppendValues (exclude_item); }
private void OnExcludeItemAdded (ExcludeItem exclude_item) { exclude_view.AddItem (exclude_item); }
private void OnExcludeItemAdded (ExcludeItem item) { value = item.Value; value_entry.Text = MailFolder.GetNameForPath (item.Value); }
private void OnDialogResponse (object o, ResponseArgs args) { if (((ResponseType)args.ResponseId) == ResponseType.Ok) { ExcludeItem exclude_item = new ExcludeItem (Type, Value); switch (Type) { case ExcludeType.Path: if (!Directory.Exists (Value)) { HigMessageDialog.RunHigMessageDialog(add_exclude_dialog, DialogFlags.Modal, MessageType.Error, ButtonsType.Ok, Catalog.GetString ("Error adding path"), Catalog.GetString ("The specified path could not be found and therefore it could not be added to the list of resources excluded for indexing.")); return; } break; } if (ExcludeItemAddedEvent != null) ExcludeItemAddedEvent (exclude_item); } add_exclude_dialog.Destroy (); }
private void OnDialogResponse (object o, ResponseArgs args) { if (args.ResponseId == ResponseType.Cancel) { mail_folder_dialog.Destroy (); return; } ExcludeItem exclude_item; object obj = folder_view.GetCurrentItem (); if (obj is MailAccount) { } else if (obj is MailFolder) { MailFolder folder = (MailFolder) obj; exclude_item = new ExcludeItem (ExcludeType.MailFolder, folder.Path); if (ExcludeItemAddedEvent != null) ExcludeItemAddedEvent (exclude_item); mail_folder_dialog.Destroy (); } }