private void on_delete_selected_row_clicked(object o, EventArgs args) { int uniqueID = UtilGtk.GetSelectedRowUniqueID( treeview_load, store_load, store_load_uniqueID_col); if (uniqueID > 0) { Sqlite.Delete(false, Constants.ExecuteAutoTable, uniqueID); store_load = UtilGtk.RemoveRow(treeview_load, store_load); button_next.Sensitive = false; } }
void on_button_delete_clicked(object o, EventArgs args) { string selectedName = getSelectedName(); if (selectedName == "") { return; } if (UtilGtk.CountRows(store) <= 1) { new DialogMessage(Constants.MessageTypes.WARNING, Catalog.GetString("Sorry, cannot delete all rows.") + "\n"); return; } //treeview UtilGtk.RemoveRow(treeview_select, store); //1 delete row UtilGtk.TreeviewSelectFirstRow(treeview_select, store, true); //2 selects another row (use first) //SQL Sqlite.DeleteFromName(false, Constants.EncoderConfigurationTable, "name", selectedName); }
//if confirmed deletion, this will be called public void Delete_row_accepted() { //remove selected row from treeview store = UtilGtk.RemoveRow(treeview, store); menuCtx.Popdown(); }
public void RemoveSelectedRow() { store = UtilGtk.RemoveRow(treeview, store); }