[blam] Clear the item's extensions on first load
- From: Carlos Martín Nieto <cmartin src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [blam] Clear the item's extensions on first load
- Date: Wed, 23 Mar 2011 23:09:24 +0000 (UTC)
commit 4a435392a15055d08488c5f282ab16611a43fa12
Author: Carlos MartÃn Nieto <carlos cmartin tk>
Date: Thu Mar 24 00:03:25 2011 +0100
Clear the item's extensions on first load
Clear an item's extensions once it's loaded from disk. Failure to do
so will cause these values to reset on each update.
Signed-off-by: Carlos MartÃn Nieto <carlos cmartin tk>
src/Item.cs | 6 ++++++
1 files changed, 6 insertions(+), 0 deletions(-)
---
diff --git a/src/Item.cs b/src/Item.cs
index 54014d2..f09b42e 100644
--- a/src/Item.cs
+++ b/src/Item.cs
@@ -121,6 +121,12 @@ namespace Imendio.Blam {
public Item(SyndicationItem item) : base(item)
{
FillItem(item);
+ /*
+ * If we don't clear the extensions, the values will be
+ * reset on each update (Unread and ref_cnt being the most
+ * worrysome.
+ */
+ ElementExtensions.Clear();
}
public bool Update(SyndicationItem item)
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]