add a style-callback to confirm

pull/1/head
ansuz 8 years ago
parent 5d88c3a436
commit 413d9a6f0b

@ -1499,7 +1499,7 @@ define([
}); });
}; };
common.confirm = function (msg, cb, opt, force) { common.confirm = function (msg, cb, opt, force, styleCB) {
opt = opt || {}; opt = opt || {};
cb = cb || function () {}; cb = cb || function () {};
if (force !== true) { msg = fixHTML(msg); } if (force !== true) { msg = fixHTML(msg); }
@ -1529,6 +1529,9 @@ define([
if (opt.reverseOrder) { if (opt.reverseOrder) {
$ok.insertBefore($ok.prev()); $ok.insertBefore($ok.prev());
} }
if (typeof(styleCB) === 'function') {
styleCB($ok.closest('.dialog'));
}
}, 0); }, 0);
}; };

Loading…
Cancel
Save