Monday, November 08, 2010 at 12:01 AM.
system.verbs.apps.Manila.windowTypes.types.manilaMessage.close
on close (adr) {
<<Close a manila message, checking it in if necessary.
local (atts);
if not window.attributes.getAll (@atts) { //return false if no atts
return (false)};
if atts.flReadOnly { //can't be saved -- return true
return (true)};
local (adrinfo = atts.adrSiteInfo);
local (username, password);
if manila.windowTypes.getUsernameAndPassword (adrinfo, @username, @password) {
manila.windowTypes.setUsernameAndPassword (adrinfo, username, password)}
else { //the user cancelled the password dialog -- return false
return (false)};
local (siteInfoTable = adrinfo^);
siteInfoTable.username = username;
siteInfoTable.password = password;
if defined (atts.msgnum) { //check in the message
manila.message.checkIn (@siteInfoTable, atts.msgnum)};
return (true)};
bundle { //debugging
close (window.frontmost ())}
This listing is for code that runs in the OPML Editor environment. I created these listings because I wanted the search engines to index it, so that when I want to look up something in my codebase I don't have to use the much slower search functionality in my object database. Dave Winer.