diff --git a/content/list.js b/content/list.js index 9a494a0..cca98d1 100644 --- a/content/list.js +++ b/content/list.js @@ -110,7 +110,8 @@ let SnowlMessageView = { "snowlSourceCol": "source.name", "snowlAuthorCol": "author.person.name", "snowlSubjectCol": "subject", - "snowlTimestampCol": "timestamp" + "snowlTimestampCol": "timestamp", + "snowlDateReceivedCol": "received" }, Filters: {}, @@ -144,6 +145,9 @@ let SnowlMessageView = { case "snowlTimestampCol": return SnowlDateUtils._formatDate(this._collection.messages[aRow].timestamp); + case "snowlDateReceivedCol": + return SnowlDateUtils._formatDate(this._collection.messages[aRow].received); + default: return null; } @@ -593,7 +597,6 @@ let SnowlMessageView = { return; let column = aEvent.target; - let property = this._columnProperties[column.id]; let sortResource = this._tree.getAttribute("sortResource"); let sortDirection = this._tree.getAttribute("sortDirection"); diff --git a/content/list.xul b/content/list.xul index 83c2b36..451d81a 100644 --- a/content/list.xul +++ b/content/list.xul @@ -135,6 +135,11 @@ persist="width ordinal hidden sortDirection" class="sortDirectionIndicator" onclick="SnowlMessageView.onClickColumnHeader(event)"/> + + #briefHeaderRow > .headerDataSubject, #headerDeck:not([header="brief"]) > #briefHeaderRow > .headerLabelSubject { - padding-top: 8px; + padding-top: .5em; } #headerDeck[deleted] > #briefHeaderRow > .headerDataSubject > #subject{ diff --git a/locale/en-US/list.dtd b/locale/en-US/list.dtd index 4d72fa6..3757d89 100644 --- a/locale/en-US/list.dtd +++ b/locale/en-US/list.dtd @@ -4,6 +4,7 @@ + diff --git a/modules/feed.js b/modules/feed.js index 6c763b0..6486797 100644 --- a/modules/feed.js +++ b/modules/feed.js @@ -410,8 +410,8 @@ SnowlFeed.prototype = { message.source = this; message.externalID = aExternalID; message.subject = aEntry.title.text; - message.timestamp = aEntry.updated ? new Date(aEntry.updated) - : aEntry.published ? new Date(aEntry.published) + message.timestamp = aEntry.updated ? new Date(SnowlDateUtils.RFC822Date(aEntry.updated)) + : aEntry.published ? new Date(SnowlDateUtils.RFC822Date(aEntry.published)) : aEntry.fields.get("dc:date") ? ISO8601DateUtils.parse(aEntry.fields.get("dc:date")) : null; message.received = aReceived; diff --git a/modules/service.js b/modules/service.js index bd6574e..2a498c8 100644 --- a/modules/service.js +++ b/modules/service.js @@ -301,7 +301,9 @@ let SnowlService = { // TODO: Don't set busy on 'all' until we know when the last one is done // so it can be unset. // this._collectionStatsByCollectionID["all"].busy = true; -// Observers.notify("snowl:messages:completed", "refresh"); + + // Invalidate tree to show new state. + Observers.notify("snowl:messages:completed", "refresh"); } // We specify the same refresh time when refreshing sources so that all diff --git a/modules/utils.js b/modules/utils.js index 66c83b2..a6bc953 100644 --- a/modules/utils.js +++ b/modules/utils.js @@ -259,6 +259,17 @@ let SnowlDateUtils = { date.getHours(), date.getMinutes(), date.getSeconds()); + }, + + /** + * RFC822 allows for military timezones, which have since been deprecated due + * to an error in the spec; Z is unambigous so we will convert Z only to UT + * here, not the other offset chars. + * @param date {Date} the date to format + * @returns converted RFC822 date that Date understands. + */ + RFC822Date: function(date) { + return date.replace(/\b[zZ]{1}\b/, "UT"); } };