ライブラリ更新

git-svn-id: http://www.cozmixng.org/repos/piro/treestyletab/trunk@5788 599a83e7-65a4-db11-8015-0010dcdd6dc2
This commit is contained in:
piro 2010-01-05 15:01:50 +00:00
parent 77c7e722a6
commit c121713d73

View File

@ -74,7 +74,7 @@
http://www.cozmixng.org/repos/piro/fx3-compatibility-lib/trunk/operationHistory.test.js http://www.cozmixng.org/repos/piro/fx3-compatibility-lib/trunk/operationHistory.test.js
*/ */
(function() { (function() {
const currentRevision = 9; const currentRevision = 10;
if (!('piro.sakura.ne.jp' in window)) window['piro.sakura.ne.jp'] = {}; if (!('piro.sakura.ne.jp' in window)) window['piro.sakura.ne.jp'] = {};
@ -180,11 +180,16 @@
let entry = history.entries[history.index--]; let entry = history.entries[history.index--];
if (!entry) continue; if (!entry) continue;
let done = false; let done = false;
[entry.data].concat(entry.children).forEach(function(aData) { [entry.data].concat(entry.children).forEach(function(aData, aIndex) {
let f = this._getAvailableFunction(aData.onUndo, aData.onundo, aData.undo); let f = this._getAvailableFunction(aData.onUndo, aData.onundo, aData.undo);
try { try {
if (f) { if (f) {
processed = f.call(aData); let info = {
level : aIndex,
parent : (aIndex ? entry.data : null ),
done : processed && done
};
processed = f.call(aData, info);
done = true; done = true;
} }
else { else {
@ -221,12 +226,17 @@
let entry = history.entries[++history.index]; let entry = history.entries[++history.index];
if (!entry) continue; if (!entry) continue;
let done = false; let done = false;
[entry.data].concat(entry.children).forEach(function(aData) { [entry.data].concat(entry.children).forEach(function(aData, aIndex) {
let f = this._getAvailableFunction(aData.onRedo, aData.onredo, aData.redo); let f = this._getAvailableFunction(aData.onRedo, aData.onredo, aData.redo);
let done = false; let done = false;
try { try {
if (f) { if (f) {
processed = f.call(entry.data); let info = {
level : aIndex,
parent : (aIndex ? entry.data : null ),
done : processed && done
};
processed = f.call(aData, info);
done = true; done = true;
} }
else { else {