add support for pages asking to be reloaded from scratch
(so that SMTP prefs can be reloaded) r=sspitzer git-svn-id: svn://10.0.0.236/trunk@65117 18797224-902f-48f8-a5cc-f745e15eee43
This commit is contained in:
parent
72e181639a
commit
296a8ac3e3
@ -377,11 +377,19 @@ function showPage(serverId, pageId) {
|
||||
// page has loaded
|
||||
function onPanelLoaded(pageId) {
|
||||
if (pageId != pendingPageId) {
|
||||
dump("ERROR: page " + pageId + " was loaded, but " + pendingPageId + " was expected!\n");
|
||||
return;
|
||||
|
||||
// if we're reloading the current page, we'll assume the
|
||||
// page has asked itself to be completely reloaded from
|
||||
// the prefs. to do this, clear out the the old entry in
|
||||
// the account data, and then restore theh page
|
||||
if (pageId == currentPageId) {
|
||||
clearAccountData(currentServerId, currentPageId);
|
||||
restorePage(currentServerId, currentPageId);
|
||||
}
|
||||
} else {
|
||||
|
||||
restorePage(pendingPageId, pendingServerId);
|
||||
}
|
||||
|
||||
restorePage(pendingPageId, pendingServerId);
|
||||
|
||||
// probably unnecessary, but useful for debugging
|
||||
pendingServerId = null;
|
||||
@ -641,6 +649,11 @@ function getValueArrayFor(serverId) {
|
||||
return accountArray[serverId];
|
||||
}
|
||||
|
||||
function clearAccountData(serverId, pageId)
|
||||
{
|
||||
getValueArrayFor(serverId)[pageId] = null;
|
||||
}
|
||||
|
||||
function getServerIdAndPageIdFromTree(tree)
|
||||
{
|
||||
var serverId = null;
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user