[gnome-documents] documents: consistently measure mtime in seconds



commit fc7a9393f6c2fa9c8871cc0c9caa9e29795c4a6d
Author: Cosimo Cecchi <cosimoc gnome org>
Date:   Tue Jun 5 16:20:46 2012 -0400

    documents: consistently measure mtime in seconds
    
    Leftover from a previous refactor.

 src/documents.js |    3 +--
 1 files changed, 1 insertions(+), 2 deletions(-)
---
diff --git a/src/documents.js b/src/documents.js
index e122718..4cee29b 100644
--- a/src/documents.js
+++ b/src/documents.js
@@ -331,7 +331,7 @@ const DocCommon = new Lang.Class({
             let timeVal = GLib.time_val_from_iso8601(mtime)[1];
             this.mtime = timeVal.tv_sec;
         } else {
-            this.mtime = GLib.get_real_time();
+            this.mtime = Math.floor(GLib.get_real_time() / 1000000);
         }
 
         this.mimeType = cursor.get_string(Query.QueryColumns.MIMETYPE)[0];
@@ -1033,7 +1033,6 @@ const DocumentModel = new Lang.Class({
 
     documentAdded: function(doc) {
         let iter = this.model.append();
-
         this.model.set(iter,
             [ 0, 1, 2, 3, 4, 5 ],
             [ doc.id, doc.uri, doc.name,



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]