See ChangeLog.

Monotone-Parent: 870459b5cd89f38f2c5d579fccb19dba58515f8b
Monotone-Revision: 4d8fb1ed0734fbcfd6dc4e68194b48101ac46567

Monotone-Author: flachapelle@inverse.ca
Monotone-Date: 2012-01-30T19:59:05
This commit is contained in:
Francis Lachapelle
2012-01-30 19:59:05 +00:00
parent d9bae3cf97
commit 9f8c705eaf
14 changed files with 180 additions and 22 deletions

View File

@@ -722,7 +722,6 @@ function popupMenu(event, menuId, target) {
visibility: "visible" });
document.currentPopupMenu = popup;
$(document.body).observe("mousedown", onBodyClickMenuHandler);
}
}
@@ -1963,15 +1962,15 @@ function _showAlertDialog(label) {
dialog.appear({ duration: 0.2 });
}
function showConfirmDialog(title, label, callbackYes, callbackNo) {
function showConfirmDialog(title, label, callbackYes, callbackNo, yesLabel, noLabel) {
var div = $("bgDialogDiv");
if (div && div.visible() && div.getOpacity() > 0)
dialogsStack.push(_showConfirmDialog.bind(this, title, label, callbackYes, callbackNo));
dialogsStack.push(_showConfirmDialog.bind(this, title, label, callbackYes, callbackNo, yesLabel, noLabel));
else
_showConfirmDialog(title, label, callbackYes, callbackNo);
_showConfirmDialog(title, label, callbackYes, callbackNo, yesLabel, noLabel);
}
function _showConfirmDialog(title, label, callbackYes, callbackNo) {
function _showConfirmDialog(title, label, callbackYes, callbackNo, yesLabel, noLabel) {
var key = title;
if (Object.isElement(label)) key += label.allTextContent();
else key += label;
@@ -1988,8 +1987,8 @@ function _showConfirmDialog(title, label, callbackYes, callbackNo) {
}
else {
var fields = createElement("p");
fields.appendChild(createButton(null, _("Yes"), callbackYes));
fields.appendChild(createButton(null, _("No"), callbackNo || disposeDialog));
fields.appendChild(createButton(null, _(yesLabel || "Yes"), callbackYes));
fields.appendChild(createButton(null, _(noLabel || "No"), callbackNo || disposeDialog));
dialog = createDialog(null,
title,
label,
@@ -2098,7 +2097,7 @@ function disposeDialog() {
dialogsStack.splice(0, 1);
dialogFcn.delay(0.2);
}
else {
else if ($('bgDialogDiv')) {
var bgFade = Effect.Fade('bgDialogDiv', { duration: 0.2 });
// By the end the background fade out, a new dialog
// may need to be displayed.