public void ActivateFilter(int id) { FilterMenuItem item = FindFilterMenuItem(id); if (item != null) { item.Activate(); } }
public void AddFilterOption(int id, string label) { if (id < 0) { throw new ArgumentException("id", "must be >= 0"); } FilterMenuItem item = new FilterMenuItem(id, label); item.Activated += OnMenuItemActivated; menu.Append(item); if (ActiveFilterID < 0) { item.Activate(); } SetIconSensitive(EntryIconPosition.Primary, true); }
public void AddFilterOption(int id, string label) { if (id < 0) { throw new ArgumentException ("id", "must be >= 0"); } FilterMenuItem item = new FilterMenuItem (id, label); item.Activated += OnMenuItemActivated; menu.Append (item); if (ActiveFilterID < 0) { item.Activate (); } SetIconSensitive (EntryIconPosition.Primary, true); }