history wip: Updating history list after saving document
[fnpeditor.git] / modules / documentHistory / documentHistory.js
index 05cddbc..c90c879 100644 (file)
@@ -19,7 +19,7 @@ return function(sandbox) {
         historyItems.add(item);\r
         var view = new itemView(item);\r
         itemViews.push(view);\r
-        domNodes.itemList.append(view.dom);\r
+        domNodes.itemList.prepend(view.dom);\r
     }\r
     \r
     var toggleItemViews = function(toggle) {\r
@@ -81,7 +81,7 @@ return function(sandbox) {
     \r
     return {\r
         start: function() { sandbox.publish('ready'); },\r
-        setHistory: function(history) {\r
+        addHistory: function(history) {\r
             history.forEach(function(historyItem) {\r
                 addHistoryItem(historyItem);\r
             });\r