[seahorse/gnome-3-30] KeyManagerStore: Fix view filter callback
- From: Niels De Graef <nielsdg src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [seahorse/gnome-3-30] KeyManagerStore: Fix view filter callback
- Date: Sun, 16 Sep 2018 18:34:18 +0000 (UTC)
commit d09819d6e4bf0e1cd962fe8bebdf8fb4411ca455
Author: Anukul Sangwan <anukulsangwan icloud com>
Date: Sun Sep 16 20:24:09 2018 +0530
KeyManagerStore: Fix view filter callback
common/key-manager-store.vala | 14 ++++++--------
1 file changed, 6 insertions(+), 8 deletions(-)
---
diff --git a/common/key-manager-store.vala b/common/key-manager-store.vala
index f079c68f..404d8fd2 100644
--- a/common/key-manager-store.vala
+++ b/common/key-manager-store.vala
@@ -211,18 +211,16 @@ public class Seahorse.KeyManagerStore : Gcr.CollectionModel {
}
private bool apply_showfilter(GLib.Object? obj) {
- if (this.showfilter == ShowFilter.ANY)
- return true;
-
- unowned Object? object = obj as Object;
- if (object == null)
- return false;
+ Flags obj_flags = Flags.NONE;
+ obj.get("object-flags", out obj_flags, null);
switch (this.showfilter) {
case ShowFilter.PERSONAL:
- return Seahorse.Flags.PERSONAL in object.object_flags;
+ return Seahorse.Flags.PERSONAL in obj_flags;
case ShowFilter.TRUSTED:
- return Seahorse.Flags.TRUSTED in object.object_flags;
+ return Seahorse.Flags.TRUSTED in obj_flags;
+ case ShowFilter.ANY:
+ return true;
}
return false;
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]