fix for #17402, stationary -> stationery.
r=alecf
major fixes for the new folder / rename folder / subscribe dialogs.
we no longer use an html select for the folder picker.
now we use cascading menu popups, like the copy and move menus.
this fixes a lot of bugs, and allows pre-flighting to finally work.
our folder data source has some new properies:
CanFileMessages, CanSubscribe, CanRename, and CanCreateSubfolders
we use these to determine what cascading menu to build, what to disable, etc.
also, nsMessenger::NewFolder() and nsMessenger::RenameFolder() were changes to
take a nsIRDFResource instead of a nsIDOMXULElement. Before we were
passing through to the back end the selected xul element, now we pass
the resource in.
other cool side effects:
in the copy & move menus, you don't get the choice to file or copy to a server, on folders
in the rename dialog, you can't pick a server, on a folder
in the new folder dialog, you can't pick the imap inbox. (* more needs to be done here.)
bugs fixed: #14773, #14254, #20599, #20646
r=alecf
a couple bullet proofing fixes to prevent some crashes reported on fullcircle
r=bienvenu
1999-12-03 08:10:09 +00:00
|
|
|
// call this from dialog onload() to set the menu item to the correct value
|
|
|
|
function MsgFolderPickerOnLoad(pickerID)
|
|
|
|
{
|
|
|
|
dump("in MsgFolderPickerOnLoad()\n");
|
|
|
|
var uri = null;
|
|
|
|
try {
|
|
|
|
uri = window.arguments[0].preselectedURI;
|
|
|
|
}
|
|
|
|
catch (ex) {
|
|
|
|
uri = null;
|
|
|
|
}
|
|
|
|
|
|
|
|
if (uri) {
|
|
|
|
dump("on loading, set titled button to " + uri + "\n");
|
|
|
|
SetTitleButton(uri,pickerID);
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
function PickedMsgFolder(selection,pickerID)
|
|
|
|
{
|
|
|
|
var selectedUri = selection.getAttribute('id');
|
|
|
|
SetTitleButton(selectedUri,pickerID);
|
|
|
|
}
|
|
|
|
|
|
|
|
function SetTitleButton(uri,pickerID)
|
|
|
|
{
|
|
|
|
var picker = document.getElementById(pickerID);
|
|
|
|
var msgfolder = GetMsgFolderFromUri(uri);
|
|
|
|
|
1999-12-04 01:43:12 +00:00
|
|
|
if (!msgfolder) return;
|
|
|
|
|
fix for #17402, stationary -> stationery.
r=alecf
major fixes for the new folder / rename folder / subscribe dialogs.
we no longer use an html select for the folder picker.
now we use cascading menu popups, like the copy and move menus.
this fixes a lot of bugs, and allows pre-flighting to finally work.
our folder data source has some new properies:
CanFileMessages, CanSubscribe, CanRename, and CanCreateSubfolders
we use these to determine what cascading menu to build, what to disable, etc.
also, nsMessenger::NewFolder() and nsMessenger::RenameFolder() were changes to
take a nsIRDFResource instead of a nsIDOMXULElement. Before we were
passing through to the back end the selected xul element, now we pass
the resource in.
other cool side effects:
in the copy & move menus, you don't get the choice to file or copy to a server, on folders
in the rename dialog, you can't pick a server, on a folder
in the new folder dialog, you can't pick the imap inbox. (* more needs to be done here.)
bugs fixed: #14773, #14254, #20599, #20646
r=alecf
a couple bullet proofing fixes to prevent some crashes reported on fullcircle
r=bienvenu
1999-12-03 08:10:09 +00:00
|
|
|
var selectedValue = null;
|
|
|
|
|
|
|
|
if (msgfolder.isServer)
|
|
|
|
selectedValue = msgfolder.name;
|
|
|
|
else
|
|
|
|
selectedValue = msgfolder.name + " on " + msgfolder.server.prettyName;
|
|
|
|
|
|
|
|
picker.setAttribute("value",selectedValue);
|
|
|
|
picker.setAttribute("uri",uri);
|
|
|
|
}
|