aboutsummaryrefslogtreecommitdiff
path: root/js/controllers/undo-controller.js
diff options
context:
space:
mode:
authorJon Reid2012-03-06 18:08:11 -0800
committerJon Reid2012-03-06 18:08:11 -0800
commita12603cfcfe9d82def3b972dcbcc80f1e790ad85 (patch)
treef52c7dcc837dd98d28f505696b67b94db15e4c63 /js/controllers/undo-controller.js
parent60bba95eaffa8b5c741c6c85fb84b327cd75d6c3 (diff)
parentbb6a1d82b2884b410f5859cc0c2cafd380acbe6a (diff)
downloadninja-a12603cfcfe9d82def3b972dcbcc80f1e790ad85.tar.gz
Merge remote-tracking branch 'ninja-jduran/TimelineUber' into Timeline-uber
Diffstat (limited to 'js/controllers/undo-controller.js')
-rwxr-xr-xjs/controllers/undo-controller.js17
1 files changed, 15 insertions, 2 deletions
diff --git a/js/controllers/undo-controller.js b/js/controllers/undo-controller.js
index 926803d3..19cfb6e6 100755
--- a/js/controllers/undo-controller.js
+++ b/js/controllers/undo-controller.js
@@ -71,22 +71,28 @@ exports.UndoController = Montage.create( Component, {
71 /** 71 /**
72 * Undo Queue 72 * Undo Queue
73 */ 73 */
74 _undoQueue: { value: [] }, 74 _undoQueue: { value: []},
75 75
76 undoQueue: { 76 undoQueue: {
77 get: function() { 77 get: function() {
78 return this._undoQueue; 78 return this._undoQueue;
79 },
80 set: function(value){
81 this._undoQueue = value;
79 } 82 }
80 }, 83 },
81 84
82 /** 85 /**
83 * Redo Queue 86 * Redo Queue
84 */ 87 */
85 _redoQueue: { value: [], enumerable: false }, 88 _redoQueue: { value: [], enumerable: false},
86 89
87 redoQueue: { 90 redoQueue: {
88 get: function() { 91 get: function() {
89 return this._redoQueue; 92 return this._redoQueue;
93 },
94 set: function(value){
95 this._redoQueue = value;
90 } 96 }
91 }, 97 },
92 98
@@ -202,5 +208,12 @@ exports.UndoController = Montage.create( Component, {
202 this.redoQueue.splice(0, this.redoQueue.length); 208 this.redoQueue.splice(0, this.redoQueue.length);
203 //this.redoQueue = []; 209 //this.redoQueue = [];
204 } 210 }
211 },
212
213 clearHistory:{
214 value: function(){
215 this.undoQueue.length = 0;
216 this.redoQueue.length = 0;
217 }
205 } 218 }
206}); \ No newline at end of file 219}); \ No newline at end of file