Compare commits

..

1464 Commits

Author SHA1 Message Date
mitesh%netscape.com
112cd3f592 Removed mapi dependency from xpfe/bootstarp
Checking in for kkhandrika@netscape.com


git-svn-id: svn://10.0.0.236/branches/MAPI_TRUNK_LANDING@107016 18797224-902f-48f8-a5cc-f745e15eee43
2001-11-01 23:38:50 +00:00
srilatha%netscape.com
0e43f0be3f Changing nsMapiHook module name to msgMapi
git-svn-id: svn://10.0.0.236/branches/MAPI_TRUNK_LANDING@106798 18797224-902f-48f8-a5cc-f745e15eee43
2001-10-31 03:21:38 +00:00
srilatha%netscape.com
2eb83bc94e New directory structure and fix for bug # 106137.
git-svn-id: svn://10.0.0.236/branches/MAPI_TRUNK_LANDING@106703 18797224-902f-48f8-a5cc-f745e15eee43
2001-10-30 19:30:18 +00:00
(no author)
eabbdbd75c This commit was manufactured by cvs2svn to create branch
'MAPI_TRUNK_LANDING'.

git-svn-id: svn://10.0.0.236/branches/MAPI_TRUNK_LANDING@104120 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-28 20:14:14 +00:00
gerv%gerv.net
13afb6d0f9 Relicensing Round 1, Take 2. Most C-like NPL files -> NPL/GPL/LGPL. Bug 98089.
git-svn-id: svn://10.0.0.236/trunk@104119 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-28 20:14:13 +00:00
myk%mozilla.org
d66bb72fd8 Fix for bug 98744: No more software error when the user clicks "remove cc" without specifying users to remove.
Fix by Jake <jake@acutex.net>.
r=myk@mozilla.org, no second review needed.


git-svn-id: svn://10.0.0.236/trunk@104118 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-28 19:49:53 +00:00
myk%mozilla.org
ec02ad7ac1 Fix for bug 73959: Make buglist.cgi display the "Show Votes" link at the bottom of the screen.
Patch by Jake <jake@acutex.net>.
r=myk@mozilla.org, no second review needed.


git-svn-id: svn://10.0.0.236/trunk@104117 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-28 19:17:27 +00:00
peterv%netscape.com
199b8bfeaa Trying to fix ports bustage with a workaround. Adding the REQUIRES from mozilla/extensions/transformiix/source/xslt/util to this one. r=Pike. a=granrose. See also bug 102138.
git-svn-id: svn://10.0.0.236/trunk@104114 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-28 16:21:39 +00:00
seawood%netscape.com
a2f908c6f4 Argh. Security doesn't need a special export target. It gets built with the rest of SeaMonkey.
git-svn-id: svn://10.0.0.236/trunk@104113 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-28 15:36:25 +00:00
waterson%netscape.com
2aa2c3314d Fix REQUIRES bustage for static build.
git-svn-id: svn://10.0.0.236/trunk@104112 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-28 15:36:20 +00:00
seawood%netscape.com
b3c8aba787 Make depend target depend upon export so that nspr headers are exported properly.
git-svn-id: svn://10.0.0.236/trunk@104111 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-28 15:32:00 +00:00
peterv%netscape.com
873de3a5c0 Trying to fix ports bustage with a workaround. Adding the REQUIRES from mozilla/extensions/transformiix/source/xml/parser to this one. r=Pike. See also bug 102138.
git-svn-id: svn://10.0.0.236/trunk@104110 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-28 14:55:30 +00:00
glazman%netscape.com
6766836155 fixing erroneous DOM 2 name for bug 101925; rs=jst
git-svn-id: svn://10.0.0.236/trunk@104109 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-28 14:11:05 +00:00
jst%netscape.com
eee64754c4 Always initalize the out parameter in CreateEvent(). r=nobody
git-svn-id: svn://10.0.0.236/trunk@104108 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-28 14:03:10 +00:00
kin%netscape.com
dc40a11ac3 Fix for bug 89236: printing is producing crash
Modified nsBlockFrame::DrainOverflowLines() so
that it reparents any floater out-of-flow frames
and their views.

r=dbaron@fas.harvard.edu  sr=waterson@netscape.com  a=pdt


git-svn-id: svn://10.0.0.236/trunk@104107 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-28 13:59:23 +00:00
peterv%netscape.com
2d8c635e96 Fix for bug 65858 (Rework XSLT sorting). r=sicking, Pike, sr=jst.
git-svn-id: svn://10.0.0.236/trunk@104106 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-28 12:58:57 +00:00
andreas.otte%primus-online.de
eb149e5f70 fix bug 99081 [ExtractPortFrom sometimes finds ports that are not there] again, this time we were not finding enough ports. Now we are checking for ? and # as additional delimiters. r=dougt@netscape.com, sr=darin@netscape.com
git-svn-id: svn://10.0.0.236/trunk@104105 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-28 10:57:06 +00:00
ccarlen%netscape.com
c083079514 Bug 87831 - Fizilla won't launch if its path contains non-ASCII char. r=ftang/sr=sfraser
git-svn-id: svn://10.0.0.236/trunk@104104 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-28 09:19:42 +00:00
hyatt%netscape.com
4ba5e07f27 Fix for 79416, document.popupNode returns wrong node. r=jag, sr=ben
git-svn-id: svn://10.0.0.236/trunk@104100 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-28 09:01:34 +00:00
aaronl%netscape.com
fca1662319 Bug 101615. Unique child ID's for accessible event targets. r=jgaunt, sr=vidur
git-svn-id: svn://10.0.0.236/trunk@104093 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-28 08:12:07 +00:00
glazman%netscape.com
3262227926 implements getComputedStyle() for float property + bad next-line argument indentation cleanup ; b=101925, r=bzbarsky, sr=jst
git-svn-id: svn://10.0.0.236/trunk@104092 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-28 07:39:41 +00:00
dbaron%fas.harvard.edu
55cff1db96 Fix OS/2 REQUIRES bustage. r=jag
git-svn-id: svn://10.0.0.236/trunk@104091 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-28 06:57:07 +00:00
curt%scruznet.com
4584b0f862 Adding ren8dot3.exe back into the installation for now.
Fixes bug #48306


git-svn-id: svn://10.0.0.236/trunk@104089 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-28 05:51:55 +00:00
pschwartau%netscape.com
b1f2be029f Initial add. Regression test for bug 101964.
git-svn-id: svn://10.0.0.236/trunk@104086 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-28 04:50:52 +00:00
katakai%japan.sun.com
d63010d71c bug 81360
Correct behavior of ResetInputState() for gtk/
Fix memory corruption problem at Resetting IME on GTK
r/sr=blizzard


git-svn-id: svn://10.0.0.236/trunk@104083 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-28 04:18:59 +00:00
mkaply%us.ibm.com
9fc231d236 Remove unused OS/2 files - we use the Windows versions now
git-svn-id: svn://10.0.0.236/trunk@104081 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-28 03:38:54 +00:00
peterlubczynski%netscape.com
8798e2a775 Fix for crash when object frame goes away but stream is still going bug 99569 r=av sr=attinasi
git-svn-id: svn://10.0.0.236/trunk@104080 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-28 03:34:53 +00:00
peterlubczynski%netscape.com
34002614aa Ignore leading and trailing whitespace for src and data attributes bug 96362 r=av sr=attinasi
git-svn-id: svn://10.0.0.236/trunk@104079 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-28 03:29:24 +00:00
jpierre%netscape.com
01e9e71530 Fix for bug 101617 - make selfserv work in multi process mode on Windows NT
git-svn-id: svn://10.0.0.236/trunk@104077 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-28 02:43:48 +00:00
mkaply%us.ibm.com
b4e74bd8ef Attempt to make OS/2 fonts work again
git-svn-id: svn://10.0.0.236/trunk@104076 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-28 02:43:02 +00:00
mkaply%us.ibm.com
643a2d5b1f OS/2 REQUIRES bustage
git-svn-id: svn://10.0.0.236/trunk@104075 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-28 02:42:47 +00:00
alecf%netscape.com
1769d28789 adding windows makefile for files added as a part of bug 102004, and bug 102085
not part of build, to be reviewed as a part of those bugs


git-svn-id: svn://10.0.0.236/trunk@104070 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-28 02:22:23 +00:00
alecf%netscape.com
c9eb80776d move default font package handling into xpfe as a part of bug 104085
not part of build, will be reviewed as a part of that bug


git-svn-id: svn://10.0.0.236/trunk@104069 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-28 02:21:13 +00:00
alecf%netscape.com
65f35fbcc6 add these files for bug 102004 - moving charset menu into xpfe components
not part of build, to be reviewed as part of that bug


git-svn-id: svn://10.0.0.236/trunk@104068 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-28 02:20:15 +00:00
mkaply%us.ibm.com
d24a777ebf OS/2 REQUIRES bustage
git-svn-id: svn://10.0.0.236/trunk@104067 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-28 02:19:29 +00:00
despotdaemon%netscape.com
1b503cba65 Pseudo-automatic update of changes made by wtc@netscape.com.
git-svn-id: svn://10.0.0.236/trunk@104064 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-28 01:52:45 +00:00
serge%netscape.com
ede8cb0735 fix bug 85701; problems using plugins [@ gtk_xtbin_init] topcrash; r=pavlov;sr=blizzard
git-svn-id: svn://10.0.0.236/trunk@104063 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-28 01:51:06 +00:00
bzbarsky%mit.edu
316ec70207 Make setting element.style.foo just parse the value instead of creating
a property:value pair and parsing that.  Speeds up setting of
element.style.top by about 5%.  Bug 99797, r=attinasi, sr=jst


git-svn-id: svn://10.0.0.236/trunk@104060 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-28 01:38:36 +00:00
pschwartau%netscape.com
dd388f7779 Warning fixes from mac build
git-svn-id: svn://10.0.0.236/trunk@104059 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-28 01:32:05 +00:00
mkaply%us.ibm.com
3eaa45e4f8 OS/2 REQUIRES bustage
git-svn-id: svn://10.0.0.236/trunk@104058 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-28 01:28:34 +00:00
wtc%netscape.com
b5d4409bdb Bugzilla bug 84035: backed out the changes to the PRMonitor functions
because some of the Mozilla client code depends on the property that
PR_EnterMonitor and PR_ExitMonitor do not call malloc, calloc, and free.
Modified Files: _pth.h, primpl.h, ptsynch.c


git-svn-id: svn://10.0.0.236/trunk@104057 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-28 01:27:07 +00:00
rogerl%netscape.com
493bc5a14d Wiped warning whining.
git-svn-id: svn://10.0.0.236/trunk@104056 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-28 01:24:38 +00:00
syd%netscape.com
e4b9e2a9dd Fix for 97249. Crash was being caused (regardless of what stack is
showing) by not carefully iterating the component list and
processing CRCs only on those XPI files that were downloaded.
r=jag, sr=dveditz.


git-svn-id: svn://10.0.0.236/trunk@104055 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-28 01:17:46 +00:00
rogerl%netscape.com
fd8415d494 Snapshot of latest fixes for expression/statement/date/boolean/types ECMA
test suite related bug fixing.


git-svn-id: svn://10.0.0.236/trunk@104054 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-28 01:16:52 +00:00
rogerl%netscape.com
1aa6f500dc Fixed crash in handling 'for (var i,p in...' - the reader didn't have a
pre-peeked token for the error report unless it was backed up.


git-svn-id: svn://10.0.0.236/trunk@104053 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-28 01:16:00 +00:00
hyatt%netscape.com
c439062786 Fix for 102066, new tab in open location dialog, r=bryner, sr=brendan
git-svn-id: svn://10.0.0.236/trunk@104052 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-28 01:15:50 +00:00
rginda%netscape.com
bab29fd350 fix seealso section
git-svn-id: svn://10.0.0.236/trunk@104037 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-28 00:43:23 +00:00
rods%netscape.com
9e77804596 Make so hitting return in text field submits form when there is a single text field and no submit
or there is a submit and the submit btn is to be included in the post data
Bug 99920 r=attinasi sr=kin a=pdt


git-svn-id: svn://10.0.0.236/trunk@104035 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-28 00:39:44 +00:00
seawood%netscape.com
8c28c75098 Track our dependencies properly by exporting before checking dependencies
git-svn-id: svn://10.0.0.236/trunk@104034 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-28 00:36:07 +00:00
rods%netscape.com
92921bbe4b Use the nsIWebProgressListener to make sure two submits do not happen
the listener is used to know when the submit got thru so it can unreg itself
Bug 85286 r=rpotts sr=kin a=pdt


git-svn-id: svn://10.0.0.236/trunk@104033 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-28 00:33:23 +00:00
dbaron%fas.harvard.edu
89236b9700 Attempting to fix OS/2 bustage by adding REQUIRES and fixing MODULE.
git-svn-id: svn://10.0.0.236/trunk@104031 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-28 00:24:55 +00:00
hyatt%netscape.com
5aa9eebddd Checking in a patch for Antoine Labour, Open Link in New Tab, r=bryner, sr=hyatt, bug #101487
git-svn-id: svn://10.0.0.236/trunk@104028 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-28 00:19:32 +00:00
kmcclusk%netscape.com
02709e4dd7 Force the backbuffer to be reallocated when the display depth is changed. bug 6061 r=karnaze sr=attinasi
git-svn-id: svn://10.0.0.236/trunk@104027 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-28 00:16:57 +00:00
hyatt%netscape.com
fe8c9753e0 Fix for 102060, enable New Tab in the UI and implement tabbrowser context menus for closing and creating tabs, add CTRL+f4 for closing tabs. r=bryner, sr=brendan
git-svn-id: svn://10.0.0.236/trunk@104023 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-28 00:10:48 +00:00
myk%mozilla.org
e970365251 Fix for bug #53612: The milestone URL appears correctly when deleting a product or a component.
Patch by Jake <jake@acutex.net>.
r=gerv@mozilla.org,myk@mozilla.org


git-svn-id: svn://10.0.0.236/trunk@104021 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-27 23:49:07 +00:00
dbaron%fas.harvard.edu
c2c2e9c121 Implement CSS2 (and CSS3 / extension) system fonts on GTK port. b=33313 r=bryner sr=blizzard, waterson
git-svn-id: svn://10.0.0.236/trunk@104020 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-27 23:44:40 +00:00
shrutiv%netscape.com
d0746d6132 Fix for bug 90968: Feature to check same domain names for mail & news
desired (r=tao)


git-svn-id: svn://10.0.0.236/trunk@104018 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-27 23:42:31 +00:00
sfraser%netscape.com
108ee42e26 Fix for bug 71718. Make Mac NSPR work on dual CPU Mac OS X macines by using MP critical regions to fix threading synchronization problems. Uses hand-rolled critical regions because the critical section API is broke on Mac OS 10.0.x. r=gordon, wtc.
git-svn-id: svn://10.0.0.236/trunk@104017 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-27 23:35:25 +00:00
shrutiv%netscape.com
e1d45093bb Fix for bug 96268: HTTP support for network installer (r=tao)
Changing UI wording to include Http.


git-svn-id: svn://10.0.0.236/trunk@104016 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-27 23:33:40 +00:00
bienvenu%netscape.com
1f4bf4cf65 fix 102002 inline images not displayed in imap messages (and view source broken) r=ducarroz, sr=mscott
git-svn-id: svn://10.0.0.236/trunk@104015 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-27 23:33:31 +00:00
zach%zachlipton.com
be4d5ef4de Partil fix for bug 102032: Fix tinderbox test errors and warnings. This patch adds some -w and use strict; work to clean up
most of the '002goodperl.t' errors.

r=Dave Miller <justdave@syndicomm.com> no 2nd review required.


git-svn-id: svn://10.0.0.236/trunk@104014 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-27 23:19:33 +00:00
kaie%netscape.com
77dd0e7ffe b=92131 r=ddrinan sr=blizzard
Enable display of all certs.


git-svn-id: svn://10.0.0.236/trunk@104006 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-27 22:48:42 +00:00
saari%netscape.com
09efa680d1 fix for PDT+, topembed, nsbranch+ bug 78857, an assertion caused by the event pool code. r=heikki, sr=jst
git-svn-id: svn://10.0.0.236/trunk@104004 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-27 22:41:40 +00:00
seawood%netscape.com
acfead8717 Yep, I'm lame. I missed a hunk. It's going around.
git-svn-id: svn://10.0.0.236/trunk@104003 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-27 22:21:49 +00:00
rods%netscape.com
ec09821e38 Part of previous checkin for Bug 99415, forgot to set this back to &PT
git-svn-id: svn://10.0.0.236/trunk@104002 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-27 22:21:38 +00:00
rjesup%wgate.com
20e4c8fea5 Bug 92575: Remaining mChildren nsAutoVoidArray changes. r=waterson, sr=jst
git-svn-id: svn://10.0.0.236/trunk@104001 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-27 22:21:37 +00:00
mscott%netscape.com
17226d0f6f Bug #99391 --> landing fix for John Marmion. display name no longer being auto generated.
r=sspitzer
sr=mscott


git-svn-id: svn://10.0.0.236/trunk@104000 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-27 22:18:45 +00:00
sfraser%netscape.com
e2ca74ff9d Include MacTypes.h via system, not user paths. r/sr=floppymoose
git-svn-id: svn://10.0.0.236/trunk@103999 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-27 22:17:36 +00:00
sfraser%netscape.com
e532eee84d Fix bug 89734 -- ensure that we pass the old update region in local, not global coordinates to InvalWindowRgn. Also cleaned up the paint flashing code, and standardized the method definitions. r=pink, sr=scc
git-svn-id: svn://10.0.0.236/trunk@103998 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-27 22:16:30 +00:00
hewitt%netscape.com
3968438eb1 95127 - dispatchEvent() doesn't return a value, r=joki, sr=hyatt
git-svn-id: svn://10.0.0.236/trunk@103997 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-27 22:15:50 +00:00
rbs%maths.uq.edu.au
08424947c6 Placeholders to just let the build go green again
git-svn-id: svn://10.0.0.236/trunk@103996 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-27 21:57:27 +00:00
rjesup%wgate.com
03d5e140b6 Bug 101710: Fix topcrash regression in Find. r=sfraser, sr=kin
git-svn-id: svn://10.0.0.236/trunk@103995 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-27 21:49:40 +00:00
pinkerton%netscape.com
abd5e43c54 correctly remove toplevel menus when hidden/collapsed attribute set. also fix assertions so they don't always show and add assertion when trying to show/hide a menu that is already in that state. r=sdagley/sr=sfraser. bug# 101795
git-svn-id: svn://10.0.0.236/trunk@103994 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-27 21:49:14 +00:00
alexsavulov%netscape.com
e2e66ee9b9 fix for bug 99948 - added rounding to pixel in CalculateSizeStandard
r= rods sr= attinasi


git-svn-id: svn://10.0.0.236/trunk@103993 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-27 21:45:14 +00:00
leaf%mozilla.org
8e72bfe3d5 Automated update
git-svn-id: svn://10.0.0.236/trunk@103992 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-27 21:43:29 +00:00
hewitt%netscape.com
2118ea4237 95127 - dispatchEvent() doesn't return a value, r=joki, sr=hyatt
git-svn-id: svn://10.0.0.236/trunk@103991 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-27 21:43:00 +00:00
dbaron%fas.harvard.edu
e946cfe315 Fix leak of widget. b=101679 r=jag sr=hyatt
git-svn-id: svn://10.0.0.236/trunk@103990 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-27 21:41:33 +00:00
morse%netscape.com
f8fced341f bug 98882, implement p3p cookie management, r=harishd,jag, sr=alecf
git-svn-id: svn://10.0.0.236/trunk@103989 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-27 21:41:26 +00:00
alexsavulov%netscape.com
3d381615a1 regression testing for tables file (bug 99948) - not affecting the build
git-svn-id: svn://10.0.0.236/trunk@103988 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-27 21:40:02 +00:00
sicking%bigfoot.com
af59ac96c2 implement a -q option that supress output of the credits header in standalone transformiix
not part of build
b=101959 r=peterv sr=jst


git-svn-id: svn://10.0.0.236/trunk@103987 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-27 21:39:08 +00:00
alexsavulov%netscape.com
80a82dde6f regression test files for tables (bugzilla bug 99948) - not affecting the build
git-svn-id: svn://10.0.0.236/trunk@103986 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-27 21:37:46 +00:00
shrutiv%netscape.com
840eb34fd8 Fix for bug 96497: Remove all Help buttons from Show Example screens for
CCK (r=tao)


git-svn-id: svn://10.0.0.236/trunk@103983 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-27 21:32:56 +00:00
hyatt%netscape.com
f6ea87bc81 Fix for 101510, crash when clicking on font dropdown in prefs. r/sr=dbaron,waterson
git-svn-id: svn://10.0.0.236/trunk@103982 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-27 21:32:44 +00:00
sicking%bigfoot.com
93aad19662 Fix crash in parameters code.
b=101946 r=peterv sr=shaver


git-svn-id: svn://10.0.0.236/trunk@103981 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-27 21:32:20 +00:00
shrutiv%netscape.com
48a21fff28 Fix for bug 96497: Remove all Help buttons from Show Example screens
for CCK.
Removing help button urls in show example screens. (r=tao)


git-svn-id: svn://10.0.0.236/trunk@103980 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-27 21:31:11 +00:00
seawood%netscape.com
4ff97f658d Turn on module dependency tracking.
Bug #59454 sr=alecf


git-svn-id: svn://10.0.0.236/trunk@103979 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-27 21:30:42 +00:00
sicking%bigfoot.com
f46a1c678e Cleanup the generate-id() xpath function implementation.
b=101672 r=peterv, Pike sr=jst


git-svn-id: svn://10.0.0.236/trunk@103978 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-27 21:30:33 +00:00
darin%netscape.com
4c0f541d76 fixes bug 52510 "HTTP handler should register as a listener for user agent
prefs changes" r=valeski,bnesse, sr=mscott


git-svn-id: svn://10.0.0.236/trunk@103976 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-27 21:26:59 +00:00
mkaply%us.ibm.com
08d95b0c8e Just get the functions in there so OS/2 builds again
git-svn-id: svn://10.0.0.236/trunk@103975 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-27 21:18:41 +00:00
despotdaemon%netscape.com
63eb42fd07 Pseudo-automatic update of changes made by endico@mozilla.org.
git-svn-id: svn://10.0.0.236/trunk@103974 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-27 21:07:05 +00:00
waterson%netscape.com
6a8ba73bf2 Bug 73235. Don't add scrollbar's width to MES. r=attinasi, sr=hyatt
git-svn-id: svn://10.0.0.236/trunk@103973 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-27 20:53:21 +00:00
dveditz%netscape.com
b233a6a501 Whitespace change to correct previous checkin comment: fix for sleeping too long
on Unix (bug 84896) contributed by Denis Antrushin <adu@sparc.spb.su> r=syd, sr=dveditz


git-svn-id: svn://10.0.0.236/trunk@103970 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-27 20:27:59 +00:00
rbs%maths.uq.edu.au
06571111c0 fix build bustage
git-svn-id: svn://10.0.0.236/trunk@103969 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-27 20:04:05 +00:00
rbs%maths.uq.edu.au
7ddac010c4 fix build bustage
git-svn-id: svn://10.0.0.236/trunk@103968 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-27 19:32:40 +00:00
rbs%maths.uq.edu.au
346ef380a5 bug 99010 - font changes. r=attinasi@netscape.com, sr=waterson@netscape.com
git-svn-id: svn://10.0.0.236/trunk@103967 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-27 18:34:30 +00:00
rbs%maths.uq.edu.au
1797500207 bug 99010 - font changes. r=attinasi@netscape.com, sr=hyatt@netscape.com
git-svn-id: svn://10.0.0.236/trunk@103966 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-27 18:33:58 +00:00
rbs%maths.uq.edu.au
5f7a58bc8f bug 99010 - font changes. r=roland.mainz@informatik.med.uni-giessen.de, sr=waterson@netscape.com
git-svn-id: svn://10.0.0.236/trunk@103965 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-27 18:32:58 +00:00
rbs%maths.uq.edu.au
19905b49c4 bug 99010 - font changes. r=pierre@netscape.com, sr=waterson@netscape.com
git-svn-id: svn://10.0.0.236/trunk@103964 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-27 18:32:31 +00:00
rbs%maths.uq.edu.au
5fae2d04d3 bug 99010 - font changes. r=katakai@japan.sun.com, sr=waterson@netscape.com
git-svn-id: svn://10.0.0.236/trunk@103963 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-27 18:31:59 +00:00
rbs%maths.uq.edu.au
8b6f6cad1e bug 99010 - font changes. r=bstell@netscape.com, sr=waterson@netscape.com
git-svn-id: svn://10.0.0.236/trunk@103962 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-27 18:31:35 +00:00
rbs%maths.uq.edu.au
a8d5942ac5 bug 99010 - font changes. r=shanjian@netscape.com,kmcclusk@netscape.com, sr=waterson@netscape.com
git-svn-id: svn://10.0.0.236/trunk@103961 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-27 18:29:59 +00:00
rbs%maths.uq.edu.au
a1d30b60c4 bug 99010 - font changes. r=shanjian@netscape.com, sr=waterson@netscape.com
git-svn-id: svn://10.0.0.236/trunk@103960 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-27 18:29:17 +00:00
rbs%maths.uq.edu.au
d44531f21e bug 99010 - font changes. sr=waterson@netscape.com
git-svn-id: svn://10.0.0.236/trunk@103959 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-27 18:28:24 +00:00
alecf%netscape.com
48a18c2b2f fix strictness and remove the clustering for now and just color visited modules
git-svn-id: svn://10.0.0.236/trunk@103958 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-27 18:02:05 +00:00
seawood%netscape.com
5a29683498 Replace File::List with homegrown rfind(). sr=alecf
not part of the pull much less the build


git-svn-id: svn://10.0.0.236/trunk@103957 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-27 17:54:10 +00:00
nicolson%netscape.com
12b2f2c4ce fix SSL_RSA_FIPS_* cipher enums.
git-svn-id: svn://10.0.0.236/trunk@103956 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-27 17:51:30 +00:00
sonja.mirtitsch%sun.com
85e93f80b9 putting new tests back, since the ciphers have been fixed again
git-svn-id: svn://10.0.0.236/trunk@103954 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-27 16:37:46 +00:00
despotdaemon%netscape.com
6f1cc97910 Pseudo-automatic update of changes made by endico@mozilla.org.
git-svn-id: svn://10.0.0.236/trunk@103953 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-27 16:34:37 +00:00
shaver%mozilla.org
e6c5757367 Backing out checkin(s) due to illegal relicensing of proprietary code.
sr=alecf, r=dawn (not part of build *cough*)


git-svn-id: svn://10.0.0.236/trunk@103949 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-27 16:22:05 +00:00
karnaze%netscape.com
e7c24ea142 new regression tests, not affecting the build.
git-svn-id: svn://10.0.0.236/trunk@103948 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-27 16:15:46 +00:00
mkaply%us.ibm.com
4490848ef7 OS/2 bustage - we don't use _System
git-svn-id: svn://10.0.0.236/trunk@103947 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-27 16:04:44 +00:00
cls%seawood.org
6028cfeac8 Semantics of NS_IMPL_THREADSAFE_ISUPPORTS* changed.
Fixing beos tinderbox bustage


git-svn-id: svn://10.0.0.236/trunk@103946 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-27 15:39:33 +00:00
nboyd%atg.com
df4f20ed0a Remove obsolete comment about serialization.
git-svn-id: svn://10.0.0.236/trunk@103945 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-27 15:14:24 +00:00
nboyd%atg.com
a0e5534fcf Add new serialization API classes.
git-svn-id: svn://10.0.0.236/trunk@103944 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-27 14:59:59 +00:00
shaver%mozilla.org
4b9d50f0ba Bug 94506: parameter named "arguments" is not accessible in JavaScript method.
Now we check for the magic "arguments" name after var-and-arg slot
optimizations. r=rogerl, sr=brendan


git-svn-id: svn://10.0.0.236/trunk@103943 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-27 14:52:14 +00:00
nboyd%atg.com
e2b9cf8160 Add docs for serialization.
git-svn-id: svn://10.0.0.236/trunk@103942 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-27 14:51:20 +00:00
nboyd%atg.com
5ead7f3139 Remove obsolete files (perhaps re-added by mistake?)
git-svn-id: svn://10.0.0.236/trunk@103941 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-27 12:59:30 +00:00
nboyd%atg.com
b2b147ed4a Patches from Igor:
Note form omj/Parser.java:

* OPT source info collection is a potential performance bottleneck;
* Source wraps a java.lang.StringBuffer, which is synchronized.  It
* might be faster to implement Source with its own char buffer and
* toString method.

It is indeed a bottleneck under JDK 1.1. When I replaced StringBuffer
by a char array (see the attached patch), execution time of
Context.compileReader decreased by 15%: to test I combined a few test
cases to get a 3MB JS source and then measured time to process it by
Context.compileReader in the interpreter mode.

Under JDK 1.3 the difference is less then 1%, but still using the explicit
string buffer saves memory. When converting StringBuffer to String Sun JDK
shares the internal char array in StringBuffer with new String, but in the
Parser case typically the capacity of this buffer is bigger then the actual
string length, so this unused space in source strings is wasted in the
interpreter mode that keeps these strings in InterpreterData.

Regards, Igor

========
I implemented that member expression as function name syntactic sugar to
support scripts using this MS extension. This is only available when
Context.hasFeature(Context.FEATURE_MEMBER_EXPR_AS_FUNCTION_NAME)
returns true to allow the deviation from the standard only when required.

The patch effectively transforms 'function <memberExpr>(...)...' to
'<memberExpr> = function(...)...' when <memberExpr> is not simple
identifier. I am not sure that MS implementation does exactly this
but hopefully it is sufficiently general to cover MS cases.

(The patch assumes that source_change.patch is already applied)

Regards, Igor


git-svn-id: svn://10.0.0.236/trunk@103940 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-27 12:51:42 +00:00
nboyd%atg.com
bcf0073005 Patch from Igor:
I implemented that member expression as function name syntactic sugar to support
scripts using this MS extension. This is only available when
Context.hasFeature(Context.FEATURE_MEMBER_EXPR_AS_FUNCTION_NAME)
returns true to allow the deviation from the standard only when required.

The patch effectively transforms 'function <memberExpr>(...)...' to
'<memberExpr> = function(...)...' when <memberExpr> is not simple identifier.
I am not sure that MS implementation does exactly this but hopefully it is
sufficiently general to cover MS cases.

(The patch assumes that source_change.patch is already applied)

Regards, Igor


git-svn-id: svn://10.0.0.236/trunk@103939 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-27 12:50:14 +00:00
jdunn%netscape.com
398e9dfa0b rulebrk.c includes this header, so we can't have c++
comment delims (//) we need to stick with c ones (/* ... */)
Fixing bustage!


git-svn-id: svn://10.0.0.236/trunk@103938 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-27 12:41:06 +00:00
locka%iol.ie
2cd0ee3ba1 Added WM_GETDLGCODE message handler so keyboard works properly when Gecko is embedded inside a dialog box. b=101571 r/sr=hyatt@netscape.com
git-svn-id: svn://10.0.0.236/trunk@103936 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-27 11:10:17 +00:00
rginda%netscape.com
82dc2646ff - venkman only -
fix mixup in breakpoint/blacklist atom


git-svn-id: svn://10.0.0.236/trunk@103935 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-27 10:40:57 +00:00
rginda%netscape.com
f4cd6049e1 - not built -
add splitter in cview.xul
list methods in seperate lines


git-svn-id: svn://10.0.0.236/trunk@103934 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-27 08:53:56 +00:00
glazman%netscape.com
b0f0ef596c alignment status in Composer was erroneous for cells into an aligned table; b=97519, r=jfrancis, sr=kin
git-svn-id: svn://10.0.0.236/trunk@103933 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-27 08:44:25 +00:00
syd%netscape.com
e869a10a49 Checking in fix for 84896. r=selmer, sr=blake.
git-svn-id: svn://10.0.0.236/trunk@103932 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-27 08:27:16 +00:00
waldemar%netscape.com
91f7f54da0 Made section headers be headings level 1 and 2 instead of 3 and 4
git-svn-id: svn://10.0.0.236/trunk@103930 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-27 05:41:50 +00:00
waldemar%netscape.com
150071e790 Miscellaneous renamings and formatting changes
git-svn-id: svn://10.0.0.236/trunk@103929 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-27 05:41:20 +00:00
waldemar%netscape.com
cd528b7805 Added optional parameters to %print-actions
git-svn-id: svn://10.0.0.236/trunk@103928 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-27 05:40:20 +00:00
waldemar%netscape.com
f9e027f813 Added support for -> covariance and contravariance
git-svn-id: svn://10.0.0.236/trunk@103927 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-27 05:39:52 +00:00
srilatha%netscape.com
f827a98db3 Checkin for backend implementation of simple MAPI prefs
Not part of the build. a=chofmann


git-svn-id: svn://10.0.0.236/trunk@103926 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-27 05:19:14 +00:00
srilatha%netscape.com
9907058bbd Checkin for implementation of MAPILogon and MAPILogoff.
Checking in for kkhandrika@netscape.com
Not part of the build. a=chofmann


git-svn-id: svn://10.0.0.236/trunk@103925 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-27 05:14:27 +00:00
brendan%mozilla.org
81ba8bd9b7 Don't report uncaught exceptions unless returning to native code (97646, r=jband, sr=shaver).
git-svn-id: svn://10.0.0.236/trunk@103924 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-27 05:04:45 +00:00
dougt%netscape.com
05f25b6893 fixing a missing } in the macro. r=sfraser@netscape.com
git-svn-id: svn://10.0.0.236/trunk@103923 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-27 04:49:38 +00:00
dougt%netscape.com
f30dca6482 Adding new files to the unix build.
git-svn-id: svn://10.0.0.236/trunk@103922 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-27 04:37:35 +00:00
dougt%netscape.com
3ae73a07eb reverting 99248. r=shaver|brendan@mozilla.org
git-svn-id: svn://10.0.0.236/trunk@103921 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-27 03:52:45 +00:00
srilatha%netscape.com
61d4844b30 Checkin for implementation of MAPILogon and MAPILogoff.
Checking in for kkhandrika@netscape.com
Not part of the build. a=chofmann


git-svn-id: svn://10.0.0.236/trunk@103920 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-27 03:51:23 +00:00
dougt%netscape.com
997cb851e1 Landing nsISupports changes. Freezes nsISupports.idl and nsrootidl.idl. r=valeski@netscape.com, sr=rpotts@netscape.com bug 98281
git-svn-id: svn://10.0.0.236/trunk@103919 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-27 03:43:00 +00:00
srilatha%netscape.com
003216efa5 Checkin for implementation of MAPILogon and MAPILogoff.
Checking in for kkhandrika@netscape.com
Not part of the build. a=chofmann


git-svn-id: svn://10.0.0.236/trunk@103918 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-27 03:24:19 +00:00
naving%netscape.com
6b588d4aba 93968 100037 r=bienvenu sr=sspitzer. Ask for confirmation dialog for folders that have an
associated filter and warn user if folder is renamed/deleted/moved. Also fixed
some of D&D folder problems and cleaned up the stringBundle code in base/util.


git-svn-id: svn://10.0.0.236/trunk@103917 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-27 02:47:03 +00:00
nboyd%atg.com
10c183d386 Add support for serialization and deserialization.
git-svn-id: svn://10.0.0.236/trunk@103916 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-27 02:33:51 +00:00
hewitt%netscape.com
ba5e552780 101775 - column reordering doesn't work right, r=blake, sr=hyatt
git-svn-id: svn://10.0.0.236/trunk@103915 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-27 02:22:27 +00:00
bienvenu%netscape.com
985a47d9e6 making go offline more robust in the face of errors r=naving sr=sspitzer 101712
git-svn-id: svn://10.0.0.236/trunk@103913 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-27 02:18:58 +00:00
darin%netscape.com
5db340c9cc fixes bug 95768 "about: services should be converted to XHTML 1.1"
patch=alexey@ihug.com.au, r=cbiesinger@web.de, sr=darin,jst


git-svn-id: svn://10.0.0.236/trunk@103911 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-27 01:42:06 +00:00
tor%cs.brown.edu
d2ce60b6bc Bug 98252 - assume 8-bit alpha channels are really 0- or 1-bit until
proven otherwise.  r=rjesup,pavlov, sr=attinasi


git-svn-id: svn://10.0.0.236/trunk@103909 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-27 01:16:59 +00:00
kmcclusk%netscape.com
86a48adb0f Check for null scrolled view before accessing it. b=98270 patch from duraid@fl.net.au. r=karnaze@netscape.com, sr=attinasi@netscape.com
git-svn-id: svn://10.0.0.236/trunk@103908 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-27 01:05:14 +00:00
despotdaemon%netscape.com
973c0866c2 Pseudo-automatic update of changes made by jpierre@netscape.com.
git-svn-id: svn://10.0.0.236/trunk@103907 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-27 01:04:42 +00:00
morse%netscape.com
c5c19032e1 bug 101637, expire master password after each time it is used, r=pchen, sr=alecf
git-svn-id: svn://10.0.0.236/trunk@103906 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-27 00:46:26 +00:00
dbaron%fas.harvard.edu
830d253373 Fix build bustage. Not part of the default build. b=99248
git-svn-id: svn://10.0.0.236/trunk@103905 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-27 00:43:32 +00:00
shrutiv%netscape.com
9fccd67e47 Fix for bug 101452: Too much of disk space for CCK Linux config (r=tao)
Removing gzip command


git-svn-id: svn://10.0.0.236/trunk@103901 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-27 00:31:02 +00:00
beard%netscape.com
f0c25d3bd0 Fix for bug #92322, changes for Carbon/Mac OS X, r=peterl, sr=sfraser.
git-svn-id: svn://10.0.0.236/trunk@103900 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-27 00:29:39 +00:00
hyatt%netscape.com
a9b69df28b Fix for 101554. r/sr=jag,blake
git-svn-id: svn://10.0.0.236/trunk@103899 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-27 00:27:26 +00:00
dbaron%fas.harvard.edu
fbe51bf547 Add list of good regression test pages on the net. Not part of the build
git-svn-id: svn://10.0.0.236/trunk@103896 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-27 00:13:52 +00:00
dbaron%fas.harvard.edu
cfbac1b525 Add list of good regression test pages on the net. Not part of the build
git-svn-id: svn://10.0.0.236/trunk@103889 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-27 00:04:07 +00:00
darin%netscape.com
6d77edd2ab fixes bug 101832 "back/forward buttons should use LOAD_NORMAL + VALIDATE_NEVER"
r=gagan, sr=rpotts


git-svn-id: svn://10.0.0.236/trunk@103888 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-27 00:03:26 +00:00
gerv%gerv.net
c0a0d2c72e Added back accidentally-removed contributor. Thanks to brade for spotting this.
git-svn-id: svn://10.0.0.236/trunk@103886 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-27 00:02:49 +00:00
darin%netscape.com
0647f49077 fixes bug 101602 "IBM accessibility Proxy server not responding correctly"
r=gagan, sr=mscott


git-svn-id: svn://10.0.0.236/trunk@103885 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-26 23:59:18 +00:00
waterson%netscape.com
a330fa9287 Back out chak's changes to mfcembed until we can separate the PSM stuff out.
git-svn-id: svn://10.0.0.236/trunk@103884 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-26 23:58:44 +00:00
dbaron%fas.harvard.edu
ffa8fd5f09 Ignore all regression test output. Not part of build.
git-svn-id: svn://10.0.0.236/trunk@103883 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-26 23:57:07 +00:00
ftang%netscape.com
c30d408bd2 fix bug 101434. ignore "UTF-16"xx and "UTF-32"xx in mime while it is impossible
to get that value
while it is really UTF-16 and UTF-32.
r=bienvenu@netscape.com
sr=mscott


git-svn-id: svn://10.0.0.236/trunk@103882 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-26 23:32:58 +00:00
darin%netscape.com
cb316be863 fixes bug 82873 "improved support for HTTP trailers" r=gagan, sr=mscott
git-svn-id: svn://10.0.0.236/trunk@103880 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-26 23:30:28 +00:00
darin%netscape.com
cabe15424d fixes bug 98262 "pages show up blank - avoid sending blank Accept-Charset header"
r=gagan, sr=mscott


git-svn-id: svn://10.0.0.236/trunk@103877 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-26 23:25:10 +00:00
despotdaemon%netscape.com
ee004a643d Pseudo-automatic update of changes made by alexsavulov@netscape.com.
git-svn-id: svn://10.0.0.236/trunk@103876 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-26 23:10:52 +00:00
eddyk%netscape.com
0f77583875 Bug 96153: disable locked prefs for addressing panel in AccountManager
r=srilatha, sr=blake,alecf


git-svn-id: svn://10.0.0.236/trunk@103873 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-26 22:57:41 +00:00
waterson%netscape.com
5d084dbd37 Back out chak until he can figure out how to build w/o necessarily requiring PSM.
git-svn-id: svn://10.0.0.236/trunk@103872 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-26 22:56:25 +00:00
eddyk%netscape.com
6c0dfc05de Bug 96152: disable locked prefs for drafts and templates in AccountManager
r=bhuvan sr=alecf


git-svn-id: svn://10.0.0.236/trunk@103871 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-26 22:56:24 +00:00
andreww%netscape.com
8646677864 bugzilla 94794 - splitter alignment issue in mac classic. sr=hewitt, r=hwaara
git-svn-id: svn://10.0.0.236/trunk@103867 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-26 21:08:46 +00:00
alecf%netscape.com
7d47ce699b add unix makefiles for unicharutil_s (not part of build!)
git-svn-id: svn://10.0.0.236/trunk@103866 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-26 21:06:46 +00:00
seawood%netscape.com
4f28621d5b Update module deps. Adding timer & uriloader to REQUIRES for accessible.
git-svn-id: svn://10.0.0.236/trunk@103865 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-26 21:03:18 +00:00
alecf%netscape.com
84c6927992 arrghh...missed this file 100214 sr=sfraser, r=jag
git-svn-id: svn://10.0.0.236/trunk@103864 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-26 20:59:25 +00:00
alecf%netscape.com
ae864ff1f5 first cut at case-insensitive wrappers for ns*Strings - not part of build
git-svn-id: svn://10.0.0.236/trunk@103863 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-26 20:53:57 +00:00
morse%netscape.com
501782c47e image blocking problem, back out previous patch, r=bryner, sr=alecf
git-svn-id: svn://10.0.0.236/trunk@103862 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-26 20:49:59 +00:00
morse%netscape.com
851853222e bug 94590, remove dup entries from wallet preview dialog, r=law, sr=alecf
git-svn-id: svn://10.0.0.236/trunk@103861 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-26 20:40:11 +00:00
bzbarsky%mit.edu
0780568d3e Change observes= to command=. Bug 39389 (view source context menus).
sr=blake, r=doron


git-svn-id: svn://10.0.0.236/trunk@103860 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-26 20:38:01 +00:00
mitesh%netscape.com
c4935abc36 Additional Fix for bug 99515 - nsAutoConfig event loop hanging. r=danm and sr=alecf
git-svn-id: svn://10.0.0.236/trunk@103859 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-26 20:28:45 +00:00
alecf%netscape.com
3af4e8c8ed beginning of bug 100214 - eliminate encoding-insensitive nsCRT::str*cmp uses by properly converting to unicode. r=jag, sr=sfraser
git-svn-id: svn://10.0.0.236/trunk@103858 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-26 20:26:14 +00:00
cmanske%netscape.com
b49c405a3a Fixed setting default button to Ok after typing color in colorpicker, b=99485, r=brade, sr=kin
git-svn-id: svn://10.0.0.236/trunk@103857 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-26 20:18:42 +00:00
alecf%netscape.com
0a278b6afc bug 101761 - clean up embed components so we can better understand REQUIRES r=cls
git-svn-id: svn://10.0.0.236/trunk@103856 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-26 20:17:35 +00:00
alecf%netscape.com
d6ca828781 bug 101761 - split necko MODULE into necko and necko2 (build-system only change - for REQUIRES purposes only) r=cls
git-svn-id: svn://10.0.0.236/trunk@103855 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-26 20:13:43 +00:00
locka%iol.ie
b36c32bcaa Missing documentation. Should gone in with b=99181 but didn't.
git-svn-id: svn://10.0.0.236/trunk@103854 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-26 20:13:26 +00:00
bienvenu%netscape.com
1e205b3195 remove unused, unneeded code rs=sspitzer, no bug
git-svn-id: svn://10.0.0.236/trunk@103853 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-26 20:05:27 +00:00
chak%netscape.com
d27cc87e85 Fix for #94974 - Provide an interface for embeddors to access security info
r=rpotts,thayes
sr=rpotts


git-svn-id: svn://10.0.0.236/trunk@103852 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-26 19:57:34 +00:00
chak%netscape.com
f13cc682dd Fix for #94974 - Provide an interface for embeddors to access security info
r=rpotts,thayes
sr=rpotts


git-svn-id: svn://10.0.0.236/trunk@103851 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-26 19:52:20 +00:00
cmanske%netscape.com
1c1d2625f0 Fixed nsIOService::ResolveRelativePath problem when basePath ends in '/', b=97682, r=andreas.otte@primus-online.de, sr=dougt
git-svn-id: svn://10.0.0.236/trunk@103848 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-26 19:34:11 +00:00
yokoyama%netscape.com
0f422044d8 Bug 90910
Allocate correct size of buffer in BYTE for IME
Composition String.
/r=shanjian; /sr=waterson


git-svn-id: svn://10.0.0.236/trunk@103847 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-26 19:33:19 +00:00
radha%netscape.com
d4d61c67af Fix for bug 89309. Reload on a post resut simply rerenders the page without taking user's permission to repost the data to the server. r=darin sr=rpotts
git-svn-id: svn://10.0.0.236/trunk@103846 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-26 19:33:14 +00:00
locka%iol.ie
ff866b20b5 Fix for focus & tabbing problems in the ActiveX control. b=88081 r=saari@netscape.com sr=rpotts@netscape.com
git-svn-id: svn://10.0.0.236/trunk@103845 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-26 19:27:33 +00:00
bzbarsky%mit.edu
a241b1d09e Add a context menu to viewsource. Bug 39389, patch by Doron
<doronr@naboonline.com>, r=bzbarsky, sr=alecf


git-svn-id: svn://10.0.0.236/trunk@103844 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-26 19:25:10 +00:00
sfraser%netscape.com
acf8156525 Fix for bug 99497. Re-order processing of jar.mn files so that we register en-mac locales after those for other platforms, so that non-installed builds (like the Mac OS X build) get Mac overlays. r=tao, sr=alecf.
git-svn-id: svn://10.0.0.236/trunk@103843 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-26 19:24:52 +00:00
ccarlen%netscape.com
6a9c29eb52 Bug 96543 - Make nsWebBrowserFind default to searching in all frames. r=valeski/sr=sfraser
git-svn-id: svn://10.0.0.236/trunk@103840 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-26 14:07:35 +00:00
rods%netscape.com
fffbeb35b8 Enables the configuration of headers and footers, via 6 string in the nsIPrintOptions
3 for the header and 3 for the footer.
The new codes are &T,&U,&D,&P,&PT (see bug for explanation)
Bug 99415 r=kmcclusk, sr=attinasi a=pdt


git-svn-id: svn://10.0.0.236/trunk@103839 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-26 14:01:26 +00:00
rods%netscape.com
b6238f63da pass back the proper errors codes, instead of just a null devspec
Bug 101514 r=karnazr sr=kin


git-svn-id: svn://10.0.0.236/trunk@103838 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-26 14:00:30 +00:00
karnaze%netscape.com
84205c2f3e Fix bug "IFrames repositioned by whitespace in HTML" (no number yet) - give cols with no content 0 width unless they have style width, sr=kin, r=alexsavulov
git-svn-id: svn://10.0.0.236/trunk@103837 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-26 13:49:26 +00:00
rginda%netscape.com
03283a8bec - not built -
move from <tree>s to <outliner>s, leaning on recent venkman outliner work.


git-svn-id: svn://10.0.0.236/trunk@103833 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-26 08:56:06 +00:00
rginda%netscape.com
51a6720d7c - not built -
add outliner files and new icons to .jar file


git-svn-id: svn://10.0.0.236/trunk@103832 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-26 08:55:09 +00:00
rginda%netscape.com
63012407bb - not built -
initial add of new cview icons


git-svn-id: svn://10.0.0.236/trunk@103831 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-26 08:54:27 +00:00
rginda%netscape.com
f9e30f1aa0 - not built -
initial add of cview outliner files


git-svn-id: svn://10.0.0.236/trunk@103830 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-26 08:53:26 +00:00
glazman%netscape.com
cdfc6fee4e Tables with borders inside of tables without borders got red dotted borders instead of the specified style because of laxist css rule in EditorContent.css; b=96354, r=jag, sr=kin
git-svn-id: svn://10.0.0.236/trunk@103829 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-26 07:37:51 +00:00
bryner%netscape.com
4565bd1e93 removing a printf. rs=sfraser.
git-svn-id: svn://10.0.0.236/trunk@103820 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-26 06:05:38 +00:00
dveditz%netscape.com
daa59eac19 bug 92222 -- get xpinstall wizard building on IRIX. patch thanks to
johnv@adacel.com.au (John Mark Vandenberg), r=me, sr=kin@netscape.com


git-svn-id: svn://10.0.0.236/trunk@103819 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-26 05:55:51 +00:00
rginda%netscape.com
6c325e0769 - venkman only -
package new icons


git-svn-id: svn://10.0.0.236/trunk@103817 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-26 05:48:57 +00:00
rginda%netscape.com
fe8af60bf8 - venkman only -
add appendChildren method


git-svn-id: svn://10.0.0.236/trunk@103816 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-26 05:47:11 +00:00
rginda%netscape.com
0231deab44 - venkman only -
remove "reload ui" string, added "reload"


git-svn-id: svn://10.0.0.236/trunk@103815 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-26 05:45:38 +00:00
dbaron%fas.harvard.edu
8a6246f392 Add PR-logging and assertions used to find bug 94979. r=bbaetz rs=darin, dougt
git-svn-id: svn://10.0.0.236/trunk@103814 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-26 05:21:12 +00:00
mscott%netscape.com
a6a8b25b54 Bug #9178 --> when migrating an account be sure to not call get default server. Instead,
create a new smtp server then set the migrated smtp settings on that new server.

r=bhuvan
sr=sspitzer


git-svn-id: svn://10.0.0.236/trunk@103813 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-26 05:11:58 +00:00
nelsonb%netscape.com
1de7774248 Fix the 128-bit block encrypt and decrypt functions for unaligned buffers.
git-svn-id: svn://10.0.0.236/trunk@103808 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-26 04:24:29 +00:00
nelsonb%netscape.com
473503a731 Correct the test for length of data in SSL channel info struct.
git-svn-id: svn://10.0.0.236/trunk@103807 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-26 04:22:55 +00:00
dbradley%netscape.com
852b750761 Bug 94859 silence compiler warning about unused variable r=rginda, sr=jband
git-svn-id: svn://10.0.0.236/trunk@103806 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-26 04:11:54 +00:00
bienvenu%netscape.com
48e824fcd0 fix memory leak of nsImapProtocol and nsImapFlagAndUidState r=naving,sspitzer, sr=mscott,sspitzer 50529 101261
git-svn-id: svn://10.0.0.236/trunk@103801 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-26 03:44:56 +00:00
mcafee%netscape.com
8162744139 Ack! this patch never made it in. Force dynamic library for static build to install properly. (87213) r=cathleen, sr=waterson
git-svn-id: svn://10.0.0.236/trunk@103798 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-26 02:47:04 +00:00
peterlubczynski%netscape.com
0890a85240 Clean up code in part for fix for doing GET rather than POST when NPN_PostURL is called bug 77603 r=av sr=attinasi
git-svn-id: svn://10.0.0.236/trunk@103797 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-26 02:45:20 +00:00
peterlubczynski%netscape.com
101be19de3 Fix for doing GET rather than POST when NPN_PostURL is called bug 77603 r=av sr=attinasi
git-svn-id: svn://10.0.0.236/trunk@103796 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-26 02:45:01 +00:00
shanjian%netscape.com
50674e829e #8664 Debug messages in terminal window on Linux Japanese build.
r=bstell sr=waterson


git-svn-id: svn://10.0.0.236/trunk@103795 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-26 02:38:34 +00:00
sspitzer%netscape.com
ce9a0f46c4 fix for #101421. the radiogroups in the mailnews pref panel and in search
and filters are supposed to be horizontal.  rs=bienvenu


git-svn-id: svn://10.0.0.236/trunk@103794 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-26 02:38:28 +00:00
justdave%syndicomm.com
1d6aad753c Fix for bug 101659: emailsuffix was missing from the component owner mailto tag on sites that use emailsuffix.
Patch by Steve Naldrett <snaldrett@transparentnetworks.com>
r= justdave@syndicomm.com x2


git-svn-id: svn://10.0.0.236/trunk@103793 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-26 02:37:29 +00:00
idk%eng.sun.com
8e55de7d8a *not part of the build*
tiny fix for solaris build.


git-svn-id: svn://10.0.0.236/trunk@103791 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-26 01:52:11 +00:00
pschwartau%netscape.com
ea654dfd73 Adding comments from contributor.
git-svn-id: svn://10.0.0.236/trunk@103787 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-26 01:15:14 +00:00
alecf%netscape.com
8154535363 other file I missed - use NS_LITERAL_STRING instead of char* because API changed
git-svn-id: svn://10.0.0.236/trunk@103786 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-26 01:14:37 +00:00
despotdaemon%netscape.com
94d894ff03 Pseudo-automatic update of changes made by seawood@netscape.com.
git-svn-id: svn://10.0.0.236/trunk@103785 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-26 01:12:00 +00:00
alecf%netscape.com
e1220d60f7 oops missed this file - use NS_LITERAL_STRING now that API has changed
git-svn-id: svn://10.0.0.236/trunk@103784 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-26 01:10:14 +00:00
shrutiv%netscape.com
0f3ba5dc3c Fix for bug 99403: Browser Windows Title bar text does not show up on build
(r=tao)


git-svn-id: svn://10.0.0.236/trunk@103783 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-26 01:06:53 +00:00
sspitzer%netscape.com
6147611fba fix for #101640, to allow cavin to finish #14295. if a server is removed
or if a server "changes" notify the incoming server listeners.  for the three pane
listener, we use that to decide if we need to change our selection.
r=cavin, sr=bienvenu


git-svn-id: svn://10.0.0.236/trunk@103782 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-26 01:01:49 +00:00
shrutiv%netscape.com
9efa3d3bf8 Fix for bug 96268: HTTP support for network installer (r=tao)
git-svn-id: svn://10.0.0.236/trunk@103781 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-26 01:00:27 +00:00
pschwartau%netscape.com
1036074531 Correcting some typos.
git-svn-id: svn://10.0.0.236/trunk@103780 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-26 00:58:35 +00:00
naving%netscape.com
4b112f978b 101057 r=robinf, bienvenu sr=sspitzer Add error messages when compact fails because of insufficient disk space or writing to folder failed.
git-svn-id: svn://10.0.0.236/trunk@103779 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-26 00:48:35 +00:00
gerv%gerv.net
a768cdf897 License changes, take 2. Bug 98089. mozilla/intl/ (part 2).
git-svn-id: svn://10.0.0.236/trunk@103778 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-26 00:47:52 +00:00
gerv%gerv.net
cf694b8116 License changes, take 2. Bug 98089. mozilla/include/, /mozilla/htmlparser/, /mozilla/intl/ (part 1).
git-svn-id: svn://10.0.0.236/trunk@103776 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-26 00:40:45 +00:00
alecf%netscape.com
3adcd56b31 bug 101562 - dont' use necko to unnecessarily create URIs just to load a string bundle. r=harishd, sr=attinasi
git-svn-id: svn://10.0.0.236/trunk@103775 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-26 00:36:45 +00:00
hewitt%netscape.com
3a4529b94a 9656 - outliner column drag and drop rearranging, r=sspitzer, sr=hyatt
git-svn-id: svn://10.0.0.236/trunk@103774 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-26 00:33:48 +00:00
pschwartau%netscape.com
0a5a3fe028 Initial add. Regression test for bug 101488.
git-svn-id: svn://10.0.0.236/trunk@103773 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-26 00:32:11 +00:00
rangansen%netscape.com
c7436e62c7 bug# 100457; r=ddrinan; r=nelsonb; r=blizzard;
sr=blizzard; Patch to put in proper handling of unrecognized
cert errors in psm


git-svn-id: svn://10.0.0.236/trunk@103772 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-26 00:28:24 +00:00
gerv%gerv.net
42bc96966b Use vendor-neutral version of translation UI from Alis Technologies. Bug 77207. r=hwaara, sr=shaver.
git-svn-id: svn://10.0.0.236/trunk@103771 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-26 00:19:34 +00:00
gerv%gerv.net
1336d4c729 License changes, take 2. Bug 98089. mozilla/gfx/.
git-svn-id: svn://10.0.0.236/trunk@103770 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-26 00:16:04 +00:00
bryner%netscape.com
2a42400611 Bug 100921 - cannot tab into certain dialog fields. wrap-around of tabbing within a single document had regressed. r=saari, sr=hyatt.
git-svn-id: svn://10.0.0.236/trunk@103767 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-26 00:03:57 +00:00
hewitt%netscape.com
b362d1d395 93519 - new box-ordinal-group xul layout feature, r=waterson, sr=hyatt
git-svn-id: svn://10.0.0.236/trunk@103766 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-25 23:35:36 +00:00
dougt%netscape.com
15aec61064 uses strtok_r if avaliable. r=doug/cls, sr=rpotts, patch by drepper@cygnus.com. bug 99248
git-svn-id: svn://10.0.0.236/trunk@103764 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-25 23:31:27 +00:00
gerv%gerv.net
f2fd909b29 License changes, take 2. Bug 98089. mozilla/extensions/.
git-svn-id: svn://10.0.0.236/trunk@103763 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-25 23:31:24 +00:00
nelsonb%netscape.com
a91e3f73be Add a few new OIDs for AES and one old semi-bogus OID for DSA. 55048.
git-svn-id: svn://10.0.0.236/trunk@103762 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-25 23:29:30 +00:00
mkaply%us.ibm.com
795e0731ff #100300
r=pedemont, sr=blizzard
OS/2 only - new filepicker based on OS/2 file dialog - remove old stuff


git-svn-id: svn://10.0.0.236/trunk@103761 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-25 23:03:21 +00:00
mkaply%us.ibm.com
fb03e71231 #100300
r=pedemont, sr=blizzard
OS/2 only - new filepicker based on OS/2 file dialog


git-svn-id: svn://10.0.0.236/trunk@103760 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-25 23:01:57 +00:00
jgaunt%netscape.com
20839ce556 bug 100772 bug 98777 accessible support for XUL
Description, Label, Button
r=aaronl sr=hyatt


git-svn-id: svn://10.0.0.236/trunk@103759 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-25 22:59:55 +00:00
gerv%gerv.net
aade3081c8 License changes, take 2. Bug 98089. mozilla/embedding/.
git-svn-id: svn://10.0.0.236/trunk@103758 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-25 22:58:40 +00:00
gerv%gerv.net
3821428085 License changes, take 2. Bug 98089. mozilla/editor/.
git-svn-id: svn://10.0.0.236/trunk@103757 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-25 22:53:13 +00:00
jgaunt%netscape.com
b05231e968 bug 100772 and bug 98777 - accessibility support for XUL Descriptions, Labels and Buttons
idl and mac mcp files only -- missed something in the mcp
r=aaronl sr=hyatt


git-svn-id: svn://10.0.0.236/trunk@103756 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-25 22:46:23 +00:00
gerv%gerv.net
612ee840db License changes, take 2. Bug 98089. mozilla/dom/.
git-svn-id: svn://10.0.0.236/trunk@103755 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-25 22:43:09 +00:00
loadrunner%betak.net
4903a65bff bug 97541, r=cmanske, sr=kin, Enable multiple spellcheckers in mail/composer
git-svn-id: svn://10.0.0.236/trunk@103754 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-25 22:41:49 +00:00
jgaunt%netscape.com
eeb62b09a4 bug 100772 and bug 98777 - accessibility support for XUL Descriptions, Labels and Buttons
idl and mac mcp files only
r=aaronl sr=hyatt


git-svn-id: svn://10.0.0.236/trunk@103753 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-25 22:41:10 +00:00
loadrunner%betak.net
4035039e1e bug 95541, r=cmanske, sr=kin, Enable multiple spellcheckers in mail/composer
git-svn-id: svn://10.0.0.236/trunk@103752 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-25 22:39:47 +00:00
rginda%netscape.com
77ae4c5463 - venkman only -
remove duplicate rule
add blacklist rules


git-svn-id: svn://10.0.0.236/trunk@103751 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-25 22:32:56 +00:00
aaronl%netscape.com
788d349827 Bug 98781. Active Accessibility: XUL <image> element support. sr=hyatt, r=jgaunt
git-svn-id: svn://10.0.0.236/trunk@103750 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-25 22:32:32 +00:00
rginda%netscape.com
7e095bbaca - venkman only -
change prefixes for ETRACE and ERROR messages, make ERROR background color easier on the eyes


git-svn-id: svn://10.0.0.236/trunk@103749 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-25 22:32:10 +00:00
rginda%netscape.com
af9a89c033 - venkman only -
add version and blacklist strings


git-svn-id: svn://10.0.0.236/trunk@103748 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-25 22:31:07 +00:00
rginda%netscape.com
7af8a20e87 - venkman only -
add reload command
add comments


git-svn-id: svn://10.0.0.236/trunk@103747 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-25 22:30:02 +00:00
rginda%netscape.com
83fe864efe - venkman only -
add version info
implement enable/disableReloadCommand


git-svn-id: svn://10.0.0.236/trunk@103746 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-25 22:28:57 +00:00
rginda%netscape.com
c03b22464f - venkman only -
move debugger menu item from tasks to tasks->tools


git-svn-id: svn://10.0.0.236/trunk@103745 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-25 22:27:36 +00:00
rginda%netscape.com
96b60b0799 - venkman only -
add blacklist nodes, not reflected in the UI yet
implement reloadSource on SourceRecord, to reload the underlying source text


git-svn-id: svn://10.0.0.236/trunk@103744 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-25 22:26:51 +00:00
rginda%netscape.com
969e91ec56 - venkman only -
add blacklist and version strings


git-svn-id: svn://10.0.0.236/trunk@103743 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-25 22:25:21 +00:00
rginda%netscape.com
5243423bff - venkman only -
implement reload command


git-svn-id: svn://10.0.0.236/trunk@103742 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-25 22:24:36 +00:00
rginda%netscape.com
c6b4ff2a01 - venkman only -
add type checking to formatValue, fix bug in formatValue -> array


git-svn-id: svn://10.0.0.236/trunk@103741 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-25 22:23:41 +00:00
rginda%netscape.com
004f80ebea - venkman only -
pass drag and drop related events to the TOViewRecord, if it knows how to deal


git-svn-id: svn://10.0.0.236/trunk@103740 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-25 22:22:02 +00:00
hyatt%netscape.com
371741758e backing out 94836, since it did not have UI review.
git-svn-id: svn://10.0.0.236/trunk@103739 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-25 22:21:47 +00:00
dougt%netscape.com
dd310a2b40 protects against crash when calling smprintf with a null argument. r=me, sr=darin@netscape. patch submitted by risto.kankkunen@iki.fi. bug number 100293.
git-svn-id: svn://10.0.0.236/trunk@103738 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-25 22:21:14 +00:00
rginda%netscape.com
3d9f84418c - venkman only -
initial add of blacklist icons


git-svn-id: svn://10.0.0.236/trunk@103737 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-25 22:20:29 +00:00
depstein%netscape.com
d50afb9d7b added stopALL flag for nsIWebNav->Stop().
git-svn-id: svn://10.0.0.236/trunk@103736 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-25 22:20:25 +00:00
hwaara%chello.se
c991f5b6c8 #94180, fix regression from XUL 1.0 change: make alternative 3pane's grippy be center-aligned.
r=stephend, sr=sspitzer.


git-svn-id: svn://10.0.0.236/trunk@103735 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-25 22:18:11 +00:00
hewitt%netscape.com
aa358ac974 9656 - outliner column drag and drop rearranging, r=sspitzer, sr=hyatt
git-svn-id: svn://10.0.0.236/trunk@103734 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-25 22:17:47 +00:00
hewitt%netscape.com
f15e8fc2e2 93519 - new box-ordinal-group xul layout feature, r=waterson, sr=hyatt
git-svn-id: svn://10.0.0.236/trunk@103733 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-25 22:17:00 +00:00
heikki%netscape.com
a265cb4587 Bug 95489, attempting to fix this topcrash with a null-check. r=harishd, sr=vidur.
git-svn-id: svn://10.0.0.236/trunk@103732 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-25 22:16:41 +00:00
sfraser%netscape.com
72d1338b0a Fix for bug 67409 -- don't use the necko connection counts to see if we're busy, because mailnews holds IMAP connections open, and that causes us to remain busy for too long. Looking for pending PLEvents is enough. r=sdagley, saari, sr=kin.
git-svn-id: svn://10.0.0.236/trunk@103731 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-25 22:15:03 +00:00
jgaunt%netscape.com
a486effad8 bug 98781 - accessibility for XULImage elements.
for aaronl
idl and mcp file
r=jgaunt sr=hyatt


git-svn-id: svn://10.0.0.236/trunk@103730 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-25 22:13:45 +00:00
av%netscape.com
934a0ed1b4 Fix for bug 91095 -- Default Plugin bypassed if 'code' attribute is missing in 'applet' tag, r=peterl, sr=attinasi
git-svn-id: svn://10.0.0.236/trunk@103728 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-25 22:04:24 +00:00
nicolson%netscape.com
34f07e2fe4 Fix 96779: UserCertConflictException always gets thrown when importing user cert.
git-svn-id: svn://10.0.0.236/trunk@103727 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-25 21:39:21 +00:00
bstell%netscape.com
2577eb1c6a bug 101370, r=adamlock, rs=alecf
fix bustage from checkin (bug 95518); make SearchNode and
SetUpFontCharSetInfo interact as before


git-svn-id: svn://10.0.0.236/trunk@103726 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-25 21:12:18 +00:00
ian.mcgreer%sun.com
7d1e9b7860 check in the nssItem_ interface
git-svn-id: svn://10.0.0.236/trunk@103725 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-25 20:48:51 +00:00
sonja.mirtitsch%sun.com
13d0ceb40b backing out changes until coredump of testclnt is fixed
git-svn-id: svn://10.0.0.236/trunk@103723 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-25 20:14:20 +00:00
shrutiv%netscape.com
b1f9b42a7d Fix for bug 101424: No error checking for port number in "Customizing
proxies" screen (r=tao)


git-svn-id: svn://10.0.0.236/trunk@103720 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-25 16:52:52 +00:00
sonja.mirtitsch%sun.com
a2e0f2ad6d added tests of 3 new ciphers in TLS and SSL
git-svn-id: svn://10.0.0.236/trunk@103719 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-25 16:00:00 +00:00
alecf%netscape.com
2fc2f3f6c5 remove xpinstall's dependency on nsIAppShellComponent*.h
sr=sfraser bug 76339


git-svn-id: svn://10.0.0.236/trunk@103718 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-25 14:56:47 +00:00
pinkerton%netscape.com
d6389374e7 don't associate .jar and .dat files with mozilla. r=sdagley/sr=sfraser. bug# 100065
git-svn-id: svn://10.0.0.236/trunk@103717 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-25 14:41:53 +00:00
nboyd%atg.com
40a7e95769 Patch from Igor:
Currently omj/TokenStream and omj/optimizer/Optimizer.java both contain
code to convert number value to a wrapper object of smallest size. The
attached patch moves this wrapping to Node constructor to avoid code
duplication and eliminate special treatment of exact integers in
Optimizer.java.


The constant folding code in omj/optimizer/Optimizer.java currently always
replaces x * 1, x - 0 by simply x which does not force the toNumber convertion,
which is visible, for example, via typeof. For example, when running at
optimization level 2, the following

function f() {
    return "0" * 1;
}

print(typeof(f()));

prints "string" instead of expected "number".

The const_fold.patch fixes this via replacing x*1 by (+x) to force number convertion.

It assumes that the patch with number wrapping changes is in place.


git-svn-id: svn://10.0.0.236/trunk@103716 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-25 14:09:22 +00:00
nboyd%atg.com
f4a7b928b8 Currently omj/TokenStream and omj/optimizer/Optimizer.java both contain code to
convert number value to a wrapper object of smallest size. The attached patch
moves this wrapping to Node constructor to avoid code duplication and eliminate
special treatment of exact integers in Optimizer.java.


git-svn-id: svn://10.0.0.236/trunk@103715 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-25 14:08:08 +00:00
rods%netscape.com
96d692a5ec Removed setting page height to 5 pages when printing a document "AsIs"
Also, added special case code for sizing of "AsIs" documents when they
are positioned 0,0
Bug 100797 r=kmcclusk sr=attinasi


git-svn-id: svn://10.0.0.236/trunk@103713 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-25 13:00:04 +00:00
jaggernaut%netscape.com
2e3e10626b Bug 100116: remove window mediator's public dependency on rdf.
Fixing bustage by adding a #include "nsISupportsArray.h" as was done to the Windows counterpart of this.


git-svn-id: svn://10.0.0.236/trunk@103712 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-25 10:58:11 +00:00
jaggernaut%netscape.com
f01c438d1f Fixing myotonic bustage (add "timer" and "uriloader" to REQUIRES)
git-svn-id: svn://10.0.0.236/trunk@103711 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-25 10:46:39 +00:00
jaggernaut%netscape.com
481ff2b35e Bug 100764: remove NS_ConvertABCtoXYZ(CharT). r=dbaron, rs=scc
git-svn-id: svn://10.0.0.236/trunk@103710 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-25 09:37:13 +00:00
jaggernaut%netscape.com
5938d73d86 Bug 100750: string iterator users should use correct typedefs. r=dbaron, rs=scc
git-svn-id: svn://10.0.0.236/trunk@103709 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-25 09:35:50 +00:00
aaronl%netscape.com
47a7eeb765 Bug 100498. Active accessibility: Clear, consistent events for page load busy states. r=jgaunt, sr=waterson.
git-svn-id: svn://10.0.0.236/trunk@103708 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-25 08:34:42 +00:00
brendan%mozilla.org
d5ee6f816f Report uncaught exceptions from all JS_Compile* APIs (97646, sr=jband&shaver).
git-svn-id: svn://10.0.0.236/trunk@103707 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-25 06:43:33 +00:00
attinasi%netscape.com
0259fc9d5a Don't allow consecutive images to wrap in table cells with percentage width. r=kmcclusk sr=waterson b=100568
git-svn-id: svn://10.0.0.236/trunk@103706 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-25 06:31:46 +00:00
stephend%netscape.com
5dfc550bec Bug 94180. Splitter appears to the left instead of center (fixed address book) r=kerz@netscape.com, sr=hyatt@netscape.com
git-svn-id: svn://10.0.0.236/trunk@103705 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-25 06:04:50 +00:00
dmose%netscape.com
2496c27f9e xpinstall packaging changes (not built by tinderbox) for registering mozldap chrome package correctly (bug 79935). r=ssu@netscape.com; sr=shaver@mozilla.org
git-svn-id: svn://10.0.0.236/trunk@103704 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-25 06:01:43 +00:00
aaronl%netscape.com
180502a51d Backing out 100498 for now. Mac problems
git-svn-id: svn://10.0.0.236/trunk@103703 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-25 05:54:10 +00:00
aaronl%netscape.com
8626b5168e Bug 100498. Active Accessibility: clear, consistent events for page load busy states. Missing file in checkin. r=jgaunt, sr=waterson. Accessible.cpp
git-svn-id: svn://10.0.0.236/trunk@103702 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-25 05:23:45 +00:00
aaronl%netscape.com
7086d51499 Bug 100498. Active accessibility: Clear, consistent events for page load busy states. r=jgaunt, sr=hyatt.
git-svn-id: svn://10.0.0.236/trunk@103701 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-25 04:52:14 +00:00
stephend%netscape.com
08d34f034d Bug 57650. JS strict warnings in MsgComposeCommands.js r=varada@netscape.com, sr=sspitzer@netscape.com
git-svn-id: svn://10.0.0.236/trunk@103700 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-25 04:16:04 +00:00
waldemar%netscape.com
29947be92b Renamed local-variable to variable
git-svn-id: svn://10.0.0.236/trunk@103699 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-25 03:51:24 +00:00
waldemar%netscape.com
f76173920f Tweaked HTML formatting
git-svn-id: svn://10.0.0.236/trunk@103698 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-25 03:51:12 +00:00
waldemar%netscape.com
1e0d4a39ef Added algorithm, stmt, and lvl styles. Obsoleted semantics styles.
git-svn-id: svn://10.0.0.236/trunk@103697 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-25 03:50:36 +00:00
waldemar%netscape.com
965032d74d Added support for algorithm styles
git-svn-id: svn://10.0.0.236/trunk@103696 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-25 03:49:47 +00:00
waldemar%netscape.com
5c2495a607 Tweaked Word styles
git-svn-id: svn://10.0.0.236/trunk@103695 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-25 03:49:27 +00:00
waldemar%netscape.com
8dcb0a0e97 Added support for the 'named' function parameter attribute. Removed .class. Renamed production names to British spelling.
git-svn-id: svn://10.0.0.236/trunk@103694 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-25 03:48:53 +00:00
waldemar%netscape.com
73a4a54d1d Added named
git-svn-id: svn://10.0.0.236/trunk@103693 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-25 03:47:52 +00:00
waldemar%netscape.com
653ef11c7d Fixed the precedence of neg
git-svn-id: svn://10.0.0.236/trunk@103692 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-25 03:46:57 +00:00
jaggernaut%netscape.com
4589ddb0b6 Clean up REQUIRES, r=cls
git-svn-id: svn://10.0.0.236/trunk@103690 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-25 02:56:54 +00:00
srilatha%netscape.com
bb5c5d55a2 Fix for bug # 97502. setting gUpdate=false in oncancel()
r=mitesh, sr=sspitzer


git-svn-id: svn://10.0.0.236/trunk@103688 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-25 02:27:52 +00:00
bbaetz%cs.mcgill.ca
88b28e0548 Additional fix for bug 99233, rs=darin
git-svn-id: svn://10.0.0.236/trunk@103686 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-25 02:14:19 +00:00
mcafee%netscape.com
f88320c545 Adding check for Time::HiRes for gettimeofday(), this perl package can give us 1ms resolution instead of default of 1s resolution. tbox instances will need to symlink in gettime.pl.
git-svn-id: svn://10.0.0.236/trunk@103683 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-25 01:36:11 +00:00
gerv%gerv.net
ed9b258739 License changes, take 2. Bug 98089. mozilla/content/.
git-svn-id: svn://10.0.0.236/trunk@103682 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-25 01:32:19 +00:00
sonja.mirtitsch%sun.com
ad866f8fa2 added log information for tinderbox
git-svn-id: svn://10.0.0.236/trunk@103681 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-25 01:27:59 +00:00
wtc%netscape.com
1fadf88660 Bugzilla bug 83593: worked around a possible HP-UX B.11.00 bug, where
getpeername() occasionally fails with ENOTCONN after a successful
completion of non-blocking connect.


git-svn-id: svn://10.0.0.236/trunk@103680 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-25 01:25:41 +00:00
gerv%gerv.net
6a0a795977 License changes, take 2. Bug 98089. mozilla/db/, mozilla/dbm/.
git-svn-id: svn://10.0.0.236/trunk@103679 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-25 01:25:13 +00:00
shrutiv%netscape.com
3a81339133 Fix for bug 96744: File path given for Addt'l Components can't be removed
Making the component path an editable text field (r=tao)


git-svn-id: svn://10.0.0.236/trunk@103675 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-25 01:12:36 +00:00
gerv%gerv.net
4c7ac5dfa4 License changes, take 2. Bug 98089. mozilla/config/, mozilla/caps/, mozilla/build/.
git-svn-id: svn://10.0.0.236/trunk@103674 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-25 01:03:58 +00:00
mcafee%netscape.com
75f0d32505 Time::HiRes wrapper, code=jrgm@netscape.com
git-svn-id: svn://10.0.0.236/trunk@103673 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-25 00:49:38 +00:00
gerv%gerv.net
c125e13670 License changes, take 2. Bug 98089. mozilla/accessible/.
git-svn-id: svn://10.0.0.236/trunk@103672 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-25 00:48:50 +00:00
akkana%netscape.com
3c9ba5b911 Unix/Win makefiles for 66345. r=cmanske, sr=sfraser. Not yet part of the build
git-svn-id: svn://10.0.0.236/trunk@103671 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-25 00:45:54 +00:00
dp%netscape.com
5928625a80 bug 100682 temporary way to get service without creating a new
one. This will get fixed the right way along with other api changes
for component and servicemanager r=sfraser/dougt, sr=mscott


git-svn-id: svn://10.0.0.236/trunk@103669 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-25 00:38:44 +00:00
sfraser%netscape.com
3730095eb7 Fix for bug 100700 -- save and restor the GDevice along with the drawing port to fix blank window problems with Carbon, and with ATM installed. r=pierre, sr=scc
git-svn-id: svn://10.0.0.236/trunk@103668 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-25 00:27:24 +00:00
dp%netscape.com
b204a73fbc bug 100834 Deferring enumeration of search plugins directory until
REALLY required. r=rjc@rjcdb.com, sr=alecf


git-svn-id: svn://10.0.0.236/trunk@103666 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-25 00:22:45 +00:00
dp%netscape.com
c0acdf26c5 bug 29063 Removing unneccessary stat() r/sr=waterson/alecf
git-svn-id: svn://10.0.0.236/trunk@103665 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-25 00:19:52 +00:00
ddrinan%netscape.com
a8853422a2 Bug 100213 - Crash in GetOCSPResponders. r=rangansen,sr=kin
git-svn-id: svn://10.0.0.236/trunk@103662 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-25 00:08:48 +00:00
jaggernaut%netscape.com
5fc8712864 Remove dead string files from the tree, r=dbaron, rs=scc
git-svn-id: svn://10.0.0.236/trunk@103661 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-24 23:55:19 +00:00
alecf%netscape.com
5003eaa90c oops, forgot to check this in - now that window mediator no longer drags in rdf, manually pull in nsISupportsArray to fix bustage (bug 100116)
git-svn-id: svn://10.0.0.236/trunk@103660 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-24 23:36:48 +00:00
bienvenu%netscape.com
c26065d3d9 fix leak of offline imap playback object r=naving, sr=sspitzer 101265
git-svn-id: svn://10.0.0.236/trunk@103659 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-24 23:36:40 +00:00
bienvenu%netscape.com
7ea0ab2bf6 fix leak of offline imap playback object r=naving, sr=sspitzer 101265
git-svn-id: svn://10.0.0.236/trunk@103658 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-24 23:28:15 +00:00
bienvenu%netscape.com
51025977ec prevent biff from firing during shutdown r=naving, sr=sspitzer 101209
git-svn-id: svn://10.0.0.236/trunk@103657 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-24 23:20:02 +00:00
bienvenu%netscape.com
fbec06d22e fix 101143 r=dp, sr=waterson shutdown observer skipped if previous observer removes itself upon shutdown notification
git-svn-id: svn://10.0.0.236/trunk@103656 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-24 23:07:44 +00:00
bbaetz%cs.mcgill.ca
62bc92111a Bug 99233. Increase the pipe's segment size so that commands don't get
split up over multiple packets, which should fix some broken
servers/firewalls.  r=timeless, r/sr=dougt


git-svn-id: svn://10.0.0.236/trunk@103655 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-24 22:58:40 +00:00
dbradley%netscape.com
203b5a336d patch from bug 99838 - Changes to remove xpconnects dependency on DOM r=jband, sr=jst
git-svn-id: svn://10.0.0.236/trunk@103654 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-24 22:57:47 +00:00
shanjian%netscape.com
77abc0c095 #93330 Manually override charset doesn't work in View | Page Source window
r= jag , sr=waterson


git-svn-id: svn://10.0.0.236/trunk@103653 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-24 22:53:26 +00:00
radha%netscape.com
cb2d8401bb Fix for bugs 87143 - Problems with setting nsSHistory::SetmaxLength()
92664 - nsISHistoryListener::OnHistoryGotoIndex() doesn't fire all the time.
r=mcafee, sr=alec


git-svn-id: svn://10.0.0.236/trunk@103652 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-24 22:53:20 +00:00
dbradley%netscape.com
df570f5b2c added files: mozilla/js/src/xpconnect/idl/nsIXPCScriptNotify.idl
git-svn-id: svn://10.0.0.236/trunk@103651 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-24 22:53:00 +00:00
dbradley%netscape.com
3223174017 patch from bug 99838 - Changes to remove xpconnects dependency on DOM r=jband, sr=jst
git-svn-id: svn://10.0.0.236/trunk@103649 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-24 22:48:35 +00:00
naving%netscape.com
de0777c655 52460 r=bienvenu sr=mscott. Allow subfolders for pop3 inbox folder.
git-svn-id: svn://10.0.0.236/trunk@103648 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-24 22:47:16 +00:00
pinkerton%netscape.com
bb00ed7bcb oops, left in a debug printf.
git-svn-id: svn://10.0.0.236/trunk@103647 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-24 22:43:56 +00:00
bzbarsky%mit.edu
f21726b0d5 Add a document.contentType attribute to allow getting the MIME type of
the current document from JS.  The rest is moving around stuff to deal
with nsIDocument already declaring GetContentType.  bug 73847, r=peterv,
sr=jst


git-svn-id: svn://10.0.0.236/trunk@103646 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-24 22:43:23 +00:00
pinkerton%netscape.com
f22f1d15a3 implements code for responding to hidden/collapsed attributes on top-level menus. bug 100122. r=saari/sr=sfraser/a=chofmann.
git-svn-id: svn://10.0.0.236/trunk@103644 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-24 22:40:26 +00:00
bzbarsky%mit.edu
c6d1988306 Fix linux topcrash bug 97970. Make AddMimeInfoToCache do some more
error checking than it used to.  r=timeless, sr=mscott


git-svn-id: svn://10.0.0.236/trunk@103643 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-24 22:39:17 +00:00
bzbarsky%mit.edu
efc4c963e6 making the "Enabling quirk stylesheet" message only show up for some
people who care (even in debug builds).  bug 100983, r=dmose, sr=attinasi


git-svn-id: svn://10.0.0.236/trunk@103642 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-24 22:36:43 +00:00
bzbarsky%mit.edu
6fec871479 Making view source load its stylesheet even when highlighting is off --
it's needed for wrap and the like.  bug 22022, r=rbs,doron sr=alecf


git-svn-id: svn://10.0.0.236/trunk@103641 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-24 22:34:47 +00:00
alecf%netscape.com
f1fb79c6f5 fix for 100116 - remove window mediator's public dependency on rdf
r=jag, sr=waterson


git-svn-id: svn://10.0.0.236/trunk@103640 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-24 22:31:49 +00:00
waterson%netscape.com
3f8ee6abf7 Bug 97775. Modify serializer to emit typed nodes when appropriate; patch courtesy tingley@sundell.net, r=shaver, sr=waterson.
git-svn-id: svn://10.0.0.236/trunk@103639 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-24 22:31:05 +00:00
sspitzer%netscape.com
9b9d1e738c fix for #101061. use nsDependentString to avoid copying the body of a message (twice)
when replying.  r=sfraser@netscape.com, sr=kin@netscape.com


git-svn-id: svn://10.0.0.236/trunk@103638 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-24 22:30:39 +00:00
pinkerton%netscape.com
27d2dee35d use OS routine to sub out the menubar and dock on OSX/Carbon. r=sdagley/sr=sfraser/a=chofmann. bug# 83570.
git-svn-id: svn://10.0.0.236/trunk@103637 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-24 22:28:04 +00:00
depstein%netscape.com
debe294f3b latest testembed update
git-svn-id: svn://10.0.0.236/trunk@103630 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-24 19:40:00 +00:00
hyatt%netscape.com
ba76f4b35a Fix for 101389.
git-svn-id: svn://10.0.0.236/trunk@103629 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-24 19:39:18 +00:00
nicolson%netscape.com
8ec2466035 Emphasize that we ignore the SecureRandom parameter.
git-svn-id: svn://10.0.0.236/trunk@103628 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-24 18:34:18 +00:00
shrutiv%netscape.com
0544e55ec0 *** empty log message ***
git-svn-id: svn://10.0.0.236/trunk@103626 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-24 17:21:07 +00:00
rjesup%wgate.com
66b1bc3856 Backout of commits for bug 97299. This causes assertions, which means we
missed some spots where name was getting set.


git-svn-id: svn://10.0.0.236/trunk@103624 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-24 15:26:39 +00:00
karnaze%netscape.com
576d4b2e6d bug 82401 - remove cell from correct parent when cell spans into split row; work around bug 101264 by doing initial reflow with unconstrained height. sr=kin, r=attinasi.
git-svn-id: svn://10.0.0.236/trunk@103623 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-24 14:53:06 +00:00
ian.mcgreer%sun.com
84a4e20feb remove dumb question
git-svn-id: svn://10.0.0.236/trunk@103622 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-24 14:39:38 +00:00
peterv%netscape.com
5463b13c1e Fix for bug 100732 (content_xsl.xpt missing in packaged bits). Also adding content_base.xpt which was missing. r=heikki, sr=jst.
git-svn-id: svn://10.0.0.236/trunk@103615 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-24 12:03:09 +00:00
peterv%netscape.com
d10179e1a0 Fix for bug 100732 (content_xsl.xpt missing in packaged bits). r=heikki, sr=jst.
git-svn-id: svn://10.0.0.236/trunk@103614 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-24 12:03:02 +00:00
rjesup%wgate.com
df88c58576 Bustage fix attempt #2. NS_GFX was there before, but gcc didn't care. I
didn't add it back in when I went back to a struct.  (Bug 97299)


git-svn-id: svn://10.0.0.236/trunk@103613 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-24 09:07:53 +00:00
rjesup%wgate.com
a86ff804be Bustage fix for bug 97299 checking: Win32 compiler doesn't like class and
struct mixed.  Reverted nsFont to struct.


git-svn-id: svn://10.0.0.236/trunk@103612 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-24 08:14:17 +00:00
rjesup%wgate.com
faf5fdf631 Bug 97299: Store font names in lowercase. r=pavlov, sr=attinasi
git-svn-id: svn://10.0.0.236/trunk@103611 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-24 07:35:04 +00:00
jfrancis%netscape.com
c2e63c0eb6 fix for bug 31770: content iterator performance work. Adding an array of cached dom offsets for parent heirarchy of current node in iterator. Most of this work is courtesy of rjesup. r=rjesup,jfrancis; sr=kin
git-svn-id: svn://10.0.0.236/trunk@103610 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-24 06:13:03 +00:00
hyatt%netscape.com
6abd5e1275 100706. Tabbrowser stuff. r=jag, sr=blake
git-svn-id: svn://10.0.0.236/trunk@103609 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-24 04:38:41 +00:00
peterlubczynski%netscape.com
8e2a74ee6c Incorrect GetAttributes/GetParameters for embed/object tag types patch by philanderton@yahoo.com bug 99063 r=peterl sr=attinasi
git-svn-id: svn://10.0.0.236/trunk@103608 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-24 04:35:02 +00:00
peterlubczynski%netscape.com
4439e39364 Bad signed conversion in plugin streaming code bug 100888 r=av sr=attinasi
git-svn-id: svn://10.0.0.236/trunk@103607 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-24 04:31:58 +00:00
jfrancis%netscape.com
fe8d36a5da fixes bug 96676: deletion can pull text out of inline containers
fixes bug 97685: unbulleting empty bullet list item can create nested list
r=fm; sr=kin


git-svn-id: svn://10.0.0.236/trunk@103605 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-24 03:43:34 +00:00
jfrancis%netscape.com
636b0444f5 fixes bug 98573: style feedback incorrect after a <br>; r=fm; sr=kin
git-svn-id: svn://10.0.0.236/trunk@103604 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-24 03:40:23 +00:00
bienvenu%netscape.com
db8ca33a33 linux didn't like that last change, backing out
git-svn-id: svn://10.0.0.236/trunk@103602 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-23 23:52:36 +00:00
bienvenu%netscape.com
da8d8b6528 remove unused method NS_NewImapHostSessionList rs=sspitzer, no bug
git-svn-id: svn://10.0.0.236/trunk@103601 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-23 23:46:47 +00:00
bienvenu%netscape.com
29d528e09c fix memory leak of imap headers when move msg filters fire rs=sspitzer 101246
git-svn-id: svn://10.0.0.236/trunk@103600 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-23 23:42:19 +00:00
leaf%mozilla.org
ce6b47301e Automated update
git-svn-id: svn://10.0.0.236/trunk@103599 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-23 23:28:34 +00:00
cls%seawood.org
ad6d30cc5e Remove unnecessary toplevel check for shm_open() as it's only used by NSPR.
Bug #96986 r=pavlov


git-svn-id: svn://10.0.0.236/trunk@103598 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-23 23:17:01 +00:00
cls%seawood.org
b30f9b9685 Adding mimetype dependency caused by checkin for bug #77909.
Fixing tinderbox bustage


git-svn-id: svn://10.0.0.236/trunk@103597 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-23 22:33:01 +00:00
cls%seawood.org
e0466b6bd9 Copy DIR struct definition from dbm/include/winfile.h for win32 to remove questionable dependency upon dbm.
Bug #100966 r=pavlov sr=shaver


git-svn-id: svn://10.0.0.236/trunk@103596 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-23 22:23:10 +00:00
hyatt%netscape.com
63305b2fff Fix for 101177. r=pavlov, sr=ben
git-svn-id: svn://10.0.0.236/trunk@103595 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-23 22:20:46 +00:00
locka%iol.ie
2101bdc168 The all new web browser persist object plus changes to the assorted embedding samples to use it. b=77909 r=ccarlen@netscape.com sr=rpotts@netscape.com
git-svn-id: svn://10.0.0.236/trunk@103594 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-23 21:03:03 +00:00
blakeross%telocity.com
20bf2c2ceb (and removing now-unnecessary class...)
git-svn-id: svn://10.0.0.236/trunk@103593 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-23 20:07:18 +00:00
blakeross%telocity.com
4bc71598ef fallout from hewitt's syntax change. sr=hewitt
git-svn-id: svn://10.0.0.236/trunk@103592 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-23 20:07:00 +00:00
nboyd%atg.com
facb322141 Remove obsolete class.
git-svn-id: svn://10.0.0.236/trunk@103591 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-23 20:01:43 +00:00
nboyd%atg.com
b38ceec6e9 Fix bug:
Hello Norris

The script should return 0, Rhino returns NaN

Steven

<script>
var trial = parseInt("0)");
alert(trial);
</script>


git-svn-id: svn://10.0.0.236/trunk@103590 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-23 20:01:31 +00:00
nboyd%atg.com
81ac2e3232 Patch from Igor:
Currently omj/optimizer/Codegen.java uses special classes ConstantList
and ConstantDude to store the list of static constants in the generated
class. It seems that using a simple double[] array with a constant
counter and checking via "(int)number == number" for constant types not
only eliminates these 2 classes but makes the whole code simple, see
the attached patch.

The patch also modifies nodeIsConvertToObjectOfNumber to return not a
Number, but the number node itself that is used to extract double
value directly via Node.getDouble() call. I changed it to allow  to
store values of number literals in nodes without using wrapper object.


git-svn-id: svn://10.0.0.236/trunk@103589 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-23 20:00:26 +00:00
nboyd%atg.com
42097520f6 Patch from Igor:
Replacing usage of ShallowNodeIterator to loop throw node children by
explicit calls to Node.getFirstChild()/ Node.getNextSibling()) with
comments when the node children list is modified while iterating
through it.

It avoids creation of ShallowNodeIterator objects and eliminates the
need to have ShallowNodeIterator class.


git-svn-id: svn://10.0.0.236/trunk@103588 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-23 19:58:38 +00:00
zach%zachlipton.com
dc3c9e0e97 Fix for bug 93388: Full name should be trimmed of whitespace before going
into database.

r1=Zach Lipton <zach@zachlipton.com> r2=Andreas Franke
<afranke@ags.uni-sb.de>. Patch by Christopher Aillon
<caillon@returnzero.com>.


git-svn-id: svn://10.0.0.236/trunk@103587 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-23 17:20:50 +00:00
zach%zachlipton.com
041ee9f94b Fix for bug 97588: localconfig should mention access.conf as well as
httpd.conf (for old apache). Simple 2line comment addition to localconfig
to inform the user they may need to look at access.conf in addition to
httpd.conf if they are using an older version of apache.

Patch by Gavin Shelley <gavins@iplbath.com> r=Zach Lipton
<zach@zachlipton.com> no 2nd review needed for this patch.


git-svn-id: svn://10.0.0.236/trunk@103586 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-23 17:07:55 +00:00
hwaara%chello.se
0735a417e5 #52902, "Text Size" on View menu should be "Text Zoom".
Patch by Christian Biesinger <cbiesinger@web.de>

r=hwaara, sr=blake


git-svn-id: svn://10.0.0.236/trunk@103585 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-23 12:52:05 +00:00
pavlov%netscape.com
dfdc106c91 adding some code to enumerate the registered image decoders (ifdef'd DEBUG_pavlov)
git-svn-id: svn://10.0.0.236/trunk@103584 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-23 10:01:07 +00:00
hyatt%netscape.com
e873c08225 Some kind of cvs error has hosed the mac classic browser.css file. In order to keep mac green, backing out jar.mn change.
git-svn-id: svn://10.0.0.236/trunk@103583 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-23 09:45:47 +00:00
hyatt%netscape.com
50550dd031 More 100706 fun. The <tabbrowser> widget. r/sr=jst,jag
git-svn-id: svn://10.0.0.236/trunk@103582 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-23 09:33:32 +00:00
hyatt%netscape.com
1a6805f34f More 100706 fun. r/sr=jst,jag
git-svn-id: svn://10.0.0.236/trunk@103581 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-23 09:30:02 +00:00
hyatt%netscape.com
f5df3da293 More 98109 goodness, making _content dynamically shiftable. r/sr=bryner,ben
git-svn-id: svn://10.0.0.236/trunk@103580 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-23 08:33:24 +00:00
cls%seawood.org
157d81dedd Remove dbm dependency by removing unneeded winfile.h include.
git-svn-id: svn://10.0.0.236/trunk@103579 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-23 07:24:39 +00:00
cls%seawood.org
247b2a0c54 Use EXPORTS instead of installing headers by hand.
Bug #98371 sr=alecf


git-svn-id: svn://10.0.0.236/trunk@103578 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-23 07:21:04 +00:00
blakeross%telocity.com
3e15035ab9 removing inadvertently checked in line.
git-svn-id: svn://10.0.0.236/trunk@103577 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-23 07:19:59 +00:00
blakeross%telocity.com
4d77ccdc7b removing attr's that are now unnecessary due to default orientation. r=hewitt sr=hyatt
git-svn-id: svn://10.0.0.236/trunk@103576 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-23 07:16:02 +00:00
blakeross%telocity.com
b5ebd5bacf tabbrowser looks like crap in classic. set default orientation of vertical for radiogroup, tabbox and horizontal for tabs for xul1.0 (101133). r=hewitt sr=hyatt
git-svn-id: svn://10.0.0.236/trunk@103575 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-23 06:58:34 +00:00
blakeross%telocity.com
fcde0211d2 composer is unusable (101142). r/sr=hyatt
git-svn-id: svn://10.0.0.236/trunk@103574 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-23 06:56:23 +00:00
hyatt%netscape.com
47a2323fe3 Fix for 101093. Content added dynamically using the DOM is now in the right scope if anonymous. r=blake, sr=jst
git-svn-id: svn://10.0.0.236/trunk@103573 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-23 05:53:32 +00:00
hyatt%netscape.com
093fc7edc3 Fix for 98109, make window._content dynamically shiftable. r=blake, sr=jst
git-svn-id: svn://10.0.0.236/trunk@103572 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-23 05:52:23 +00:00
zach%zachlipton.com
158508051a Have checksetup.pl block web-access to runtests.sh (by .htaccess) and
chmod +x runtests.sh so that it can be run with ./

r=bbaetz on irc, no 2nd review needed. No bug filed.


git-svn-id: svn://10.0.0.236/trunk@103571 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-23 04:28:17 +00:00
zach%zachlipton.com
c3991b060c Renaming *.t to be 00*.t to solve any sorting issues down the road as per
bug 97976.

No review required for tests at this time. NOT_PART_OF_BUILD


git-svn-id: svn://10.0.0.236/trunk@103570 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-23 04:08:44 +00:00
zach%zachlipton.com
d3d55e6e94 *** empty log message ***
git-svn-id: svn://10.0.0.236/trunk@103569 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-23 04:02:19 +00:00
cls%seawood.org
280b52b889 Purge old headers when building with MOZ_TRACK_MODULE_DEPS set.
Bug #59454 r=jag


git-svn-id: svn://10.0.0.236/trunk@103568 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-23 03:44:12 +00:00
cls%seawood.org
2ac62745b5 Use default EXPORTS rules instead of installing headers by hand.
Bug #98371 sr=alecf


git-svn-id: svn://10.0.0.236/trunk@103567 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-23 03:34:32 +00:00
stephend%netscape.com
ad011c86ee Unused cruft removal. r=cls, sr=sspitzer
git-svn-id: svn://10.0.0.236/trunk@103566 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-23 02:26:16 +00:00
waterson%netscape.com
60cfdaab0e Remove old unused files. r=rods, sr=attinasi
git-svn-id: svn://10.0.0.236/trunk@103564 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-22 23:29:03 +00:00
mcafee%netscape.com
f6e80de09c switching to sourceforge cvs server, more in sync?
git-svn-id: svn://10.0.0.236/trunk@103563 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-22 22:05:58 +00:00
stephend%netscape.com
cb736067a7 Bug 100906. JS strict warnings in mailWindowOverlay.js r=rginda@netscape.com sr=bienvenu@netscape.com
git-svn-id: svn://10.0.0.236/trunk@103562 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-22 21:56:42 +00:00
cmanske%netscape.com
1772b49e80 Use 'hidden' instead of 'collapsed' to remove items from context menu (wrong bug number in last checkin!) b=100015: Fix by neil@parkwaycc.co.uk, r=cmanske,brade sr=hewitt
git-svn-id: svn://10.0.0.236/trunk@103561 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-22 19:01:58 +00:00
cmanske%netscape.com
8f50ff8376 Use 'hidden' instead of 'collapsed' to remove items from context menu, b=98567: Fix by neil@parkwaycc.co.uk, r=cmanske, sr=hewitt
git-svn-id: svn://10.0.0.236/trunk@103560 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-22 18:49:01 +00:00
cmanske%netscape.com
9edd8e9f3e Inlude 'img' filetype for Open file dialogs when creating links, b=98567, r=akkana, sr=hewitt
git-svn-id: svn://10.0.0.236/trunk@103559 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-22 18:44:59 +00:00
cmanske%netscape.com
7753e79195 Fixed removal of empty selection ranges after joining table cells, b=96668, r=akkana, sr=hewitt
git-svn-id: svn://10.0.0.236/trunk@103558 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-22 18:40:58 +00:00
cmanske%netscape.com
e89f78fdd0 Added first-char input filtering to 'hreflang' attribute in Advanced Edit dialog. b=88881, r=akkana, sr=hewitt
git-svn-id: svn://10.0.0.236/trunk@103557 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-22 18:33:56 +00:00
jband%netscape.com
7e37012cad I'm tired of this warning: '*/' found outside of comment. This was much discussed. But no one ever bothered to actually check in the trivial fix. r=rginda rs=jband.
git-svn-id: svn://10.0.0.236/trunk@103556 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-22 17:42:36 +00:00
bernd.mielke%snafu.de
6d94a901b7 bug 97905 add -B 1 to the rtest.bat in order to avoid the complete regression tree dump
on every error. With this option only the differing nodes will be printed out.
This is not part of the build.


git-svn-id: svn://10.0.0.236/trunk@103555 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-22 17:30:21 +00:00
hwaara%chello.se
6bc48fe8de #100542, JavaScript strict warning in printdialog.js.
Patch by Christopher Aillon <caillon@returnzero.com>

r=cbiesinger@web.de, sr=alecf


git-svn-id: svn://10.0.0.236/trunk@103552 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-22 14:31:05 +00:00
cls%seawood.org
47182cc8a6 Convert widget_beos over to using a generic (xpcom) module.
Remove unused native widget implementations.
Thanks to arougthopher@lizardland.net for the patch.
Bug #95348 r=cls sr=attinasi


git-svn-id: svn://10.0.0.236/trunk@103551 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-22 13:41:07 +00:00
cls%seawood.org
96e5ad9048 Update REQUIRES for MOZ_MATHML & MOZ_SVG builds.
Thanks to jonsmirl@mediaone.net for the patch.
Bug #98371 r=cls


git-svn-id: svn://10.0.0.236/trunk@103550 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-22 13:34:38 +00:00
cls%seawood.org
12042b7023 Use OBJ_SUFFIX instead of hardcoding .o . Should fix OS/2 bustage
git-svn-id: svn://10.0.0.236/trunk@103549 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-22 12:49:53 +00:00
locka%iol.ie
5042d42905 NOT PART OF BUILD. Moved streaming off onto another thread to make UI responsive. First cut impl of NPN_GetValue.
git-svn-id: svn://10.0.0.236/trunk@103548 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-22 12:33:34 +00:00
stephend%netscape.com
cf31eed8df Bug 100907. JS strict warnings in messengerdns.js r=rginda@netscape.com, sr=jst@netscape.com
git-svn-id: svn://10.0.0.236/trunk@103547 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-22 11:02:20 +00:00
hyatt%netscape.com
8ace313ea8 Fix for 100706, r/sr=jag,brendan
git-svn-id: svn://10.0.0.236/trunk@103545 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-22 07:33:53 +00:00
hyatt%netscape.com
b5530a97ca Checking in tabbrowser prototype. r=jag, sr=brendan
git-svn-id: svn://10.0.0.236/trunk@103544 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-22 07:27:30 +00:00
varga%utcru.sk
ae57adb87a Fix for 97110. nsOutlinerBodyFrame::GetLastVisibleRow returns incorrect value.
r=varga, sr=hyatt, patch by mike@vee.net


git-svn-id: svn://10.0.0.236/trunk@103543 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-22 05:57:11 +00:00
leif%netscape.com
8154ee7ea7 Bug 91248: LDAP referrals hangs browser. r=dmose, sr=bienvenu, patch=leif.
git-svn-id: svn://10.0.0.236/trunk@103542 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-22 05:13:05 +00:00
stephend%netscape.com
80741bf14e Bug 100897. JS strict warning in searchDialog.js r=naving@netscape.com sr=jst@netscape.com
git-svn-id: svn://10.0.0.236/trunk@103540 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-22 03:56:22 +00:00
bryner%netscape.com
9d69f8b1b2 Bug 99962 - inspector assertions when flashing a DOM node with display: none. r=hewitt, sr=hyatt.
git-svn-id: svn://10.0.0.236/trunk@103539 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-22 03:33:33 +00:00
cls%seawood.org
0cfaa334c0 Export the viewer samples from the toplevel webshell makefile so that we have them in release builds.
Bug #87905 r=jag


git-svn-id: svn://10.0.0.236/trunk@103537 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-22 03:02:01 +00:00
cls%seawood.org
cceeacbea1 Place LDAP headers into ldap subdir.
Bug #98924 r=dmose sr=alecf


git-svn-id: svn://10.0.0.236/trunk@103536 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-22 02:28:40 +00:00
beard%netscape.com
bf45549385 [not part of build] OJI plugin for Mac OS X.
git-svn-id: svn://10.0.0.236/trunk@103535 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-22 02:12:57 +00:00
cmanske%netscape.com
e02d882fb8 Checkin fix by brade for bug 100371: remove unused code, r=cmanske, sr=hewitt
git-svn-id: svn://10.0.0.236/trunk@103534 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-22 02:04:54 +00:00
morse%netscape.com
384c202a91 bug 96828, fix js warning, c=gemal, r=morse, sr=alecf
git-svn-id: svn://10.0.0.236/trunk@103533 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-22 01:44:09 +00:00
cls%seawood.org
7598224bba Remove commented out references to mozilla xp_*.h files.
Thanks to Brian Ryner <bryner@netscape.com> for the patch.
Bug #38061 r=cls


git-svn-id: svn://10.0.0.236/trunk@103532 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-22 01:42:48 +00:00
morse%netscape.com
4ebd59b78f bug 99910, password manager never isn't remembered, r=jag, sr=alecf
git-svn-id: svn://10.0.0.236/trunk@103531 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-22 01:41:42 +00:00
rginda%netscape.com
22a97b8a46 - venkman only -
bug 100943, changes needed to build jsd on os/2
patch by Dainis Jonitis, r=mkaply,rginda


git-svn-id: svn://10.0.0.236/trunk@103530 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-22 01:39:24 +00:00
bryner%netscape.com
f25b234892 Removing dead code. r=morse.
git-svn-id: svn://10.0.0.236/trunk@103529 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-22 01:38:46 +00:00
bzbarsky%mit.edu
85c12e9807 Do a case-insensitive compare on the extensions fetched from mime.types
files. Bug 101014, r=bbaetz, sr=jst


git-svn-id: svn://10.0.0.236/trunk@103528 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-22 01:23:55 +00:00
bzbarsky%mit.edu
85683c8389 Better defaults for the locations of the mime.types and mailcap files
(don't assume Netscape is installed).  Bug 95504, r=bbaetz, sr=darin


git-svn-id: svn://10.0.0.236/trunk@103527 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-22 01:21:53 +00:00
depstein%netscape.com
fe4d82fb11 Uploading new object model (work done by Ashish) & .cpp files for separate interface tests.
git-svn-id: svn://10.0.0.236/trunk@103523 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-22 00:49:38 +00:00
beard%netscape.com
e1323274aa [not part of build] Resource files for Mac OS X OJI plugin.
git-svn-id: svn://10.0.0.236/trunk@103521 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-22 00:39:43 +00:00
beard%netscape.com
24450010d7 [not part of build] XML project files for Pro 6 & Pro 7 to build new Mac OS X OJI plugin.
git-svn-id: svn://10.0.0.236/trunk@103520 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-22 00:38:12 +00:00
hyatt%netscape.com
0c386f7c3e Fix for 96291, leaking popups in tree widget, causing reply-all in mailcompose to fail autocompletion. r/sr=waterson,danm
git-svn-id: svn://10.0.0.236/trunk@103519 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-22 00:32:23 +00:00
hyatt%netscape.com
edd0dd382e Fix for 94180. Grippy in mail 3-pane misaligned. r=hwaara, sr=brendan
git-svn-id: svn://10.0.0.236/trunk@103518 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-22 00:29:42 +00:00
leaf%mozilla.org
dead72402f Automated update
git-svn-id: svn://10.0.0.236/trunk@103516 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-22 00:28:36 +00:00
cls%seawood.org
ae10af6d68 Make -DHAVE_MOVEMAIL localized to mailnews.
Bug #58117 r=jag


git-svn-id: svn://10.0.0.236/trunk@103514 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-22 00:26:48 +00:00
jst%netscape.com
1d560515a4 Fixing bug 100765. nsStringKey leak in the nsDOMEvent code. r=cls@seawood.org, sr=brendan@mozilla.org
git-svn-id: svn://10.0.0.236/trunk@103511 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-22 00:25:16 +00:00
mstoltz%netscape.com
855721da6d Bug 99020, need to clear the value of a textbox when we change its type to
'file.' r=heikki, sr=jst.


git-svn-id: svn://10.0.0.236/trunk@103510 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-22 00:24:41 +00:00
jband%netscape.com
1181621592 fix bug 100773. This protects agains infinite recursion that could occur thorugh xpconnect in QI calls on elements with multiple bindings. sr=hyatt r=brendan.
git-svn-id: svn://10.0.0.236/trunk@103509 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-22 00:24:24 +00:00
naving%netscape.com
4d21e183c5 100978 r=sspitzer sr=bienvenu. fix and/or radio button load correctly in filter editor when doing
new/edit filter.


git-svn-id: svn://10.0.0.236/trunk@103508 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-22 00:23:03 +00:00
cls%seawood.org
84a5dfec4b Use non-standard OBJ_SUFFIX so that we can safely use VPATH to grab files from other srcdirs and allow people to build in the srctree.
Bug #100851 r=jag


git-svn-id: svn://10.0.0.236/trunk@103507 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-22 00:21:59 +00:00
bienvenu%netscape.com
2217a54fa7 fix 98689 mark all read local folder leaves db invalid r=naving, sr=sspitzer
git-svn-id: svn://10.0.0.236/trunk@103506 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-22 00:21:13 +00:00
mstoltz%netscape.com
63a25ad1bc Bug 101021 - omitted assignment of return value from security check.
r=harishd, sr=vidur.


git-svn-id: svn://10.0.0.236/trunk@103505 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-22 00:20:59 +00:00
cls%seawood.org
d0cd4675ca Allow Makefiles to override OBJ_SUFFIX if necessary.
Bug #100851 r=jag


git-svn-id: svn://10.0.0.236/trunk@103504 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-22 00:20:31 +00:00
serge%netscape.com
2e74f8250f fix for 74938; acrobat fails on plugin registration on Linux; r=av; sr=waterson
git-svn-id: svn://10.0.0.236/trunk@103503 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-22 00:18:55 +00:00
yokoyama%netscape.com
c9b66890f6 Bug 97224
Adding a Unicode byte check in the UTF8 converter.
Checking in for ftang.
/r=yokoyama, /sr=waterson


git-svn-id: svn://10.0.0.236/trunk@103502 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-22 00:18:39 +00:00
bienvenu%netscape.com
76be632cd5 fix move from imap to local folder marking dest message read rs=sspitzer
git-svn-id: svn://10.0.0.236/trunk@103500 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-22 00:14:19 +00:00
sspitzer%netscape.com
351b266bc0 fix for #96979. hide the Total and Unread folder columns for existing profiles.
r=mscott, sr=bienvenu


git-svn-id: svn://10.0.0.236/trunk@103499 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-22 00:13:21 +00:00
radha%netscape.com
f57ce1c3c0 Fix for bug 92824. Update index in SH after onStartLoad() is called for the page. r=adamlock sr=rpotts
git-svn-id: svn://10.0.0.236/trunk@103498 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-22 00:12:41 +00:00
radha%netscape.com
d1cf6ddf4a Fix for bug 92824. Update index in SH after onStartLoad() gets called for the page
git-svn-id: svn://10.0.0.236/trunk@103497 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-22 00:10:58 +00:00
radha%netscape.com
ec63eef899 Fix for bus 92824. Update index in session History only after onStartLoad notifications come for the page. r=adamlaock sr=rpotts
git-svn-id: svn://10.0.0.236/trunk@103496 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-22 00:07:42 +00:00
relyea%netscape.com
61fe26d0b7 Allocate space for the slot count as well.
git-svn-id: svn://10.0.0.236/trunk@103492 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-21 22:53:02 +00:00
relyea%netscape.com
3b3177349b SlotFlags should have a different quote char if they aren't escaped
git-svn-id: svn://10.0.0.236/trunk@103491 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-21 22:52:27 +00:00
pschwartau%netscape.com
9fd36cca92 Make formatArray() work in Rhino. Improve getState() by checking for more whitespace characters.
git-svn-id: svn://10.0.0.236/trunk@103488 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-21 22:44:46 +00:00
pchen%netscape.com
ee539ee4e4 Fix for smoketest blocker 100702, remove extra lines caused by misapplied
patch for bug 98107


git-svn-id: svn://10.0.0.236/trunk@103470 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-21 20:19:39 +00:00
cls%seawood.org
4b3d12095a Adding windowwatcher to REQUIRES to fix myotonic bustage.
Caused by checkin for bug 97907


git-svn-id: svn://10.0.0.236/trunk@103468 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-21 19:59:35 +00:00
alecf%netscape.com
5e5b3d7e09 add url to GraphViz in the comments
git-svn-id: svn://10.0.0.236/trunk@103467 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-21 19:49:25 +00:00
mkaply%us.ibm.com
004476b5b7 More OS/2 bustage
git-svn-id: svn://10.0.0.236/trunk@103465 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-21 19:31:37 +00:00
relyea%netscape.com
d93824a08c Fix JSS required prototypes. Bug 100791
git-svn-id: svn://10.0.0.236/trunk@103463 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-21 19:05:46 +00:00
pinkerton%netscape.com
c3cdc9e186 make the system unit of mousewhell scrolling 3 lines on osx. r=sdagley/sr=sfraser/a=chofmann. bug# 100799
git-svn-id: svn://10.0.0.236/trunk@103459 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-21 18:27:41 +00:00
mkaply%us.ibm.com
eb9bf61686 One more REQUIRES issue for windows
git-svn-id: svn://10.0.0.236/trunk@103456 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-21 16:34:42 +00:00
ian.mcgreer%sun.com
8319e5b9ae add entrust global ca's
git-svn-id: svn://10.0.0.236/trunk@103454 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-21 15:43:30 +00:00
mkaply%us.ibm.com
549f12e000 remove spaces in Makefile
git-svn-id: svn://10.0.0.236/trunk@103453 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-21 15:38:44 +00:00
mkaply%us.ibm.com
f814791b71 Windows REQUIRES bustage
git-svn-id: svn://10.0.0.236/trunk@103452 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-21 15:22:27 +00:00
mkaply%us.ibm.com
7efa54e569 myotonic REQUIRES bustage
git-svn-id: svn://10.0.0.236/trunk@103451 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-21 14:59:09 +00:00
alecf%netscape.com
a67226f760 oops, remove this chrome line - for REQUIRES builds only
git-svn-id: svn://10.0.0.236/trunk@103450 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-21 14:28:26 +00:00
alecf%netscape.com
0e4d766ac2 check in non-perl use of REQUIRES line to speed the build (bug 98371)
r=cls


git-svn-id: svn://10.0.0.236/trunk@103449 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-21 14:25:16 +00:00
timeless%mac.com
bab5dc4c87 Bug 100873 JS Hard Codes JS_HAVE_LONG_LONG to the detriment of FreeBSD
r=cls sr=shaver


git-svn-id: svn://10.0.0.236/trunk@103448 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-21 14:09:54 +00:00
mkaply%us.ibm.com
01bcd3003a #97907
r=kaie, r=dcone, sr=jst
Checkin for Roland.Mainz@informatik.med.uni-giessen.de - add error codes to printing


git-svn-id: svn://10.0.0.236/trunk@103447 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-21 13:52:39 +00:00
karnaze%netscape.com
58ca0b5118 new regression tests developed by alexsavulov not affecting the build.
git-svn-id: svn://10.0.0.236/trunk@103446 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-21 13:49:00 +00:00
mkaply%us.ibm.com
e8268d4b78 OS/2 bustage
git-svn-id: svn://10.0.0.236/trunk@103445 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-21 13:46:45 +00:00
karnaze%netscape.com
a84183a301 bug 92143 - alexsavulov's patch for special handling of nowrap on <td> when there is a width. sr=attinasi, r=karnaze.
git-svn-id: svn://10.0.0.236/trunk@103444 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-21 13:43:18 +00:00
kin%netscape.com
ffd4f979fb Fix for bug #92215: [Table Printing] Mozilla crashes when printing the front page of slashdot
Modified nsBlockFrame::ReflowDirtyLines() so that it
removes any floaters on it's continuing frames list,
if they are on lines that are being pulled up.

r=dbaron@fas.harvard.edu  sr=waterson@netscape.com


git-svn-id: svn://10.0.0.236/trunk@103443 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-21 13:41:52 +00:00
hwaara%chello.se
176158cfbe #94836, fix some more issues with Open Address. Final part of cleanup.
r=doron, sr=alecf


git-svn-id: svn://10.0.0.236/trunk@103442 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-21 13:40:46 +00:00
hwaara%chello.se
86a9c3e8b7 #99702, removing more ugly cruft.
rs=sspitzer


git-svn-id: svn://10.0.0.236/trunk@103441 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-21 13:31:11 +00:00
peterv%netscape.com
d0a5cd0748 Improving transformiix test harness. Adding better error reporting, range selection, support for loading text-only reference files, ignore namespace attributes, cleanup code. Code by Pike, sicking and me. r=Pike. Not part of the build.
git-svn-id: svn://10.0.0.236/trunk@103439 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-21 12:23:25 +00:00
ssu%netscape.com
c872b19750 fixing bug 86869 - From URL: should be URL:. r=ssu, moa=dveditz.
git-svn-id: svn://10.0.0.236/trunk@103438 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-21 07:45:37 +00:00
cls%seawood.org
d6143aa0ed Adding import to REQUIRES to fix tinderbox bustage
git-svn-id: svn://10.0.0.236/trunk@103437 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-21 07:44:17 +00:00
mscott%netscape.com
52b4b8bd15 Bug #100608 --> for ldap, min # of result for popup is 2
r=hewitt
sr=sspitzer


git-svn-id: svn://10.0.0.236/trunk@103436 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-21 07:33:14 +00:00
ssu%netscape.com
9203a23690 fixing bug 99526 - update uninstaller to be able to undo the new MAPI settings set by mail. r=dveditz, sr=mscott. affects windows platforms only.
git-svn-id: svn://10.0.0.236/trunk@103435 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-21 06:33:46 +00:00
jaggernaut%netscape.com
42e88e1d2a Fix js strict warning about trailing comma in object initializer. r=mozbot
git-svn-id: svn://10.0.0.236/trunk@103434 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-21 06:30:33 +00:00
dmose%netscape.com
edcb1dfc22 Fix error message display of incorrectly set search filters (bug 79935). r=leif@netscape.com, sr=bienvenu@netscape.com
git-svn-id: svn://10.0.0.236/trunk@103429 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-21 05:26:32 +00:00
stephend%netscape.com
ca2a8b6e84 Bug 58571. JS strict warnings in searchDialog.js r=naving@netscape.com sr=sspitzer@netscape.com
git-svn-id: svn://10.0.0.236/trunk@103428 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-21 05:11:14 +00:00
ccarlen%netscape.com
3c83c48108 Bug 99387 - turbo gain minimized due to profile support. Now observing a notifier which is sent to forget passwords without a profile shutdown. r=bhuvan/sr=mscott
git-svn-id: svn://10.0.0.236/trunk@103427 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-21 05:04:25 +00:00
bienvenu%netscape.com
6742d58fde fix unescaped send later uris in profile migration code r=naving, sr=sspitzer 91936
git-svn-id: svn://10.0.0.236/trunk@103426 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-21 04:43:16 +00:00
bienvenu%netscape.com
5e24bbb0b3 fix unescaped send later uris set up by old profile migration code r=naving, sr=sspitzer 91936
git-svn-id: svn://10.0.0.236/trunk@103425 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-21 04:41:20 +00:00
naving%netscape.com
d4494eb19a 70252 62437 r=bienvenu sr=sspitzer Use the platform charset while converting filter name etc
from 4x to 6x.


git-svn-id: svn://10.0.0.236/trunk@103423 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-21 04:34:13 +00:00
jst%netscape.com
3cb85318a9 Backing out part of last checkin that wasn't supposed to be checked in.
git-svn-id: svn://10.0.0.236/trunk@103422 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-21 04:33:47 +00:00
ducarroz%netscape.com
dda1ec3315 Fix for bug 57902 (second try). This time, the file size check is done after the file has been closed. R=varada, SR=bienvenu
git-svn-id: svn://10.0.0.236/trunk@103421 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-21 04:28:20 +00:00
sfraser%netscape.com
991911506c Fix for bugscape bug 8740 (nsISound does not work on Mac OS X). Have to call EnterMovies() on Mac OS X, so just moving it out of the TARGET_CARBON #ifdef. r=beard, pinkerton. sr=jst
git-svn-id: svn://10.0.0.236/trunk@103420 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-21 04:27:04 +00:00
darin%netscape.com
614db7419e fixes bug 97997 "easyweb.tdcanadatrust.com does not display" r=bbaetz, sr=dougt
git-svn-id: svn://10.0.0.236/trunk@103419 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-21 03:59:02 +00:00
jst%netscape.com
6d5f67dfc9 Fixing bug 100847. Removing nsIXMLDocument::SetTitle() since it's not needed any more. r=heikki@netscape.com, sr=hyatt@netscape.com
git-svn-id: svn://10.0.0.236/trunk@103418 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-21 03:55:50 +00:00
cls%seawood.org
ad96de8459 Updating REQUIRES list for mfcembed.
Bug #98371


git-svn-id: svn://10.0.0.236/trunk@103414 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-21 03:41:41 +00:00
bzbarsky%mit.edu
7243411c66 Bustage fix. replace nsIRequest::LOAD_FROM_CACHE with
::nsIRequest::LOAD_FROM_CACHE


git-svn-id: svn://10.0.0.236/trunk@103413 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-21 03:35:49 +00:00
jst%netscape.com
672cd5f0d3 Tweaking core document classname to make my last patch actually do the right thin in all cases.
git-svn-id: svn://10.0.0.236/trunk@103412 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-21 03:23:33 +00:00
nelsonb%netscape.com
c4b44f9b2f Add support for new TLS AES ciphersuites. Bug 87021.
git-svn-id: svn://10.0.0.236/trunk@103410 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-21 03:09:32 +00:00
nelsonb%netscape.com
f978c68393 Add support to TLS for new 128-bit and 256-bit AES ciphersuites. 87021.
git-svn-id: svn://10.0.0.236/trunk@103408 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-21 03:07:35 +00:00
shanjian%netscape.com
468203fe10 #99666 page is displayed as blank in certain situation
r=harishd, sr=rpotts


git-svn-id: svn://10.0.0.236/trunk@103407 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-21 02:38:37 +00:00
srilatha%netscape.com
e026314a27 Fix for bug # 100645. NextToken returns utf-8 string instead of ucs2.
r=dmose, sr=alecf


git-svn-id: svn://10.0.0.236/trunk@103406 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-21 02:24:19 +00:00
sspitzer%netscape.com
c5bb663095 fix for bug #98037. sometimes newsgroups would be marked as all read.
bad call to CleanupNewsgroupList(), which calls FinishXOVERLINE()
which adjusts the unread set.  r=mscott, sr=bienvenu


git-svn-id: svn://10.0.0.236/trunk@103405 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-21 02:20:27 +00:00
morse%netscape.com
b6306e7966 bug 100682 domain cookies from sites having IP url's, r=sgehani, sr=alecf
git-svn-id: svn://10.0.0.236/trunk@103404 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-21 02:08:21 +00:00
hewitt%netscape.com
c12dd73fd5 93857 - Both 'To:' and 'Bcc:' options simultaneously checked in composition window, r=varada, sr=mscott
git-svn-id: svn://10.0.0.236/trunk@103403 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-21 02:02:11 +00:00
srilatha%netscape.com
674ae0bc0b Fix for bug 98566. Adding support for simple MAPI
r=law, sr=alecf


git-svn-id: svn://10.0.0.236/trunk@103402 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-21 02:02:05 +00:00
srilatha%netscape.com
cd6584d3a7 *** empty log message ***
git-svn-id: svn://10.0.0.236/trunk@103401 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-21 02:00:24 +00:00
bzbarsky%mit.edu
7634772e28 Make nsViewSourceChannel implement nsICachingChannel and nsIHttpChannel
as appropriate so that the docshell will do the right things as far as
pulling it from cache.  bug 99107, r=chak@netscape.com,
sr=darin@netscape.com


git-svn-id: svn://10.0.0.236/trunk@103400 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-21 01:57:37 +00:00
naving%netscape.com
25580ab2be 100326 r=bienvenu sr=sspitzer Abort the compaction if writing to folder fails.
90702 r=bienvenu sr=sspitzer Update the expungedBytes for offline stores after compaction
95584 r/sr=bienvenu CleanupTempFiles in case compaction on a folder cannot start because
some other operation is in progress.


git-svn-id: svn://10.0.0.236/trunk@103399 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-21 01:40:30 +00:00
stephend%netscape.com
509ffa03df Bug 100656. about:config 'Prefs' column should read 'Preference Name' r=chipc@netscape.com, sr=sspitzer@netscape.com. Patch by Bradley Hart <bhart00@yahoo.com>
git-svn-id: svn://10.0.0.236/trunk@103398 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-21 01:39:59 +00:00
tao%netscape.com
9e76d326d7 97606: Default character coding setting is blank in pref.
(r=dveditz,sr=alecf). add navigator.proeprties to en-{win,mac}.jar.


git-svn-id: svn://10.0.0.236/trunk@103397 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-21 01:25:36 +00:00
relyea%netscape.com
d4e3d4a00f Fix assert to be correct!
git-svn-id: svn://10.0.0.236/trunk@103395 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-21 01:20:08 +00:00
tao%netscape.com
f4427c7e0f 97606: Default character coding setting is blank in pref
(r=dveditz,sr=alecf). add navigator.proeprties to en-{win,mac}.jar


git-svn-id: svn://10.0.0.236/trunk@103392 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-21 01:16:59 +00:00
shrutiv%netscape.com
8edf2285a1 Fix for bug 100204: Customized Linux build does not work if dir name
contains spaces (r=tao)
Including quotes in directory path of tar command


git-svn-id: svn://10.0.0.236/trunk@103391 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-21 01:11:19 +00:00
heikki%netscape.com
0be4058e88 Bug 100795 Mac project changes.
git-svn-id: svn://10.0.0.236/trunk@103390 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-21 01:08:36 +00:00
jst%netscape.com
8ceabb2e83 Fixing bug 100795. Removign the method load() from HTML documents, implement it only on XML documents since the name 'load' blocks existing global functions named 'load' from being called from event handlers in the document (since document.load is found before window.load in the scope of event handlers). HTMLDocument.load and XULDocument.load were never implemented any way. r=heikki@netscape.com, sr=vidur@netscape.com
git-svn-id: svn://10.0.0.236/trunk@103389 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-21 01:07:53 +00:00
waterson%netscape.com
289f661b27 Bug 96228. Make nsContainerFrame::PositionFrameView position _only_ the frame's view (don't recur). Explicitly call nsContainerFrame::PositionChildViews as appropriate when moving a frame post-Reflow. Consolidate view positioning logic duplicated between PositionFrameView and SyncFrameViewAfterReflow, which now correctly computes offset for anonymous view in nsScrollFrame and accounts for scrolled views. r=kmcclusk,karnaze sr=attinasi
git-svn-id: svn://10.0.0.236/trunk@103388 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-21 00:53:29 +00:00
bryner%netscape.com
d3fdac2234 Fixing build bustage. r=brendan.
git-svn-id: svn://10.0.0.236/trunk@103387 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-21 00:44:22 +00:00
cmanske%netscape.com
204d58e195 Tweaks to make relative url work, b=72583, r=syd, sr=hewitt
git-svn-id: svn://10.0.0.236/trunk@103386 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-21 00:38:47 +00:00
rangansen%netscape.com
f6b4428c94 r=rangansen sr=kin@netscape.com
bug# 100193 - updating PSM version


git-svn-id: svn://10.0.0.236/trunk@103385 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-21 00:20:34 +00:00
relyea%netscape.com
7cb64e2de7 Duh. Don't try to get a reference to the slot until we know that it's not NULL.
git-svn-id: svn://10.0.0.236/trunk@103383 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-21 00:13:10 +00:00
rogerl%netscape.com
273acc5945 Fixed value/type mismatch bugs. Fixed some warnings.
git-svn-id: svn://10.0.0.236/trunk@103382 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-20 23:52:06 +00:00
srilatha%netscape.com
1f34a21d06 Fix for smoketest blocker bugscape bug 9703
r=dmose,sr=sspitzer, a=granrose


git-svn-id: svn://10.0.0.236/trunk@103381 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-20 23:50:51 +00:00
beard%netscape.com
8276df6954 Fix crasher on Mac.
git-svn-id: svn://10.0.0.236/trunk@103380 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-20 23:39:06 +00:00
idk%eng.sun.com
a420243c8a fix for 57337 [libjar does not retrieve link information]
r  = dveditz@netscape.com
sr = brendan@mozilla.org


git-svn-id: svn://10.0.0.236/trunk@103378 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-20 23:33:23 +00:00
relyea%netscape.com
9c16ebd7f8 Sigh, some platforms have stdio.h included, some don't.
git-svn-id: svn://10.0.0.236/trunk@103377 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-20 23:19:15 +00:00
relyea%netscape.com
6f50db662d Replace variable that belongs in an ifdef.
git-svn-id: svn://10.0.0.236/trunk@103376 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-20 23:15:12 +00:00
alecf%netscape.com
b668e19883 update with clustering ability and comments
git-svn-id: svn://10.0.0.236/trunk@103375 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-20 23:01:21 +00:00
hewitt%netscape.com
a7487fd6d0 97574 - Implement toolbarbutton and kill menubutton, r=blake, sr=hyatt
git-svn-id: svn://10.0.0.236/trunk@103374 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-20 22:51:30 +00:00
dsirnapalli%netscape.com
0a5c6c9243 Added line var setCharsetValueTo = "ISO-8859-1";
git-svn-id: svn://10.0.0.236/trunk@103373 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-20 22:51:25 +00:00
relyea%netscape.com
fbaa312653 Fix compiler errors on HP, Linux, AIX, and Solaris
git-svn-id: svn://10.0.0.236/trunk@103372 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-20 22:16:25 +00:00
relyea%netscape.com
f13d9297bd Fix compiler warnings on Solaris, Linux, HP, and AIX
git-svn-id: svn://10.0.0.236/trunk@103371 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-20 22:15:32 +00:00
beard%netscape.com
9af53e73a4 Fix Mac build bustage.
git-svn-id: svn://10.0.0.236/trunk@103370 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-20 22:15:14 +00:00
relyea%netscape.com
0ffcdcfc2e Fix compiler warnings on AIX, Linux, HP, and Solaris.
git-svn-id: svn://10.0.0.236/trunk@103369 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-20 22:14:09 +00:00
hewitt%netscape.com
b762194700 97574 - Implement toolbarbutton and kill menubutton, r=blake, sr=hyatt
git-svn-id: svn://10.0.0.236/trunk@103368 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-20 22:13:03 +00:00
relyea%netscape.com
c774d09663 Fix compiler warnings on HP, AIX, Linux, and Solaris.
git-svn-id: svn://10.0.0.236/trunk@103367 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-20 22:12:23 +00:00
relyea%netscape.com
2e78d42585 Remove usage of KeyDBHandle from the jar code.
git-svn-id: svn://10.0.0.236/trunk@103366 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-20 22:11:19 +00:00
relyea%netscape.com
b5252ef10f Fix compiler warnings on HP, Linux, Solaris, and AIX.
git-svn-id: svn://10.0.0.236/trunk@103365 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-20 22:09:49 +00:00
jst%netscape.com
b931268a98 Adding new interface file, not part of the build yet.
git-svn-id: svn://10.0.0.236/trunk@103364 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-20 22:09:41 +00:00
relyea%netscape.com
00c62fcc57 Fix compiler warnings on Solaris, Linux, AIX, HP.
Remove dependency on header files in softoken.


git-svn-id: svn://10.0.0.236/trunk@103363 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-20 22:07:33 +00:00
relyea%netscape.com
e14e336a0e Fix Linux warnings.
git-svn-id: svn://10.0.0.236/trunk@103362 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-20 22:02:46 +00:00
relyea%netscape.com
eca0a94b81 Fix compiler warnings.
git-svn-id: svn://10.0.0.236/trunk@103361 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-20 22:01:37 +00:00
relyea%netscape.com
22d7ca9cce Handle issues with raw keys not being visible.
git-svn-id: svn://10.0.0.236/trunk@103360 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-20 22:00:05 +00:00
relyea%netscape.com
5850b3c43f Fix compiler warnings
git-svn-id: svn://10.0.0.236/trunk@103359 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-20 21:59:11 +00:00
relyea%netscape.com
b349acd79b Compile in the new brave world where Low level structures are visible.
git-svn-id: svn://10.0.0.236/trunk@103358 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-20 21:54:33 +00:00
relyea%netscape.com
e9d550d3e0 Fix compiler warnings.
git-svn-id: svn://10.0.0.236/trunk@103357 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-20 21:52:59 +00:00
relyea%netscape.com
1a8f6540c8 rsaperf uses low level external headers. Get those headers from the
development tree.


git-svn-id: svn://10.0.0.236/trunk@103356 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-20 21:52:06 +00:00
relyea%netscape.com
689040a632 Remove unneeded references to the KeyDB data structure.
fix compilier warnings.


git-svn-id: svn://10.0.0.236/trunk@103355 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-20 21:50:21 +00:00
relyea%netscape.com
0023cdd352 Fix compilier warnings.
Remove calls to low level key structures.


git-svn-id: svn://10.0.0.236/trunk@103354 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-20 21:47:29 +00:00
relyea%netscape.com
f9427b6c6c Remove dead code.
Fix compiler warnings.


git-svn-id: svn://10.0.0.236/trunk@103353 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-20 21:45:41 +00:00
relyea%netscape.com
6e05bd575f Fix compiler warnings.
Use the new Initalization functions for Modules.


git-svn-id: svn://10.0.0.236/trunk@103352 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-20 21:44:20 +00:00
relyea%netscape.com
d931f220fc BlapiTest required headers are no longer public. Get them from the
developement directory.


git-svn-id: svn://10.0.0.236/trunk@103350 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-20 21:42:54 +00:00
relyea%netscape.com
21438ed487 Fix warnings on Linux, Solaris, AIX, HP.
git-svn-id: svn://10.0.0.236/trunk@103349 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-20 21:41:34 +00:00
relyea%netscape.com
42c00a9b16 Export the new initialization functions
git-svn-id: svn://10.0.0.236/trunk@103348 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-20 21:40:24 +00:00
relyea%netscape.com
da09c34349 Make sure the Low level initialization function signature match. Include the
header to get the correct prototypes.


git-svn-id: svn://10.0.0.236/trunk@103347 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-20 21:39:58 +00:00
relyea%netscape.com
fba56f7d78 Fix warnings on Linux, HP, Solaris, and AIX.
git-svn-id: svn://10.0.0.236/trunk@103346 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-20 21:38:26 +00:00
relyea%netscape.com
6d1b3b062a Fix compilier warnings on AIX, Solaris, HP, and Linux.
git-svn-id: svn://10.0.0.236/trunk@103345 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-20 21:37:16 +00:00
relyea%netscape.com
236f6cb96c Fix compilier warnings on AIX, HP, Linux, and Solaris.
git-svn-id: svn://10.0.0.236/trunk@103344 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-20 21:34:42 +00:00
relyea%netscape.com
c7bce077ad 1) fix compilier warnings on AIX, Solaris, HP, and Linux.
2) remove Dependency on low key structures in the soft token.


git-svn-id: svn://10.0.0.236/trunk@103343 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-20 21:30:48 +00:00
relyea%netscape.com
2938d8768c Remove dependancy on direct calls inside softoken.
git-svn-id: svn://10.0.0.236/trunk@103342 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-20 21:26:40 +00:00
ian.mcgreer%sun.com
f3b2424469 add the diagram
git-svn-id: svn://10.0.0.236/trunk@103341 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-20 21:24:29 +00:00
relyea%netscape.com
bf40d79d07 1) fix warnings on AIX, HP, Linux, and Solaris.
2) Move private functions into private headers.

3) Sharpen the layer separation between NSS components, especially pkcs #12
and soft token.

4) Remove dead code.


git-svn-id: svn://10.0.0.236/trunk@103340 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-20 21:23:51 +00:00
ian.mcgreer%sun.com
bc5bdc252d add a trust domain diagram; suggestion for cert hash
git-svn-id: svn://10.0.0.236/trunk@103339 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-20 21:22:08 +00:00
relyea%netscape.com
285df75582 1) Fix Solaris, AIX, HP, and Linux warnings. Several were potential real
problems (mostly uninitialized variables in error cases).

2) Start separating softoken from the rest of NSS where appropriate (finish
separating out the key stuff, the cert stuff is coming).

3) Make the prototypes between the new functions consistant.


git-svn-id: svn://10.0.0.236/trunk@103338 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-20 21:05:53 +00:00
ian.mcgreer%sun.com
159f90e97a put in a test for search by nickname
git-svn-id: svn://10.0.0.236/trunk@103337 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-20 20:41:52 +00:00
ian.mcgreer%sun.com
38f6811a67 some cleanup; use list for modules
git-svn-id: svn://10.0.0.236/trunk@103336 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-20 20:40:03 +00:00
ian.mcgreer%sun.com
0e75bc6671 some cleanup; collect token certs in a list
git-svn-id: svn://10.0.0.236/trunk@103335 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-20 20:38:08 +00:00
ian.mcgreer%sun.com
6e9433a3f4 some cleanup in the list code
git-svn-id: svn://10.0.0.236/trunk@103334 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-20 20:33:27 +00:00
nicolson%netscape.com
7466c08078 Fix 100796: calling undeclared functions breaks AIX build
Workaround 100791: misspelled function prototypes in pk11func.h


git-svn-id: svn://10.0.0.236/trunk@103333 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-20 19:16:51 +00:00
shrutiv%netscape.com
ea91f2fe59 Fix for bug 99368: Banner bmp missing on second screen of wizard
Changing bmp file name (r=tao)


git-svn-id: svn://10.0.0.236/trunk@103332 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-20 19:13:45 +00:00
edburns%acm.org
93988bc5d9 Changes to make it work on Linux.
git-svn-id: svn://10.0.0.236/trunk@103331 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-20 18:57:35 +00:00
dsirnapalli%netscape.com
2e68046b35 Automated smoketests for mfcEmbed.
git-svn-id: svn://10.0.0.236/trunk@103330 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-20 18:48:06 +00:00
shrutiv%netscape.com
1c86b6f44e Fix for bug 99409: Customized Linux build works only on WinNT platform
Including "/cygdrive/" in path for tar command (r=tao)


git-svn-id: svn://10.0.0.236/trunk@103329 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-20 18:38:57 +00:00
shrutiv%netscape.com
c9965de2da Fix for bug 98384: CCK built N6.1 does not install additional components
(java, realplayer, winamp, etc.) correctly (r=tao)


git-svn-id: svn://10.0.0.236/trunk@103328 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-20 18:09:03 +00:00
shrutiv%netscape.com
04200a2756 Fix for bug 96914: Support customizing proxies
Adding Proxy.ini to cck wizard (r=tao)


git-svn-id: svn://10.0.0.236/trunk@103327 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-20 17:55:23 +00:00
shrutiv%netscape.com
3bc5595ff4 Fix for bug 96914: Support customizing proxies
Including Proxy screen in CCK wizard (r=tao)


git-svn-id: svn://10.0.0.236/trunk@103326 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-20 17:51:07 +00:00
shrutiv%netscape.com
08af04a016 Fix for bug 96914: Support customizing proxies
UI code for proxies (r=tao)


git-svn-id: svn://10.0.0.236/trunk@103325 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-20 17:48:28 +00:00
shrutiv%netscape.com
49a4405032 Fix for bug 96914: Support customizing proxies
Backend code for customizing proxies (r=tao)


git-svn-id: svn://10.0.0.236/trunk@103324 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-20 17:43:23 +00:00
ian.mcgreer%sun.com
951cdd10fc disable AES for blocksizes > 128 until it is fixed.
git-svn-id: svn://10.0.0.236/trunk@103323 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-20 17:11:08 +00:00
bienvenu%netscape.com
b76811d08d fix smoketest blocker 100747 can't send mail a=granrose
git-svn-id: svn://10.0.0.236/trunk@103321 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-20 16:25:52 +00:00
mkaply%us.ibm.com
3cddf40f06 Bustage strnstr is wrong
git-svn-id: svn://10.0.0.236/trunk@103320 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-20 14:51:00 +00:00
wtc%netscape.com
32657f6603 Bugzilla bug 77788: checked in the bug fix again now that the manifest.mn
file that incorrectly set CFLAGS has been fixed.


git-svn-id: svn://10.0.0.236/trunk@103319 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-20 14:27:54 +00:00
mkaply%us.ibm.com
212ad7d015 #99503
r=dougt, sr=darinr
XP support for FTP to OS/2 servers


git-svn-id: svn://10.0.0.236/trunk@103318 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-20 14:16:14 +00:00
cmanske%netscape.com
a6b318d1c8 Small tweak to fix for bug 72583 because of fix to 97983: use 'url_Path' instead of 'url_Directory' r=brade, sr=kin
git-svn-id: svn://10.0.0.236/trunk@103317 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-20 14:08:35 +00:00
locka%iol.ie
163592a42a Fix missing newline at the end. b=99181 r=chak@netscape.com sr=rpotts@netscape.com
git-svn-id: svn://10.0.0.236/trunk@103315 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-20 13:32:49 +00:00
locka%iol.ie
095099132d nsIWebBrowserSetup frozen and documented. b=99181 r=chak@netscape.com sr=rpotts@netscape.com
git-svn-id: svn://10.0.0.236/trunk@103314 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-20 13:30:59 +00:00
locka%iol.ie
86920db1c5 Added nsITooltipTextProvider.idl to Mac IDL project. b=99181 r=chak@netscape.com sr=rpotts@netscape.com
git-svn-id: svn://10.0.0.236/trunk@103313 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-20 13:28:25 +00:00
locka%iol.ie
ec8e40f618 nsITooltipTextProvider and contract id split out into its own files frozen and documented. b=99181 r=chak@netscape.com sr=rpotts@netscape.com
git-svn-id: svn://10.0.0.236/trunk@103312 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-20 13:25:40 +00:00
ccarlen%netscape.com
775ceae53b Bug 99117 - mail account creation problems under turbo. UnloadAccounts needed to reset some more things. r=bhuvan,dp/sr=mscott
git-svn-id: svn://10.0.0.236/trunk@103311 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-20 13:22:19 +00:00
locka%iol.ie
1e33f16866 NOT PART OF BUILD. Fix to allow multiple plugins off the same type to run at the same time. b=100549
git-svn-id: svn://10.0.0.236/trunk@103310 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-20 13:03:40 +00:00
locka%iol.ie
3661c917e1 nsITooltipTextProvider and contract id split out into its own files frozen and documented. b=99181 r=chak@netscape.com sr=rpotts@netscape.com
git-svn-id: svn://10.0.0.236/trunk@103309 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-20 12:43:28 +00:00
locka%iol.ie
098fb2416a nsITooltipTextProvider and contract id split out into its own files frozen and documented. b=99181 r=chak@netscape.com sr=rpotts@netscape.com
git-svn-id: svn://10.0.0.236/trunk@103308 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-20 12:40:53 +00:00
cls%seawood.org
4cdf497958 Only use LDAP_CFLAGS where needed.
Bug #98924 r=dmose


git-svn-id: svn://10.0.0.236/trunk@103307 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-20 12:30:57 +00:00
locka%iol.ie
2612c1468a nsIContextMenuListener frozen. Updated documentation. b=99181 r=chak@netscape.com sr=rpotts@netscape.com
git-svn-id: svn://10.0.0.236/trunk@103306 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-20 12:15:52 +00:00
locka%iol.ie
aca74ad389 nsIWebBrowser frozen. Updated documentation. b=99181 r=chak@netscape.com sr=rpotts@netscape.com
git-svn-id: svn://10.0.0.236/trunk@103305 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-20 12:14:18 +00:00
rods%netscape.com
3152467394 Should set PrintObject to print "AsIs" if it doesn't have children
Bug 83683 r=kmcclusk r=attinasi


git-svn-id: svn://10.0.0.236/trunk@103304 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-20 12:13:48 +00:00
locka%iol.ie
08529e3db3 nsIEmbeddingSiteWindow frozen. Updated documentation. b=99181 r=chak@netscape.com sr=rpotts@netscape.com
git-svn-id: svn://10.0.0.236/trunk@103303 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-20 12:11:46 +00:00
locka%iol.ie
ff90e0106a NS_InitEmbedding & NS_TermEmbedding become frozen APIs. Updated documentation. b=99181 r=chak@netscape.com sr=rpotts@netscape.com
git-svn-id: svn://10.0.0.236/trunk@103302 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-20 12:08:04 +00:00
cls%seawood.org
ba676d16bf Removing extraneous ldap.h include.
Bug #98924 r=dmose


git-svn-id: svn://10.0.0.236/trunk@103301 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-20 12:03:40 +00:00
cls%seawood.org
1e985db27c Update REQUIRES. Fixing archangel bustage.
git-svn-id: svn://10.0.0.236/trunk@103300 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-20 11:05:19 +00:00
cls%seawood.org
986d6a7494 Declare xml version before comments. Fixing problem with mailnews not showing up in Tasks menu.
r=pavlov sr=jst


git-svn-id: svn://10.0.0.236/trunk@103299 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-20 10:52:28 +00:00
peterv%netscape.com
d69ca49133 Fixing bug 65486. Implementing HTML[I]FrameElement.contentWindow, r=harishd@netscape.com, sr=hyatt@netscape.com
git-svn-id: svn://10.0.0.236/trunk@103297 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-20 10:15:42 +00:00
cls%seawood.org
bc0787adda Initial version. Added nsCOMPtr.h
Bug #99698 not part of build (yet)


git-svn-id: svn://10.0.0.236/trunk@103296 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-20 10:08:33 +00:00
stephend%netscape.com
46d2fd5063 Bug 100178. Subscribe.xul changes for XUL 1.0. r=kerz@netscape.com sr=hewitt@netscape.com
git-svn-id: svn://10.0.0.236/trunk@103295 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-20 08:38:11 +00:00
simon%softel.co.il
fea5729a35 Add Arabic and Hebrew ISO standard encodings to the default list for mail edit. Bug 99108, r=momoi, sr=kin
git-svn-id: svn://10.0.0.236/trunk@103294 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-20 08:07:09 +00:00
dmose%netscape.com
cc41e310ab Have the LDAP autocomplete session return an error item on failure; the user can select this item and an alert box with more details will be popped up. r=ducarroz@netscape.com, sr=bienvenu@netscape.com
git-svn-id: svn://10.0.0.236/trunk@103293 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-20 07:59:15 +00:00
jst%netscape.com
24a0f2340e Fixing bug 65486. Implementing HTML[I]FrameElement.contentWindow, r=harishd@netscape.com, sr=hyatt@netscape.com
git-svn-id: svn://10.0.0.236/trunk@103292 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-20 07:58:49 +00:00
dmose%netscape.com
faa784e099 Add support to the autocomplete widget, interfaces, and LDAP autocomplete session for returning "failure items" which allow the user to select an error entry and have it fire an arbitrary command, rather than actually filling in the text of the item. Part of bug 79935. r=hewitt@netscape.com, sr=bievenu@netscape.com
git-svn-id: svn://10.0.0.236/trunk@103291 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-20 07:55:59 +00:00
jst%netscape.com
5a4ec1483a Adding new interface for bug 65486, implement HTML[I]FrameElement.contentWindow. r=harishd@netscape.com, sr=hyatt@netscape.com. Not used yet.
git-svn-id: svn://10.0.0.236/trunk@103290 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-20 07:53:37 +00:00
dmose%netscape.com
03ba9cd5db Theme changes to support LDAP autocomplete error-handling. Icons from marlon@netscape.com; css by me. r=jaggernaut@netscape.com, sr=bienvenu@netscape.com
git-svn-id: svn://10.0.0.236/trunk@103289 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-20 07:49:54 +00:00
dmose%netscape.com
ae53bba07e Mac build system changes to jar up the LDAP chrome stuff when building with 'options ldap'. Part of fix for bug 79935; r=pavlov@netscape.com.
git-svn-id: svn://10.0.0.236/trunk@103288 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-20 07:47:07 +00:00
dmose%netscape.com
57f5288a54 Add internationalized error message support to the LDAP XPCOM SDK; part of bug 79935. r=jaggernaut@netscape.com, sr=bienvenu@netscape.com
git-svn-id: svn://10.0.0.236/trunk@103287 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-20 07:46:58 +00:00
hyatt%netscape.com
2ab7945bef Make XUL boxes check maxheight/maxwidth attrs as well as minwidth. r/sr=hewitt,jst
git-svn-id: svn://10.0.0.236/trunk@103286 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-20 07:46:13 +00:00
hyatt%netscape.com
e183b6f97e Fire DOM event when title changes. r/sr=waterson,jst
git-svn-id: svn://10.0.0.236/trunk@103285 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-20 07:43:56 +00:00
hyatt%netscape.com
a1d1c14ea3 Fix XUL popup listener to check for new contextmenu syntax. r/sr=hewitt,jst
git-svn-id: svn://10.0.0.236/trunk@103284 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-20 07:42:48 +00:00
hyatt%netscape.com
dbdc08cf3f Fix XUL atoms to match spec for minwidth/minheight/maxwidth/maxheight. r/sr=hewitt,jst
git-svn-id: svn://10.0.0.236/trunk@103283 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-20 07:40:45 +00:00
hewitt%netscape.com
e74681453a 97574 - implement toolbarbutton, kill menubutton, r=blake, sr=hyatt
git-svn-id: svn://10.0.0.236/trunk@103282 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-20 07:33:13 +00:00
hewitt%netscape.com
48aeb1be8d 97574 - Implement toolbarbutton and kill menubutton, r=blake, sr=hyatt
git-svn-id: svn://10.0.0.236/trunk@103281 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-20 07:10:52 +00:00
hewitt%netscape.com
5da5088f86 97574 - Implement toolbarbutton and kill menubutton (except outliner.css), r=blake, sr=hyatt
git-svn-id: svn://10.0.0.236/trunk@103279 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-20 07:08:29 +00:00
jst%netscape.com
6237e41d0e Checking in Roland.Mainz@informatik.med.uni-giessen.de's fix for bug 87285, MathML broken in Xlib-toolkit and Xprint. r=rbs@maths.uq.edu.au, sr=kin@netscape.com
git-svn-id: svn://10.0.0.236/trunk@103277 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-20 05:13:26 +00:00
rginda%netscape.com
53d25e8e30 - chatzilla only -
bug 59453, add options to turn off individual munger rules
patch by samuel@sieb.net, r=me


git-svn-id: svn://10.0.0.236/trunk@103276 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-20 05:04:17 +00:00
srilatha%netscape.com
4d43ce2bc5 Fix for bugscape bug #6906. sr=sspitzer.
part of simple MAPI UI checkin. added some comments.


git-svn-id: svn://10.0.0.236/trunk@103275 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-20 05:01:47 +00:00
nelsonb%netscape.com
a8c509b734 Generate larger block of key material correctly for SSL3 as well as TLS.
Add assert to detect if key material is ever too small again.


git-svn-id: svn://10.0.0.236/trunk@103273 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-20 04:36:14 +00:00
stephend%netscape.com
37c8348809 Bug 58567. JavaScript strict warnings (re-declarations). r=walk84@usa.net/naving@netscape.com, sr=hewitt@netscape.com
git-svn-id: svn://10.0.0.236/trunk@103271 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-20 04:13:42 +00:00
aaronl%netscape.com
f5cf7d0c84 Bug 98752. Clear consistent MSAA events to indicate when busy loading a page, and when finished. r=jgaunt, sr=vidur
git-svn-id: svn://10.0.0.236/trunk@103270 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-20 04:09:23 +00:00
nelsonb%netscape.com
0a9d418750 Increase the amount of key material derived from the master secret to that
it will be enough for AES with 256-bit keys.


git-svn-id: svn://10.0.0.236/trunk@103268 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-20 03:55:16 +00:00
stephend%netscape.com
1f7d17595e Bug 100509. JS strict warning (re-declaration) r=doron, sr=blake
git-svn-id: svn://10.0.0.236/trunk@103265 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-20 03:22:51 +00:00
naving%netscape.com
a25ea2b8eb 95584 r=bienvenu sr=mscott. Made it so that compacting folders and downnloading messages do not
overwrite each others data.


git-svn-id: svn://10.0.0.236/trunk@103264 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-20 03:07:59 +00:00
ducarroz%netscape.com
695c98b84e Fix for bug 88079 and bug 57902. As write to file is done using a buffer, we need to check the return code of the flush to be sure we phisically wrote the data to disk. Also check the file size when we are done writing to avoid sending empty mail. In the case we fetch a local file, verify that the file path is a valid file and not a directory. R=varada, SR=bienvenu
git-svn-id: svn://10.0.0.236/trunk@103263 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-20 02:59:58 +00:00
nelsonb%netscape.com
05dd12251a Fix pk11_DecryptInit for AES. It was telling AES to encrypt, not decrypt.
git-svn-id: svn://10.0.0.236/trunk@103262 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-20 02:56:18 +00:00
mkaply%us.ibm.com
9de09dfa55 OS/2 bustage
PR_STATIC_CALLBACK is not needed here


git-svn-id: svn://10.0.0.236/trunk@103261 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-20 02:38:56 +00:00
dbaron%fas.harvard.edu
9dff5d268e Fix crash due to unsigned integer underflow. b=100451 r=jag, harishd sr=waterson
git-svn-id: svn://10.0.0.236/trunk@103259 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-20 02:15:21 +00:00
darin%netscape.com
3a5782e22d fixes build bustage... forgot to checkin these makefile changes.
git-svn-id: svn://10.0.0.236/trunk@103258 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-20 02:05:50 +00:00
rogerl%netscape.com
0504d72851 Added 'version' function for test suite.
git-svn-id: svn://10.0.0.236/trunk@103257 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-20 01:41:03 +00:00
rogerl%netscape.com
4119277f1d Fixes for missing global object properties, various bug fixes.
git-svn-id: svn://10.0.0.236/trunk@103256 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-20 01:35:42 +00:00
darin%netscape.com
224e7e0865 removing unused file: nsIResChannel.idl
git-svn-id: svn://10.0.0.236/trunk@103255 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-20 01:34:13 +00:00
darin%netscape.com
11f36e31c0 mac project change for bug 99410
git-svn-id: svn://10.0.0.236/trunk@103254 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-20 01:33:37 +00:00
darin%netscape.com
2dc26f5426 fixes bug 99410 "further res protocol cleanup" r=dougt, sr=mscott
git-svn-id: svn://10.0.0.236/trunk@103253 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-20 01:32:16 +00:00
gordon%netscape.com
1da5a472fc Fix bug 92348, browser won't start if cache capacities set to 0. Added
check to fail nsCacheService::ActivateEntry() if neither disk or memory
cache devices are enabled, or if the memory cache device is not enabled
and the request if for a non-stream-based entry. r=gagan, sr=dougt.

Also changing pref name for cache parent directory according to suggestion
in bug 78480.  r=gagan, sr=darin.


git-svn-id: svn://10.0.0.236/trunk@103251 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-20 01:12:35 +00:00
gordon%netscape.com
eeddb9caeb Fix bug 100216, top crash on shutdown. Added null pointer check to
nsCacheEntryDescriptor::RequestDataSizeChange(). r=gagan, sr=darin.


git-svn-id: svn://10.0.0.236/trunk@103250 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-20 01:09:01 +00:00
naving%netscape.com
88489460f3 62347 r=bienvenu sr=sspitzer Make non ascii folder names from 4x rules.dat work in 6x.
git-svn-id: svn://10.0.0.236/trunk@103249 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-20 00:59:22 +00:00
naving%netscape.com
27383dcd0f 70252 r=bienvenu sr=sspitzer. Make 4x non-ascii filter names and conditions migrate correctly to 6x.
git-svn-id: svn://10.0.0.236/trunk@103248 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-20 00:57:17 +00:00
jband%netscape.com
f20e03b41b fix bug 100222. Fix crash by only releasing other objects in xpcwrappedjs dtor if xpconnect has not yet shutdown. r=dbradley sr=jst.
git-svn-id: svn://10.0.0.236/trunk@103247 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-20 00:51:38 +00:00
peterlubczynski%netscape.com
a19be96dd8 Fix for OS X crash with bundle type plugins bug 98729 r=beard sr=attinasi
git-svn-id: svn://10.0.0.236/trunk@103245 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-20 00:46:50 +00:00
blakeross%telocity.com
03fd797622 Turbo turns off if you go to the advanced panel and press ok without making any changes (99677). r=hewitt sr=ben
git-svn-id: svn://10.0.0.236/trunk@103244 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-20 00:38:55 +00:00
varada%netscape.com
80af67899d fix for #89950;set focus to msg compose fields after select addresses dialog;r=ducarroz;sr=bienvenu
git-svn-id: svn://10.0.0.236/trunk@103243 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-20 00:38:53 +00:00
varada%netscape.com
e8c3692c0a fix for bug#99234;duplicate domain name check for send format;r=ducarroz;sr=mscott
git-svn-id: svn://10.0.0.236/trunk@103242 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-20 00:31:14 +00:00
ian.mcgreer%sun.com
c95b1f54fe checkin of threadsafe hashtable; copied from ckfw/hash.c but using NSS types
git-svn-id: svn://10.0.0.236/trunk@103241 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-20 00:28:36 +00:00
waldemar%netscape.com
824f0e3d5e Transitioned to paragraph/DIV-based styles
git-svn-id: svn://10.0.0.236/trunk@103239 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-20 00:13:32 +00:00
waldemar%netscape.com
6cff0ce7ce Added time-to-string and time-to-short-string
git-svn-id: svn://10.0.0.236/trunk@103238 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-20 00:12:13 +00:00
sfraser%netscape.com
f40a806dad Fix for bug 97866. Fixes async file I/O to ensure that we always call WaitOnThisThread if we're doing an async call (which does not wait if the notifier has already fired). Also don't bother checking return values from PBRead/WriteAsync, since they never fail, but do check the return value of the PBReadSync call. Fixes synchronization problems on Mac OS X. r=gordon, a=wtc.
git-svn-id: svn://10.0.0.236/trunk@103237 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-20 00:08:36 +00:00
gerv%gerv.net
ae1d5501a1 Oops.
git-svn-id: svn://10.0.0.236/trunk@103236 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-20 00:02:59 +00:00
despotdaemon%netscape.com
9260b72d4f Pseudo-automatic update of changes made by endico@mozilla.org.
git-svn-id: svn://10.0.0.236/trunk@103233 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-19 23:04:24 +00:00
despotdaemon%netscape.com
b000958e4c Pseudo-automatic update of changes made by endico@mozilla.org.
git-svn-id: svn://10.0.0.236/trunk@103232 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-19 23:03:15 +00:00
despotdaemon%netscape.com
c6970c8aa2 Pseudo-automatic update of changes made by endico@mozilla.org.
git-svn-id: svn://10.0.0.236/trunk@103231 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-19 22:53:40 +00:00
scc%mozilla.org
2281a4d137 bug #98089: ripped new license
git-svn-id: svn://10.0.0.236/trunk@103230 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-19 22:39:41 +00:00
gerv%gerv.net
4448a74f22 More license whackage. We are relicensing the expat makefiles to be compatible with the LGPL and GPL but making it clear that expat itself is under James Clakrk's MIT/X license. Bug 98089.
git-svn-id: svn://10.0.0.236/trunk@103228 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-19 21:50:17 +00:00
mcgreer%netscape.com
256bdc1d8f match changes in dev, implement lookup by nickname for testing
git-svn-id: svn://10.0.0.236/trunk@103227 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-19 21:49:52 +00:00
mcgreer%netscape.com
224311fbd6 the device API is not public, so move:
NSSModule_ ==> nssModule_
NSSSlot_   ==> nssSlot_
NSSToken_  ==> nssToken
Functions which should be public can be changed individually.


git-svn-id: svn://10.0.0.236/trunk@103226 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-19 21:47:23 +00:00
mcgreer%netscape.com
2c10ed3f44 use the list to collect certs
git-svn-id: svn://10.0.0.236/trunk@103225 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-19 21:37:21 +00:00
scc%mozilla.org
327cf7a65a bug #98089: ripped new license
git-svn-id: svn://10.0.0.236/trunk@103222 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-19 20:40:05 +00:00
mcgreer%netscape.com
24b949d0b3 initial checkin of threadsafe list
git-svn-id: svn://10.0.0.236/trunk@103221 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-19 20:20:06 +00:00
scc%mozilla.org
52c8d09e03 bug #98089: ripped new license
git-svn-id: svn://10.0.0.236/trunk@103219 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-19 20:09:47 +00:00
mcgreer%netscape.com
bf22305f42 first cut at password handling. todo: implement transaction-based passwords (at a higher level?)
git-svn-id: svn://10.0.0.236/trunk@103213 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-19 19:08:32 +00:00
ian%hixie.ch
a6aab56db7 The first ContactMethod, namely Email.
git-svn-id: svn://10.0.0.236/trunk@103212 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-19 18:56:05 +00:00
scc%mozilla.org
7721a318d8 bug #98089: ripped new license
git-svn-id: svn://10.0.0.236/trunk@103211 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-19 18:55:32 +00:00
ian%hixie.ch
8458307437 Added a hook for installing new user fields so that setupInstall handlers don't have to go through the same process multiple times. Also corrected an obvious error (using a variable after checking that it couldn't be used...).
git-svn-id: svn://10.0.0.236/trunk@103208 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-19 18:43:06 +00:00
ian%hixie.ch
6e6fd80d50 Correcting the misspelling of the package names ('Components' not 'Component') to match the directory.
git-svn-id: svn://10.0.0.236/trunk@103207 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-19 18:29:39 +00:00
ian%hixie.ch
09011bc7ce Corrected the order of return values (newPassword) and removed the extraneous argument (output).
git-svn-id: svn://10.0.0.236/trunk@103206 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-19 18:11:03 +00:00
ian%hixie.ch
f841c45515 Cached the SMTP object to improve performance.
git-svn-id: svn://10.0.0.236/trunk@103205 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-19 18:05:28 +00:00
ian%hixie.ch
e857b66e93 Made the outputter be a simple service rather than a service instance to improve performance.
git-svn-id: svn://10.0.0.236/trunk@103204 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-19 18:01:23 +00:00
ian%hixie.ch
9c2608c334 Corrected an oversight in the service instance creation code: if a service acts as both a service instance and a normal service, it needs a special constructor to force the creation of the instance, otherwise if the service is created first it will be used again for the instances.
git-svn-id: svn://10.0.0.236/trunk@103203 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-19 17:56:15 +00:00
nboyd%atg.com
aa2c5f6644 Patch from Igor:
Currently Rhino source has quite a few places with code like (String)node.getDatum()
 or ((Number)node.getDatum()).doubleValue(). The patch changes this usage to call
node.getString() or node.getDouble().

It also adds new constructors to Node to accept int or double values in addition to
Object datum to replace new Node(token, new Integer(x)) by Node(token, x) etc. It
may allow in future not to create a wrapper object for int or double datum to speed
up parsing.


git-svn-id: svn://10.0.0.236/trunk@103201 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-19 17:01:46 +00:00
jake%acutex.net
6b6097c59e Fix for bug 97971 - Sanity check should check statuses, resolutions, everconfirmed & number of votes.
Patch by Matthew Tuck <matty@chariot.net.au>
r= jake@acutex.net


git-svn-id: svn://10.0.0.236/trunk@103198 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-19 15:06:43 +00:00
bzbarsky%mit.edu
75407cbbca Implement the parentRule property of CSS rules. Bug 37470, r=pierre,
sr=jst


git-svn-id: svn://10.0.0.236/trunk@103197 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-19 14:16:34 +00:00
mkaply%us.ibm.com
c2fa199fd5 No bug
r=mkaply, sr=blizzard
Code from aaronr - continuing to try to fix focus/etc. issues related to XWorkplace/XCenter
Man I with Mozilla had picked a focus model that wasn't so similar to Windows


git-svn-id: svn://10.0.0.236/trunk@103196 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-19 14:01:02 +00:00
rods%netscape.com
ce9c399a8e Make the default "submit"
Bug 59035 r=kmcclusk sr=attinasi


git-svn-id: svn://10.0.0.236/trunk@103195 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-19 13:00:23 +00:00
rods%netscape.com
399b9183c4 Make the default for "submit"
Bug 59035 r=kmcclusk sr=attinasi


git-svn-id: svn://10.0.0.236/trunk@103194 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-19 12:58:41 +00:00
karnaze%netscape.com
1540a4c12e bug 68998 - added extra param to Paint, PaintChild, PaintChildren used by tables in standard mode. sr=waterson, r=alexsavulov.
git-svn-id: svn://10.0.0.236/trunk@103193 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-19 12:35:19 +00:00
leaf%mozilla.org
7a358b4a58 Automated update
git-svn-id: svn://10.0.0.236/trunk@103192 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-19 10:28:33 +00:00
cls%seawood.org
ee20fa4afb Remove extraneous spaces from variable assignment.
Thanks to Masaki Katakai <katakai@japan.sun.com> for the patch.
Bug #100275 r=cls


git-svn-id: svn://10.0.0.236/trunk@103191 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-19 10:23:32 +00:00
cls%seawood.org
42546073fd Initial version of libxpcomglue win32 makefile. not part of build (yet)
Bug #99698


git-svn-id: svn://10.0.0.236/trunk@103190 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-19 08:09:04 +00:00
racham%netscape.com
4e0d493a22 Fixing bug 100404. Backing out changes made to to accountwizard to reflect the current xpcom component. Bug 100483 will be used to bring back these changes.
git-svn-id: svn://10.0.0.236/trunk@103189 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-19 07:47:59 +00:00
racham%netscape.com
22ccbd0fe7 Fixing bug 100404. Backing out changes made to xpcom that caused dependency on chrome component. AccountManager in mailnews need to be fixed as explained in bug 100483 to solve the problem in a better way.
git-svn-id: svn://10.0.0.236/trunk@103188 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-19 07:43:41 +00:00
jst%netscape.com
9ba2e4188b Fixing bug 100270. Crash when evaluating 'window.close();' in the JavaScript console. r=waterson@netscape.com, sr=hyatt@netscape.com
git-svn-id: svn://10.0.0.236/trunk@103187 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-19 07:08:15 +00:00
jband%netscape.com
09fde32fce fix bug 100260. xpconnect should not hold a weak reference to a classinfo object after the xpcwrappednativeproto that was holding a strong ref is destroyed. sr=jst, r=dbradley,markh.
git-svn-id: svn://10.0.0.236/trunk@103184 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-19 06:22:17 +00:00
bstell%netscape.com
3b48d0d55d ports bustage fix for bug 95518
git-svn-id: svn://10.0.0.236/trunk@103183 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-19 06:03:47 +00:00
cls%seawood.org
6b39ce4b3d Compilers handle local declarations of 'int i' inside a for-loop differently so just declare it once at the top of the function.
git-svn-id: svn://10.0.0.236/trunk@103180 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-19 04:23:48 +00:00
cls%seawood.org
ebb6c99cbb Update REQUIRES list with added depedency upon uconv introduced by checkin for bug 95518. Fixing myotonic bustage
git-svn-id: svn://10.0.0.236/trunk@103179 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-19 04:22:21 +00:00
cls%seawood.org
57344bcda1 Declare REQUIRES list for activex control. Should fix archangel bustage
git-svn-id: svn://10.0.0.236/trunk@103178 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-19 04:06:01 +00:00
edburns%acm.org
8d3d442afd bug=98107
r=peterl
sr=rpotts

/* According to the HTML 4.01 spec, at
                       * http://www.w3.org/TR/html4/types.html#type-cdata
                       * ''User agents may ignore leading and trailing
                       * white space in CDATA attribute values (e.g., "
                       * myval " may be interpreted as "myval"). Authors
                       * should not declare attribute values with
                       * leading or trailing white space.''
                       */


git-svn-id: svn://10.0.0.236/trunk@103177 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-19 03:34:17 +00:00
ducarroz%netscape.com
05bc542a07 Fix for bug 96386. When a generic or unknown error occures while posting a message, we should report a post error instead of a send error. Also, the send unsent message listener should not display errors. Finally, the Display Send Report function should avoid displaying twice the same string. R=varada, sr=mscott
git-svn-id: svn://10.0.0.236/trunk@103176 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-19 03:28:23 +00:00
bstell%netscape.com
ff63715851 bug 95518, r=yokoyama@netscape.com,r=Roland.Mainz@informatik.med.uni-giessen.de,
sr=brendan@mozilla.org,

Compress font char maps by folding the empty spaces on top of each other.


git-svn-id: svn://10.0.0.236/trunk@103175 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-19 03:01:54 +00:00
cls%seawood.org
40d220fe45 Create the BApplication on a seperate thread like apprunner does.
Call the native viewer app's shutdown function on SIGTERM instead of forcefully quitting the app.
Bug #99564 sr=alecf


git-svn-id: svn://10.0.0.236/trunk@103174 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-19 02:52:50 +00:00
bstell%netscape.com
4614cc2f7d bug 95518, r=yokoyama@netscape.com,r=Roland.Mainz@informatik.med.uni-giessen.de,
sr=brendan@mozilla.org,

Compress font char maps by folding the empty spaces on top of each other.


git-svn-id: svn://10.0.0.236/trunk@103173 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-19 02:52:30 +00:00
cls%seawood.org
1cc8dafd1a Change beos sighandler to get the nsAppShellService and call its shutdown function on SIGTERM rather than forcefully quitting the app.
Bug #99564 sr=alecf


git-svn-id: svn://10.0.0.236/trunk@103172 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-19 02:51:32 +00:00
bstell%netscape.com
682aa91ee3 bug 95518, r=yokoyama@netscape.com,r=Roland.Mainz@informatik.med.uni-giessen.de,
sr=brendan@mozilla.org,

Define the size of a PRUint32 char map, aka: 8K char map


git-svn-id: svn://10.0.0.236/trunk@103171 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-19 02:49:05 +00:00
hyatt%netscape.com
8b83395577 Fix for 99198, ensure that stack doesn't stretch children explicitly position at left/top of (0,0), r=bryner, sr=waterson
git-svn-id: svn://10.0.0.236/trunk@103170 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-19 02:05:57 +00:00
hyatt%netscape.com
57db03f42a Fix for 99476, setting the pack attribute on boxes should cause a reflow. r=bryner, sr=waterson
git-svn-id: svn://10.0.0.236/trunk@103169 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-19 01:56:03 +00:00
hyatt%netscape.com
01431ff45e Fix for 49874 and 98109, make iframes build their docshells and kick off their content load from frame construction, also enabling the primary content area to be dynamically shiftable. r=jag, sr=waterson
git-svn-id: svn://10.0.0.236/trunk@103168 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-19 01:53:00 +00:00
dp%netscape.com
adddab947a bug 88844 Fixing turbo mode initialization on launch preventing xpcom double initialization. Merging branch to tip
git-svn-id: svn://10.0.0.236/trunk@103167 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-19 01:51:15 +00:00
cmanske%netscape.com
d9fb860dec Enable 'None' item in Format | List submenu, b=96510, r=brade, sr=kin
git-svn-id: svn://10.0.0.236/trunk@103164 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-19 00:44:12 +00:00
gerv%gerv.net
df75c81fea Plugins dir environment variable was misnamed. Renamed it to MOZ_PLUGIN_PATH. Bug 99846. r=av, sr=blake.
git-svn-id: svn://10.0.0.236/trunk@103162 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-19 00:37:36 +00:00
cls%seawood.org
d0abe23458 Declaring win32 dependencies for smimestub.
Bug #98371 sr=alecf


git-svn-id: svn://10.0.0.236/trunk@103161 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-19 00:30:46 +00:00
cmanske%netscape.com
d2a90f73f4 Fixed disabling of menulist in Insert Character dialog; Fix by jrgm: b=96703, r=cmanske, sr=kin
git-svn-id: svn://10.0.0.236/trunk@103160 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-19 00:26:00 +00:00
markh%activestate.com
f466bcdf46 Cache nsIClassInfos for all Python classes. This works around a bug in
XPConnect that is soon to be fixed, but also allows us to take advantage
of the XPConnect caching, and to save rebuilding the same class info for
short-lived objects created repeatedly.

Not part of the build.


git-svn-id: svn://10.0.0.236/trunk@103159 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-19 00:25:31 +00:00
tao%netscape.com
59c07e460b 95944: XPI packages not working on Linux 0.9.3. (r=ssu,sr=dveditz).
failover to profile directory when the global location isn't writable.


git-svn-id: svn://10.0.0.236/trunk@103158 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-19 00:21:21 +00:00
markh%activestate.com
168e47aee3 Remove bad tests for Unicode - we only support strings as contract IDs.
git-svn-id: svn://10.0.0.236/trunk@103157 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-19 00:20:50 +00:00
markh%activestate.com
9b20c7465f Add weak-reference test output to the expected test output.
git-svn-id: svn://10.0.0.236/trunk@103156 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-19 00:20:04 +00:00
sspitzer%netscape.com
d1576f4b41 fix for some news problems we've been having. #95320 and #59449.
in the case where the socket gets closed we need to remove it from the
connection cache.  more work needs to be done to properly clean up
the protocol instance and to fix some related issues, but this helps
the end user.  r=bienvenu, sr=sspitzer.  thanks to Phil Anderton
for the patch.


git-svn-id: svn://10.0.0.236/trunk@103155 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-19 00:19:43 +00:00
cls%seawood.org
b065cf0ab3 Updating xpinstall dependencies.
Bug #98371 sr=alecf


git-svn-id: svn://10.0.0.236/trunk@103154 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-19 00:14:33 +00:00
cls%seawood.org
75129830d7 Updating accessibility dependencies.
Bug #98371 sr=alecf


git-svn-id: svn://10.0.0.236/trunk@103153 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-19 00:11:41 +00:00
cls%seawood.org
7e0d10215d Updating profile acct dependencies.
Bug #98371 sr=alecf


git-svn-id: svn://10.0.0.236/trunk@103151 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-19 00:08:30 +00:00
blakeross%telocity.com
48a4d4ca4b editable menulists use wrong text size/font (96946). r/sr=ben
git-svn-id: svn://10.0.0.236/trunk@103150 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-19 00:06:39 +00:00
cls%seawood.org
cd40cb959c Updating xmlextras deps.
Bug #98371 sr=alecf


git-svn-id: svn://10.0.0.236/trunk@103149 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-19 00:03:53 +00:00
srilatha%netscape.com
3e93df812f Fix for bug #95122. sr=sspitzer
Missed this change in the previous checkin. SO rechecking in this file


git-svn-id: svn://10.0.0.236/trunk@103147 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-19 00:02:51 +00:00
cls%seawood.org
eda06e15a6 Updating security/ REQUIRES.
Bug #98371 moa=kaie r=bryner sr=alecf


git-svn-id: svn://10.0.0.236/trunk@103146 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-19 00:01:47 +00:00
harishd%netscape.com
cecf1d33ee 98187 - Make sure that the end tag, inline element, does not close tags in the root tag list. r=heikki,sr-vidur
git-svn-id: svn://10.0.0.236/trunk@103145 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-19 00:01:42 +00:00
cls%seawood.org
f8ac63ed7e Updating accessibility dependencies.
Bug #98371 sr=alecf


git-svn-id: svn://10.0.0.236/trunk@103142 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-18 23:48:03 +00:00
cls%seawood.org
6a55e06ff2 Add accessibility dependencies.
Bug #98371 sr=alecf


git-svn-id: svn://10.0.0.236/trunk@103131 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-18 23:36:42 +00:00
kin%netscape.com
237a94d4ee Patch submitted by neil@parkwaycc.co.uk
Fix for bug #80239: javascript strict warnings in editor.js

Simplify methods that check for existence of
spellchecker and find components, by checking
if they exist in Components.classes.

r=cmanske@netscape.com   sr=kin@netscape.com


git-svn-id: svn://10.0.0.236/trunk@103130 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-18 23:35:19 +00:00
bienvenu%netscape.com
a33d2c43de fix regression in downloading messages for offline use and disabling commands when local message is loaded while offline r=naving, sr=sspitzer 99696 100124
git-svn-id: svn://10.0.0.236/trunk@103128 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-18 23:27:20 +00:00
cls%seawood.org
fb7750bb00 Delete the semaphore used to sync timer callbacks when shutting down the appshell. This should prevent the timer thread from hanging on exit.
Bug #99564 sr=alecf


git-svn-id: svn://10.0.0.236/trunk@103126 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-18 23:25:30 +00:00
mcafee%netscape.com
b20fa51f21 Adding branch page
git-svn-id: svn://10.0.0.236/trunk@103125 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-18 23:24:28 +00:00
darin%netscape.com
d9914fb477 fixes bug 99183 "JAR channel allocates and uses a monitor even though it is
accessed exclusively by the UI thread" r=dougt, sr=mscott


git-svn-id: svn://10.0.0.236/trunk@103124 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-18 23:07:57 +00:00
bryner%netscape.com
43546bcee2 Bug 64052 - don't allow chrome documents to take focus via tabbing. r=saari, sr=hyatt.
git-svn-id: svn://10.0.0.236/trunk@103123 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-18 23:07:44 +00:00
rogerl%netscape.com
a01fa23e32 Fix bug #98306, ParseAtom crash for "/[/]/" r=jst, r/sr=be.
git-svn-id: svn://10.0.0.236/trunk@103121 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-18 22:36:14 +00:00
srilatha%netscape.com
97f215fbe3 Fix for bug #95122. sr=sspitzer
Cleaning up the contents.rdf and fixing the js error


git-svn-id: svn://10.0.0.236/trunk@103120 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-18 22:26:16 +00:00
colin%theblakes.com
22e6baf645 Use a different URL for the plugin page for OpenVMS.
b=99114 r=av@netscape.com sr=brendan@mozilla.org


git-svn-id: svn://10.0.0.236/trunk@103119 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-18 22:23:14 +00:00
mitesh%netscape.com
f9c9f59b2d Fix for bug 80789 Changing hashing algorithm for netscape.cfg
r=bnesse and sr=alecf
checking in for chipc@netscape.com


git-svn-id: svn://10.0.0.236/trunk@103118 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-18 22:05:57 +00:00
alecf%netscape.com
16f11bc1ec fix for bug 100310 r=jag, sr=blizzard - remove gfx dependency on string bundles, move into windows-specific module
git-svn-id: svn://10.0.0.236/trunk@103117 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-18 22:02:30 +00:00
jaggernaut%netscape.com
8a87c13848 One module per line for REQUIRES. r=/sr=alecf
git-svn-id: svn://10.0.0.236/trunk@103116 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-18 22:01:13 +00:00
jaggernaut%netscape.com
fdac6a026c Bug 89784: ``xlib 0.9.2 will not display to m64(8+24bit)/Expert3D/Creator3D framebuffers because of visuals/depths'', author=Roland Mainz <Roland.Mainz@informatik.med.uni-giessen.de>, r=Caspian Maclean <caspian.maclean@tuxia.com>, sr=jst
git-svn-id: svn://10.0.0.236/trunk@103115 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-18 22:01:04 +00:00
oeschger%netscape.com
deb6947294 just changing id of help window to match the new sys tray icon on the ns side, bug=96140, r=andreww, sr=hewitt, pdt says in on trunk
git-svn-id: svn://10.0.0.236/trunk@103114 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-18 21:56:54 +00:00
jaggernaut%netscape.com
9233ab9978 One module per line for REQUIRES. r=/sr=alecf
git-svn-id: svn://10.0.0.236/trunk@103113 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-18 21:52:15 +00:00
mitesh%netscape.com
5c8558a3a9 Fix for bug 99515 - AutoConfig hangs during Profile Migration
r=danm and sr=alecf


git-svn-id: svn://10.0.0.236/trunk@103112 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-18 21:52:01 +00:00
jaggernaut%netscape.com
5415c5da69 Bug 99876: [XUL Syntax] <spring/> --> <spacer/>, r=alecf, sr=hyatt.
git-svn-id: svn://10.0.0.236/trunk@103111 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-18 21:47:32 +00:00
blizzard%redhat.com
643618026a Fix bug #80051. Attach the user running the mozilla process to the x remote windows so that another user running mozilla can run another copy of the process tothe same display. r/sr=alecf,shaver
git-svn-id: svn://10.0.0.236/trunk@103110 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-18 21:45:43 +00:00
jband%netscape.com
59b8e22a73 unbust XPCOM_STANDALONE. bug 66759. These days xpcom relies on nsIChromeRegistry.h too. Gak! r=dougt sr=brendan.
git-svn-id: svn://10.0.0.236/trunk@103109 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-18 21:43:46 +00:00
pinkerton%netscape.com
bc0203a4f4 work around bugs in CarbonLib's ::MenuSelect() with submenus. r=saari/sr=sfraser. bug#83639
git-svn-id: svn://10.0.0.236/trunk@103108 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-18 21:43:45 +00:00
chak%netscape.com
181d4f9c48 Fix for #99144 - Marking nsIFactory as frozen
r=dougt, sr=rpotts


git-svn-id: svn://10.0.0.236/trunk@103107 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-18 21:40:42 +00:00
mcgreer%netscape.com
3fe2b80569 cleanup; match changes to dev/; update doc
git-svn-id: svn://10.0.0.236/trunk@103105 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-18 20:55:01 +00:00
mcgreer%netscape.com
bfe5a4a03b cleanup; add nssSession type to allow multiple sessions accessing the token API
git-svn-id: svn://10.0.0.236/trunk@103104 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-18 20:54:28 +00:00
alecf%netscape.com
a9e58e7c85 fix blocker 100312 - fix the XPIDL_MODULE lines so they aren't all content_xul
r=jag


git-svn-id: svn://10.0.0.236/trunk@103101 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-18 18:21:58 +00:00
jaggernaut%netscape.com
ae3ddf1d13 Clean up some of the die messages, only look for srcdirs which have "mozilla" or "ns" in them (shortcut around fancy Makefile parsing), emit one module per line.
git-svn-id: svn://10.0.0.236/trunk@103096 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-18 16:08:37 +00:00
jaggernaut%netscape.com
8b71ae9c91 Bug 73353: splitting the modules on the REQUIRES lines in Makefile.in across multiple lines to more clearly show the changes made. sr=alecf
git-svn-id: svn://10.0.0.236/trunk@103093 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-18 13:41:47 +00:00
jdunn%netscape.com
9e96eff17d now fixing nebiros bustage, apparently my previous fix wasn't
liked by it.
so what I did was remove 2 instances of "for (int i = <blah>"
and replaced it with "int i;  <blah> for (i = <blah>"


git-svn-id: svn://10.0.0.236/trunk@103092 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-18 13:13:16 +00:00
cls%seawood.org
338e52b058 Updating module dependencies list
git-svn-id: svn://10.0.0.236/trunk@103091 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-18 12:56:49 +00:00
nboyd%atg.com
dd74cb10b1 Patch from Igor:
Currently in the interpreter mode all number literals are stored in
InterpreterData.itsICode as an index to InterpreterData.itsNumberTable
which holds the actual value.

For integers that fit 2 or 4 bytes this is an overkill and the attached
patch stores integers in InterpreterData.itsICode inline after special
TokenStream.INTNUMBER or TokenStream.SHORTNUMBERS tokens.

The changes made benchmarks to run 1.5% faster. It also saves memory
because InterpreterData.itsNumberTable is allocated only for non-integers
that present only in a small number of scripts.

In principle, it may be possible to store all numbers inline as well, but
unfortunately re-assembling of 8 bytes from InterpreterData.itsICode array
into double is rather slow operation and is not worth the hassles.

Regards, Igor


git-svn-id: svn://10.0.0.236/trunk@103090 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-18 12:27:23 +00:00
nboyd%atg.com
52fd793a66 Patch from Igor:
Hi, Norris!

Currently ScriptableObject.put does not check lastAccess cache during its search for
slots. When I added this check (see the attached patch) it speeded up the benchmark
suite by about 1.5% and in particular for setProp_bench.js the win was about 8%.

I think that even on multiprocessor machines it would not introduces any additional
issues  like accessing the old value in the processor cache because the put method
accesses existing properties via unsynchronized getSlot, and the check for lastAccess
is on pair with that.

Trgards, Igor


git-svn-id: svn://10.0.0.236/trunk@103089 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-18 12:26:10 +00:00
nboyd%atg.com
e838eaede0 Fix for problem from Felix Meschberger:
When handling an Exception the Context tries to get the current script
and line number from the Java Stacktrace. To get the indication of which
entry in the trace might be an ECMA script, the file extension ".js" is
assumed.

For our integration we use the standard extension ".ecma" which collides
with the above assumption. But we don't force this extension, we just
have a convention. We name these files ".ecma" as they are not plain
ECMA but JSP-like ECMA. That is instead of using Java as the programming
language we use ECMA. In this respect they would be ".esp".


git-svn-id: svn://10.0.0.236/trunk@103088 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-18 12:24:56 +00:00
jdunn%netscape.com
ce1a8e406f fixing katakai's bustage on cement and myotonic
git-svn-id: svn://10.0.0.236/trunk@103087 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-18 11:54:38 +00:00
katakai%japan.sun.com
1496fa7bc3 bug 84380 Need a component that generates thai presentation forms
Updates for *extensions*/ctl for prabhat@Sun, r=ftank for check-in
A Incorporate frank's review fixes (08/07)
B Bugfix in TIS620Encoder
C Fix memory corruption
D Makefile changes in pangoLite directory to install pango.modules


git-svn-id: svn://10.0.0.236/trunk@103086 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-18 10:14:38 +00:00
stephend%netscape.com
d9fd93b244 Bug 10020. JS function verifyAccounts() should be verifyAccount(null) to reflect parameter passing. r=bhuvan@netscape.com, sr=sspitzer@netscape.com
git-svn-id: svn://10.0.0.236/trunk@103083 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-18 06:56:08 +00:00
srilatha%netscape.com
0359e77c4b Fix for bug # 95122. Implementation of UI for simple MAPI
r=rdayal, sr=sspitzer


git-svn-id: svn://10.0.0.236/trunk@103082 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-18 06:10:34 +00:00
alecf%netscape.com
d2145a5ad8 add some comments, clean up the generated graphs, etc
git-svn-id: svn://10.0.0.236/trunk@103080 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-18 05:46:45 +00:00
jst%netscape.com
363f1c313a Fix bug 99690. Fix crash when external apps try to open mozilla windows. r=bzbarsky@mit.edu, sr=blakeross@telocity.com
git-svn-id: svn://10.0.0.236/trunk@103079 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-18 05:32:03 +00:00
dougt%netscape.com
ba5ece1168 Adds Double PASV support. r=gagan, sr=darin b92582
git-svn-id: svn://10.0.0.236/trunk@103078 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-18 05:21:18 +00:00
bzbarsky%mit.edu
55cffed35d Fix topcrash bug 99057 (crash @
GetExtensionsAndDescriptionFromMimetypesFile). r=dbaron, sr=scc


git-svn-id: svn://10.0.0.236/trunk@103074 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-18 03:53:25 +00:00
jst%netscape.com
e41f11fa43 Fixing bug 81928. JS errors in XUL files were not always reported. sr=brendan@mozilla.org, r=jband@netscape.com
git-svn-id: svn://10.0.0.236/trunk@103072 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-18 03:32:03 +00:00
loadrunner%betak.net
f6d9a26100 bug 99253, Optimization on sort in pref-languages.js, patch by jrgm, r=jbetak, sr=blizzard, alecf
git-svn-id: svn://10.0.0.236/trunk@103069 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-18 03:12:03 +00:00
saari%netscape.com
570c005a78 adding files to IDL projects for aaronl. Accessiblity stuff, bug 82207
git-svn-id: svn://10.0.0.236/trunk@103068 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-18 03:09:19 +00:00
aaronl%netscape.com
6c18128152 Bug 82207. Beginning XUL MSAA support (checkboxes). r=jgaunt, sr=hyatt
git-svn-id: svn://10.0.0.236/trunk@103067 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-18 03:09:01 +00:00
bryner%netscape.com
0e84091532 Bug 99192 - don't tab into popups. r=jag, sr=hyatt.
git-svn-id: svn://10.0.0.236/trunk@103064 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-18 02:25:07 +00:00
peterlubczynski%netscape.com
6816be05a4 Fix for full-page plugin printing bug 53349 r=av sr=attinasi
git-svn-id: svn://10.0.0.236/trunk@103062 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-18 02:16:52 +00:00
peterlubczynski%netscape.com
e88c276837 Implement plugin printing bug 27478 r=av,beard sr=attinasi
git-svn-id: svn://10.0.0.236/trunk@103060 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-18 02:11:09 +00:00
nelsonb%netscape.com
838aefdfe7 Use new function SSL_GetChannelInfo(). Bugzilla bug 78959.
Also, reduce size of SSL server session cache on disk.


git-svn-id: svn://10.0.0.236/trunk@103059 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-18 02:05:08 +00:00
nelsonb%netscape.com
65c1d8ebc2 Use new function SSL_GetChannelInfo(). Bugzilla bug 78959.
git-svn-id: svn://10.0.0.236/trunk@103058 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-18 02:02:05 +00:00
nelsonb%netscape.com
c38ee88985 Implement new function SSL_GetChannelInfo(). Bugzilla bug 78959.
git-svn-id: svn://10.0.0.236/trunk@103057 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-18 01:59:21 +00:00
rangansen%netscape.com
1fcb4bc2c8 r=ddrinan sr=kin@netscape.com
bug# 99719; patch to regression on dialog window


git-svn-id: svn://10.0.0.236/trunk@103056 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-18 01:50:28 +00:00
brendan%mozilla.org
c5ed6660bd Use the maximum of fp->argc and fp->fun->nargs to bound fp->argv (97921, sr=jband&shaver).
git-svn-id: svn://10.0.0.236/trunk@103055 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-18 01:47:41 +00:00
sfraser%netscape.com
ad1923a9ba Fix bug 86694 -- image tiling slow on Mac. Implement repeated scaling into a temporary GWorld before final blit. sr=scc, r=pavlov.
git-svn-id: svn://10.0.0.236/trunk@103054 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-18 01:39:04 +00:00
naving%netscape.com
8612278b5d 99168; r/sr=mscott fix nsMsgMailNewsUrl leak on reading imap messages
git-svn-id: svn://10.0.0.236/trunk@103052 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-18 00:50:56 +00:00
ddrinan%netscape.com
fb8158f193 Fix build bustage for rpotts. Removed GetProtocolHandler() method
git-svn-id: svn://10.0.0.236/trunk@103048 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-18 00:20:16 +00:00
dbaron%fas.harvard.edu
f25532bcbf Allow declarations in style attribute to be surrounded by braces in quirks mode. Rename ParseDeclarations to ParseStyleAttribute since that's what it does. b=99554 r=hixie,glazman sr=attinasi
git-svn-id: svn://10.0.0.236/trunk@103044 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-17 23:59:30 +00:00
dbaron%fas.harvard.edu
7bdb46f971 Make fixed positioning code check for NS_AUTOOFFSET to fix positioning of auto-sized fixed positioned elements relative to bottom or right. b=98579 r=waterson sr=attinasi
git-svn-id: svn://10.0.0.236/trunk@103043 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-17 23:55:58 +00:00
pschwartau%netscape.com
9017fd7bcd Forgot to remove these comment-marks.
git-svn-id: svn://10.0.0.236/trunk@103042 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-17 23:55:06 +00:00
pschwartau%netscape.com
05556de073 Skip regression test for bug 100199 until the bug is fixed.
git-svn-id: svn://10.0.0.236/trunk@103041 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-17 23:53:12 +00:00
sspitzer%netscape.com
0d3dfb1778 fix for #99491. persist mailnews sidebar height by persisting the outliner height.
r=varada, sr=mscott


git-svn-id: svn://10.0.0.236/trunk@103040 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-17 23:51:07 +00:00
pschwartau%netscape.com
2041d901f7 Initial add. Regression test for bug 100199.
git-svn-id: svn://10.0.0.236/trunk@103039 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-17 23:49:25 +00:00
sdagley%netscape.com
cf37c81c53 Fix #99556. Account for change in Mac epoch time as of MSL 6. r=wtc/sfraser
git-svn-id: svn://10.0.0.236/trunk@103038 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-17 23:42:12 +00:00
hewitt%netscape.com
12bda0148b 99102 - update skin versions in all contents.rdf, r=hyatt, sr=blake
git-svn-id: svn://10.0.0.236/trunk@103036 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-17 23:40:50 +00:00
leif%netscape.com
fb1a4be4c0 Fix for bug 82412: Preresolve DNS before calling into LDAP C-SDk. SR=bienvenu@netscape.com, r=dmose@netscape.com, patch=leif@netscape.com.
git-svn-id: svn://10.0.0.236/trunk@103035 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-17 23:35:03 +00:00
naving%netscape.com
8e096d7cb3 99150 r/sr=sspitzer. Make minor changes to return value and freeing memory.
git-svn-id: svn://10.0.0.236/trunk@103034 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-17 23:31:28 +00:00
rpotts%netscape.com
c61968e3c4 bug #70223 (r=valeski@netscape.com, sr=mscott@netscape.com). Remove nsIURIContentListener::GetProtocol() since it is unused.
git-svn-id: svn://10.0.0.236/trunk@103032 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-17 23:22:00 +00:00
attinasi%netscape.com
602857076b Fixing erroneous addition to previously reviewed and approved patch: b=97619 r=bernd sr=waterson
git-svn-id: svn://10.0.0.236/trunk@103028 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-17 23:14:43 +00:00
stephend%netscape.com
27f62a5e0c Bug 91751. In the Search window of mail/news, 'Search' should appear the default button. Patch by Bradley Hart <bhart00@yahoo.com> r=hwaara@chello.se/jglick@netscape.com, sr=sspitzer@netscape.com
git-svn-id: svn://10.0.0.236/trunk@103026 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-17 23:05:58 +00:00
sicking%bigfoot.com
b44d102f77 Make the XPath engine handle CDATA sections as text-nodes.
b=92786 r=peterv, pike sr=jst

Mixed small fixes and comments.
b=99792 r=peterv sr=jst


git-svn-id: svn://10.0.0.236/trunk@103025 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-17 23:02:57 +00:00
jst%netscape.com
1d23a9848c Duh! (typo in the fix for bug 95840).
git-svn-id: svn://10.0.0.236/trunk@103023 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-17 22:58:06 +00:00
mcgreer%netscape.com
eee6e64a55 add suggestion about new NSSSession type; crypto context question
git-svn-id: svn://10.0.0.236/trunk@103020 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-17 22:14:55 +00:00
aaronl%netscape.com
e0b865c6d4 Part of checkin for 82207 (XUL MSAA support). Fixing accidentally lowercased names. r=jgaunt, sr=hyatt
git-svn-id: svn://10.0.0.236/trunk@103019 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-17 21:51:20 +00:00
naving%netscape.com
7fd837278b 99473 r/sr=mscott. fix a specific pop3 message downloading problems on linux.
git-svn-id: svn://10.0.0.236/trunk@103018 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-17 21:50:26 +00:00
wtc%netscape.com
a283fa5a06 lla bug 98371: specify the NSPR and DBM include directories using
MOZILLA_INCLUDES instead of SOURCE_MDHEADERS_DIR.


git-svn-id: svn://10.0.0.236/trunk@103017 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-17 20:55:25 +00:00
gordon%netscape.com
38ed8264eb Fix bug 97620 [r=rpotts, sr=brendan/ben] Added code to doom and clear
active cache entries when devices are shutdown.

Fix bug 88768 [a=nisheeth], fixing unary operator usage in nsCacheEntryDescriptor.cpp.


git-svn-id: svn://10.0.0.236/trunk@103015 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-17 20:47:09 +00:00
stephend%netscape.com
e437e5da57 Bug 99245. Using strtok is evil. Patch by Ulrich Drepper <drepper@cygnus.com> r=bnesse@netscape.com, sr=alecf@netscape.com
git-svn-id: svn://10.0.0.236/trunk@103014 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-17 20:39:31 +00:00
jaggernaut%netscape.com
cf70e0c265 Bug 79889: download progress dialog not wide enough. r=hewitt, sr=hyatt
git-svn-id: svn://10.0.0.236/trunk@103008 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-17 20:28:38 +00:00
hyatt%netscape.com
1a60797acb Fix for 96899, unable to see addresswes when scrolling up in mailcompose. r=mscott, sr=brendan
git-svn-id: svn://10.0.0.236/trunk@103007 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-17 20:24:30 +00:00
heikki%netscape.com
cc689d7c32 Bug 100106, XMLHttpRequest.responseText empty if XML parsing error. r=harishd, sr=vidur.
git-svn-id: svn://10.0.0.236/trunk@103006 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-17 20:22:16 +00:00
cmanske%netscape.com
a2feafea50 New strings for UI part of relative URL support, b=72583, r=brade, sr=kin
git-svn-id: svn://10.0.0.236/trunk@103004 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-17 19:33:53 +00:00
cmanske%netscape.com
8667c2b02f Added support to use relative URLs in link and image dialogs and let user convert to/from absolute URLs, b=72583, r=brade,akkana, sr=kin
git-svn-id: svn://10.0.0.236/trunk@103003 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-17 19:31:19 +00:00
alecf%netscape.com
6f4b44bcf4 additional changes per cls for bug 98371 (REQUIRES support on Win32)
git-svn-id: svn://10.0.0.236/trunk@103000 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-17 19:14:31 +00:00
alecf%netscape.com
e28607491e Final REQUIRES changes for bug 98371, adding support for MOZ_TRACK_MODULE_DEPS to win32. r=cls (and tested by cls!)
git-svn-id: svn://10.0.0.236/trunk@102999 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-17 19:06:35 +00:00
sspitzer%netscape.com
49518c84e4 fix for trivial bug #100128. ("account ." should be "account.") rs=bienvenu
git-svn-id: svn://10.0.0.236/trunk@102998 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-17 19:05:59 +00:00
stephend%netscape.com
31b501f801 Bug 99984. JavaScript strict warning in am-prefs.js r=dmose@netscape.com, sr=mscott@netscape.com
git-svn-id: svn://10.0.0.236/trunk@102997 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-17 18:59:42 +00:00
rginda%netscape.com
0b2e733162 patch from Pavel Hlavnicka pavel@gingerall.cz
fix ordering of user footer and menu


git-svn-id: svn://10.0.0.236/trunk@102996 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-17 18:58:14 +00:00
stephend%netscape.com
3c271c4e33 Bug 98381. Align and change the wording of the Subscribe dialog's label. Patch by Bradley Hart <bhart00@yahoo.com> r=stephend@netscape.com/jglick@netscape.com/robinf@netscape.com sr=sspitzer@netscape.com
git-svn-id: svn://10.0.0.236/trunk@102995 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-17 18:58:09 +00:00
myk%mozilla.org
ded048fcee Fix for bug 90333: Bugzilla now displays an appropriate error message if a user hits process_bug.cgi without specifying any bugs to change.
Patch by Myk Melez <myk@mozilla.org>
r=jake@acutex.net


git-svn-id: svn://10.0.0.236/trunk@102994 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-17 18:55:31 +00:00
dbaron%fas.harvard.edu
7f671ce2b5 Add all extension properties to nsIDOMNSCSS2Properties, rather than just a few. Clean up nsDOMCSSDeclaration implementation of nsIDOM{,NS}CSS2Properties and implement new attributes in nsIDOMNSCSS2Properties. r=hixie sr=jst b=98500
git-svn-id: svn://10.0.0.236/trunk@102992 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-17 00:57:46 +00:00
ian%hixie.ch
b17b61acb3 Fixed error messages to be more accurate.
git-svn-id: svn://10.0.0.236/trunk@102991 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-17 00:13:16 +00:00
naving%netscape.com
5eeff8faef 98650 r/sr=mscott. Look for only '\n' as endOfLine char. This will fix
the problem of not getting mail from one specific account. At the same time
it should increase performance where ever reading buffer is involved in
mailnews because PL_strstr is changed to PL_strchr.


git-svn-id: svn://10.0.0.236/trunk@102990 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-16 23:55:32 +00:00
gerv%gerv.net
4aac52fcb9 Prevent security dialogs being untitled. Bug 99845. r=timeless. rs=brendan with his magic string-only-changes rubberstamp.
git-svn-id: svn://10.0.0.236/trunk@102989 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-16 23:27:11 +00:00
zach%zachlipton.com
be39f40d3c Fix to make the tests generate the list of files to test instead of having to update the list manually whenever a file is added
or removed. The main logic is in t/Support/Files.pm, changes to the test files are needed to allow it to function properly.

NOT_PART_OF_BUILD. No review needed for tests at this time.


git-svn-id: svn://10.0.0.236/trunk@102988 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-16 18:35:18 +00:00
bernd.mielke%snafu.de
d628a49eda bug 97905, adding a link from block regression tests to table regression tests,
this has already been done for linux. Creating a virtual drive s: if necessary.
r=karnaze not part of the build


git-svn-id: svn://10.0.0.236/trunk@102987 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-16 18:35:07 +00:00
zach%zachlipton.com
c98ca09634 Make this file test for exec calls in addition to system calls that are
one-argument and are therefore insecure.

NOT_PART_OF_BUILD, no review needed.


git-svn-id: svn://10.0.0.236/trunk@102986 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-16 17:52:19 +00:00
jaggernaut%netscape.com
ddbe957f8b Bug 99876: <spring/> --> <spacer/>. r=mozbot
git-svn-id: svn://10.0.0.236/trunk@102985 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-16 14:39:37 +00:00
bryner%netscape.com
b6d3a9eb1c Bug 98041 - xlib port of image tiling assertion fixes. Checking in for Roland.Mainz@informatik.med.uni-giessen.de. r=timeless, sr=jst.
git-svn-id: svn://10.0.0.236/trunk@102984 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-15 21:20:24 +00:00
kmcclusk%netscape.com
0b16a7e103 Protect against null-pointer in nsViewManager::ProcessPendingUpdates. bug 97664 sr=mscott@netscape.com r=peterl@netscape.com
git-svn-id: svn://10.0.0.236/trunk@102983 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-15 17:22:06 +00:00
mkaply%us.ibm.com
20fdde39ca myotonic REQUIRES bustage I think
git-svn-id: svn://10.0.0.236/trunk@102982 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-15 13:00:17 +00:00
racham%netscape.com
aaa50d8405 Fixing bugscape bug 4198. This fix allows ISPs add signature files to the user accounts. If ISP opts for attaching signature file, get the respective file and set the signature.
git-svn-id: svn://10.0.0.236/trunk@102980 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-15 07:57:48 +00:00
racham%netscape.com
af481b9a4d Fixing bugscape bug 4198. This fix allows ISPs add signature files to the user accounts. Adding changes to AppFileLocationProvider to get to messenger defaults.
git-svn-id: svn://10.0.0.236/trunk@102979 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-15 07:53:54 +00:00
myk%mozilla.org
0260babdad Fix for bug 97877: changed* operators now work for attachment statuses on query form.
Fix by Myk Melez <myk@mozilla.org>
r=jake@acutex.net


git-svn-id: svn://10.0.0.236/trunk@102978 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-15 07:26:21 +00:00
bryner%netscape.com
4a248d5162 Bug 89998 - deprecate titledbox in favor of groupbox. This checkin moves the groupbox functionality to groupbox.* instead of titledbox.*. Patch from andersma@luther.edu, r=bryner, sr=hewitt.
git-svn-id: svn://10.0.0.236/trunk@102977 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-15 06:47:08 +00:00
waldemar%netscape.com
565e137cb7 Eliminated unnecessary VC6 workaround
git-svn-id: svn://10.0.0.236/trunk@102976 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-15 05:17:51 +00:00
wtc%netscape.com
ba11393180 Deleted unused prototypes for _PR_Unlock, _PR_SuspendThread, and
_PR_ResumeThread.


git-svn-id: svn://10.0.0.236/trunk@102975 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-15 04:53:12 +00:00
wtc%netscape.com
913d62f0eb Added 'const' to two arrays of constants. Thanks to Simon Fraser for
suggesting this.


git-svn-id: svn://10.0.0.236/trunk@102974 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-15 04:47:14 +00:00
waldemar%netscape.com
0d9075ada0 Fixed error in lexing hexadecimal literals
git-svn-id: svn://10.0.0.236/trunk@102973 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-15 01:52:07 +00:00
darin%netscape.com
9ba42a9da0 fix AIX & OS/2 bustage (second attempt)
git-svn-id: svn://10.0.0.236/trunk@102972 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-15 01:45:27 +00:00
aaronl%netscape.com
d745421739 Bug 82207. Reversing part of change, before redness occurs
git-svn-id: svn://10.0.0.236/trunk@102971 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-15 01:33:24 +00:00
bzbarsky%mit.edu
08e13f7472 Make insertRule() calls on a media rule which initially had no children
not fail.  Bug 98931, r=sicking, sr=jst


git-svn-id: svn://10.0.0.236/trunk@102970 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-15 01:27:49 +00:00
bzbarsky%mit.edu
54ce63514d Make the vertical separator next to the "Home" button not show up when
there are no buttons there.  Bug 80494, patch by Fabian
<hidday@geocities.com>, r=hwaara, sr=ben


git-svn-id: svn://10.0.0.236/trunk@102969 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-15 01:24:16 +00:00
aaronl%netscape.com
31ef3cce70 Part of bug 82207. r=jgaunt, sr=hyatt. XUL Checkbox supporting MSAA
git-svn-id: svn://10.0.0.236/trunk@102965 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-15 01:15:19 +00:00
cls%seawood.org
b0014b8855 Adding htmlparser to REQUIRES. Fixing myotonic bustage
git-svn-id: svn://10.0.0.236/trunk@102964 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-15 00:52:51 +00:00
waterson%netscape.com
3c7ac0611c Bug 99538. Improve debug output for XUL frames. r=evaughan, sr=hyatt
git-svn-id: svn://10.0.0.236/trunk@102962 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-15 00:45:54 +00:00
darin%netscape.com
fc46c2b828 attempting to fix AIX bustage
git-svn-id: svn://10.0.0.236/trunk@102960 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-15 00:09:09 +00:00
cls%seawood.org
cc13fa6484 Initial version for bug 99698. Not part of the build.
git-svn-id: svn://10.0.0.236/trunk@102958 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-14 23:50:59 +00:00
darin%netscape.com
8008536b25 fixes obj dir build bustage
git-svn-id: svn://10.0.0.236/trunk@102957 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-14 22:29:06 +00:00
heikki%netscape.com
e15193424a Not part of build. New tests.
git-svn-id: svn://10.0.0.236/trunk@102956 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-14 22:02:43 +00:00
jake%acutex.net
b176facdc0 Fix for bug 30731 - Reassigning closed bugs from the mass change page caused their status to be set to new.
r= myk@mozilla.org, zach@zachlipton.com


git-svn-id: svn://10.0.0.236/trunk@102955 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-14 21:50:08 +00:00
sspitzer%netscape.com
8a7a58ad8e fix for #99657. change biff url from pop3://user@host:port?check to pop3://user@host:port?/check
the first url isn't valid (w.r.t. our parser) so we'll fail to biff.  r=bbaetz, sr=darin.


git-svn-id: svn://10.0.0.236/trunk@102954 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-14 21:30:23 +00:00
darin%netscape.com
c25366fe24 fixes bug 99522 "nsHttpConnectionInfo need not inherit from nsISupports"
r=dougt, sr=mscott


git-svn-id: svn://10.0.0.236/trunk@102953 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-14 21:28:41 +00:00
sspitzer%netscape.com
888dd90c77 fix ^Ms for varada.
git-svn-id: svn://10.0.0.236/trunk@102952 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-14 21:28:16 +00:00
darin%netscape.com
c643356f83 mac project changes for bug 97528
r=dp, sr=brendan


git-svn-id: svn://10.0.0.236/trunk@102951 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-14 21:19:48 +00:00
darin%netscape.com
af57f84492 fixes bug 97528 "1200 urls created on startup about:blank" (take 2)
r=dp, sr=brendan


git-svn-id: svn://10.0.0.236/trunk@102950 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-14 21:19:41 +00:00
mkaply%us.ibm.com
8dcfc84412 #83698
r=beard, sr=jband
This code was previously r/sr for XP_UNIX. Because the OS/2 Java plugin is based on the Unix Java plugin, we need this fix too.


git-svn-id: svn://10.0.0.236/trunk@102949 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-14 21:16:19 +00:00
heikki%netscape.com
3f9884bac0 Bug 78622, DOMParser and XMLHttpRequest failures when parser blocked (with xml-stylesheet for example). r=harishd,sr=vidur.
git-svn-id: svn://10.0.0.236/trunk@102948 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-14 21:14:41 +00:00
jfrancis%netscape.com
f11c6a2688 fixes 88109: caret jumps down when typing after inserting table. One liner to properly set selection after table insertion. r=fm;sr=kin
git-svn-id: svn://10.0.0.236/trunk@102947 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-14 21:12:35 +00:00
sfraser%netscape.com
67b5d38f41 Fix for bug 96160 -- null check the i18n resource before use. Checking in for ftang, r=yokoyama, sr=sfraser
git-svn-id: svn://10.0.0.236/trunk@102946 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-14 21:12:17 +00:00
jaggernaut%netscape.com
0434fcaba2 Keep those ^M out of the tree please
git-svn-id: svn://10.0.0.236/trunk@102945 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-14 21:11:41 +00:00
jfrancis%netscape.com
ef3482215e fixes 97797: empty solo list item won't indent. Changes to nsHTMLEditRules::WillMakeList() to not outsmart itself so badly. r=fm;sr=kin
git-svn-id: svn://10.0.0.236/trunk@102944 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-14 21:09:55 +00:00
mkaply%us.ibm.com
ea207f9a95 #55103
r=mkaply, sr=blizzard
Code from Javier. Hack up the font code real good to account for OS/2 weirdness.
We now size things correctly.


git-svn-id: svn://10.0.0.236/trunk@102943 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-14 21:09:54 +00:00
darin%netscape.com
9d78227063 fixes bug 99562 "nsHttpTransaction should own the nsIProgressEventSink proxy
instead of nsHttpConnection" r=gagan, sr=mscott


git-svn-id: svn://10.0.0.236/trunk@102942 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-14 21:08:58 +00:00
mkaply%us.ibm.com
acf9f8babe #95642
r=cls
When given the win/mac/unix choice for chrome, OS/2 should use win, not define its own


git-svn-id: svn://10.0.0.236/trunk@102941 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-14 21:07:39 +00:00
vidur%netscape.com
95992b1d96 Added new WSDL loading mechanism. This is not (as yet) part of the build
git-svn-id: svn://10.0.0.236/trunk@102940 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-14 20:56:54 +00:00
vidur%netscape.com
d004bebfb4 Added nsISchemaCollection interface. Started using DOM3 namespace lookup methods. This is not (as yet) part of the build.
git-svn-id: svn://10.0.0.236/trunk@102939 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-14 20:56:06 +00:00
vidur%netscape.com
66ee3d3220 Adding DOM utility classes. This could get moved to a more general location if we continue to add functionality that is common to multiple modules. For now, it's a schema/wsdl-only thing. This is not yet part of the build.
git-svn-id: svn://10.0.0.236/trunk@102937 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-14 20:54:09 +00:00
ssu%netscape.com
12eaba0200 fixing bug 99340's part regarding turbo settings in installer not retained when running installer in silent/auto modes. r=dveditz,syd sr=mscott, a=asa affects windows platforms only.
git-svn-id: svn://10.0.0.236/trunk@102936 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-14 20:52:54 +00:00
harishd%netscape.com
1770a9beef 91744 - Avoid stack overflow by replacing recursion with a simple do-while. Removed unwanted assertions. r=heikki,sr=vidur
git-svn-id: svn://10.0.0.236/trunk@102934 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-14 20:48:25 +00:00
harishd%netscape.com
beea70d29d 98261 - Instead of throwing away the current tag close it's parent such that the stack level does not go beyond the reflow depth limit. This would allow leaf tags, that follow the current tag, to find the correct node. r=heikki, sr=attinasi.
git-svn-id: svn://10.0.0.236/trunk@102933 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-14 20:45:16 +00:00
harishd%netscape.com
7c0676bf06 98261 - reconcile the difference between the ContentSink's notion of depth and Layout's notion of depth. r=heikki, sr=attinasi.
git-svn-id: svn://10.0.0.236/trunk@102932 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-14 20:44:41 +00:00
waterson%netscape.com
e7777863f5 Bug 99293. Clean up regression tests that throw dialogs on Unix. r=karnaze, sr=attinasi
git-svn-id: svn://10.0.0.236/trunk@102929 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-14 20:32:29 +00:00
cotter%netscape.com
69d17c15fd privacy & security help content update per 85925 and 96018, a=asa, r=oeschger
git-svn-id: svn://10.0.0.236/trunk@102928 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-14 20:27:23 +00:00
sspitzer%netscape.com
6fc3865237 fix for #99671. remove unused code. r=hwaara, rs=bienvenu
git-svn-id: svn://10.0.0.236/trunk@102927 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-14 20:26:07 +00:00
varada%netscape.com
dc4bf10507 fix for bug#99393;message compose performance improvements; r=ducarroz; sr=sspitzer
git-svn-id: svn://10.0.0.236/trunk@102926 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-14 20:24:49 +00:00
kaie%netscape.com
5355c98172 b=99525 r=ddrinan/morse/relyea sr=blizzard
Completing feature added with bug 96018.


git-svn-id: svn://10.0.0.236/trunk@102924 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-14 20:19:29 +00:00
pschwartau%netscape.com
abafd4dd75 Improve visual presentation in the case where test string contains '\n'.
git-svn-id: svn://10.0.0.236/trunk@102923 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-14 20:10:49 +00:00
shrutiv%netscape.com
aa96591e89 Bug 99409: Customized Linux build works only on WinNT platform (r=tao)
Channging path names to support linux format


git-svn-id: svn://10.0.0.236/trunk@102922 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-14 19:42:37 +00:00
mcgreer%netscape.com
f49abbf1a2 work-in-progress document for stan development
git-svn-id: svn://10.0.0.236/trunk@102921 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-14 19:01:56 +00:00
jaggernaut%netscape.com
e366bf9ab7 Allow this script to work on ns trees too, and have more helpful error reporting when no srcdir was found in a Makefile.
git-svn-id: svn://10.0.0.236/trunk@102920 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-14 18:45:30 +00:00
mcgreer%netscape.com
cf2aaa9018 initial checkin of pkiutil.
git-svn-id: svn://10.0.0.236/trunk@102919 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-14 18:37:58 +00:00
mcgreer%netscape.com
c280ddbd94 initial checkin of the new command library.
git-svn-id: svn://10.0.0.236/trunk@102918 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-14 18:37:37 +00:00
mcgreer%netscape.com
9e7d9cfbc0 make stan buildable using BUILD_STAN variable
git-svn-id: svn://10.0.0.236/trunk@102917 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-14 18:07:54 +00:00
shrutiv%netscape.com
a36d016c5d Fix for bug 99409: Customized Linux build works only on WinNT platform
Changing options used in tar command (r=tao)


git-svn-id: svn://10.0.0.236/trunk@102916 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-14 17:39:17 +00:00
despotdaemon%netscape.com
2e1265bc21 Pseudo-automatic update of changes made by ddrinan@netscape.com.
git-svn-id: svn://10.0.0.236/trunk@102915 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-14 17:35:58 +00:00
nboyd%atg.com
9e1ccfcd4c Patch from Igor:
Patch fixes issue of not ignoring UNICODE format characters in match
and peek methods, adds explicit assertions checks for code assumptions
and makes handling of ASCII '\r', '\n' and UNICODE U+2028, U+2029 line
ends uniform.

It was rather tricky to fix format character issue and I spend some
time figuring out what TokenStream assumes about LineBuffer that
breaks my initial thoughts on the patch in cases like very long
sequences of format characters that do not fit in the buffer. I
fixed that but it made the code rather unclear so I put explicit
checks for assumptions/preconditions to help with debugging.

I added Context.check flag to turn on/off these checks and
Context.codeBug to throw an exception in case of check violations,
and also modified UintMap to use them instead of the private
flags there.

It would be nice to add some tests about format characters to the test
suite with checks similar to "eval('1 =\u200C= 1') == true" and
"eval('.\u200C1') == 0.1".


git-svn-id: svn://10.0.0.236/trunk@102914 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-14 17:26:12 +00:00
nboyd%atg.com
5964ebdfd5 Patch from Igor:
Hi, Norris!

I have found few problems with NativeArraj.java.

1. jsSet_length requires that the new length value should be an instance of Number. But according to Ecma 15.4.5.1, item 12-13, an error should be thrown only if ToUint32(length_value) != ToNumber(length_value). Here is a simple test that demonstrates it:

Array(5).length = new Number(1)

It currenly throws an exception.

2. jsSet_length when executing the code marked with "// assume that the representation is sparse" effectively removes all properties with values less then the current length when String is used to represent its value. Note that simply changing lines "if (d == d && d < length) delete(id);" to "if (d == d && d >= longVal) delete(id);" is not good because it would remove properties like "4.5" or "007", the full array index check has to be used instead.

Here is a test case that catches the problem:

var BIG_INDEX = 4294967290;
var a = Array(BIG_INDEX);
a[BIG_INDEX - 1] = 'a';
a[BIG_INDEX - 10000] = 'b';
a[BIG_INDEX - 0.5] = 'c';

a.length = BIG_INDEX - 5000;
var s = '';
for (var i in a) s += a[i];

print('s="'+s+'"');

this should print s='cb' (or 'bc': EcmaScript does not fix the order), but currently it gives s=''.

3. There are race conditions in jsSet_length and getIds.
The first contains:
                    if (hasElem(this, i))
                        ScriptRuntime.delete(this, new Long(i));
which would lead to call to delete in the Array prototype if 2 threads would invoke this code. Simply calling ScriptableObject.delete without any checks for existence is enough here.

getIds assumes that the count of present elements in the dense array does not change, which is not true when another thread deletes elements from dense.

The attached patch fixes these issues.

Regards, Igor


git-svn-id: svn://10.0.0.236/trunk@102913 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-14 13:50:09 +00:00
sicking%bigfoot.com
06ad4ebdd3 Make PathExpr::matches more clever and remove specialcasing of absolute path expressions
b=97107 r=peterv sr=jst


git-svn-id: svn://10.0.0.236/trunk@102912 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-14 11:49:50 +00:00
jaggernaut%netscape.com
08a47b4511 Fix debug build bustage on Windows by changing |for (PRUint32 i=0; ..; ..) {} for (PRUint32 i=0; ..; ..) {}| to |PRUint32 i; for (i=0; ..; ..) {} for (i=0; ..; ..) {}|
git-svn-id: svn://10.0.0.236/trunk@102911 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-14 09:27:57 +00:00
jaggernaut%netscape.com
cbf6249310 Add support for IsVoid and SetIsVoid, add NS_COM to nsAStringGenerator. r=jst, rs=scc.
git-svn-id: svn://10.0.0.236/trunk@102910 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-14 08:23:46 +00:00
andreas.otte%primus-online.de
84bc369b7e fix bug 97983 [ExtractUrlPart allows no access to the directory part of the url] This patch introduces a new bitmask url_Path that allows accessing the whole path, moved url_Directory from path access to it's original meaning accessing the directory portion of the url. Also fixed some start/endposition calculations, r=dougt@netscape.com,sr=darin@netscape.com
git-svn-id: svn://10.0.0.236/trunk@102909 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-14 05:47:54 +00:00
andreas.otte%primus-online.de
3bd3613d5a fix bug 99081 [ExtractPortFrom sometimes finds ports that are not there] ExtractPortFrom trys to parse the portnumber from url-strings and sometimes it found ports that are none like messageids of news urls, r=dougt@netscape.com, sr=darin@netscape.com
git-svn-id: svn://10.0.0.236/trunk@102908 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-14 05:38:51 +00:00
jaggernaut%netscape.com
937638062c Bug 73353: move gfx from module layout to module gfx and fix up REQUIRES lines. r=cls
git-svn-id: svn://10.0.0.236/trunk@102907 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-14 05:37:29 +00:00
mscott%netscape.com
54ca33a168 Bug #99222 --> for compose auto complete, don't show the popup if we have an exact
macth.
r=ducarroz
sr=sspitzer


git-svn-id: svn://10.0.0.236/trunk@102906 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-14 05:36:27 +00:00
mscott%netscape.com
e70b8b3f14 Bug #99222 --> make the widget flexible enough to only show the popup if
there are  a certain # of results present in the list.
r=sspitzer, ducarroz
sr=hewitt


git-svn-id: svn://10.0.0.236/trunk@102905 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-14 05:34:59 +00:00
bryner%netscape.com
a1a013a1fa Bug 73353 - clean up REQUIRES. patch from jag, r=bryner, sr=brendan.
git-svn-id: svn://10.0.0.236/trunk@102904 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-14 04:55:50 +00:00
bienvenu%netscape.com
be6dc02100 fix problems playing back offline deletes when delete model is not delete to trash r=naving, sr=sspitzer 96631
git-svn-id: svn://10.0.0.236/trunk@102903 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-14 04:47:43 +00:00
blizzard%redhat.com
55401797e9 Bump the epoch up to make room for 0.9.4.x versions. Not part of the build.
git-svn-id: svn://10.0.0.236/trunk@102902 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-14 04:44:27 +00:00
bienvenu%netscape.com
85c4a00c88 fix crash exiting browser with turbo enabled if you've opened an address book r=naving sr=sspitzer 99510
git-svn-id: svn://10.0.0.236/trunk@102901 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-14 04:44:10 +00:00
naving%netscape.com
013b55f08a 89698 r=bienvenu sr=mscott. Make rename imap folder work for backslash and
change the alert wording
99150 r/sr=bienvenu Make rename Cyrus imap folder work correctly for '/'


git-svn-id: svn://10.0.0.236/trunk@102900 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-14 04:39:28 +00:00
dbaron%fas.harvard.edu
638d954dab Make public identifier matching case-insensitive to expand the set of public identifiers triggering quirks mode since some existing pages use FPIs with incorrect case. Add two additional FPIs to the list. b=98977 r=harishd sr=waterson
git-svn-id: svn://10.0.0.236/trunk@102899 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-14 04:18:59 +00:00
brendan%mozilla.org
c1e6be1826 Fix unsafe JS_DHashTableRawRemove usage; unoverload cx->resolving into a counter and a JSDHashTable pointer (94422, r/sr=jband,waterson with dbaron sanity checks).
git-svn-id: svn://10.0.0.236/trunk@102898 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-14 03:37:15 +00:00
sonmi%netscape.com
8c5d584c57 forgot this in the last checkin - added Solaris 9, fixed 2 bugs
git-svn-id: svn://10.0.0.236/trunk@102897 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-14 01:05:06 +00:00
sonmi%netscape.com
81ba96e1a7 added Sparc solaris 9
fixed unfiled bug in mksymlink (trying to symlink if dir exists in
	unix dirs, trying to symlink if either dir or symlink exists)
fixed bug in header , debug flag not passed into mksymlinks
fixed bug in header , always-yes flag not passed into mksymlinks
added email option -ml for qa_stat - only sends hyperlink to result.html
fixed unfiled bug NT backward compatibility test failures
removed unnecessary hostnamesetting from anything but nssqa
changed handeling of pass/fail in backward compatibility test
	evaluation, started fix of bugs 97209 and 98219


git-svn-id: svn://10.0.0.236/trunk@102896 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-14 01:04:05 +00:00
pschwartau%netscape.com
fd39a30c74 Making testcase compatible with updated testRegExp() function in utility file shell.js
git-svn-id: svn://10.0.0.236/trunk@102895 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-14 00:29:21 +00:00
pschwartau%netscape.com
cfa8058644 Improving the error-reporting functions for RegExp tests. Now more complete and more consistent.
git-svn-id: svn://10.0.0.236/trunk@102894 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-14 00:15:59 +00:00
mkaply%us.ibm.com
23b1bbae91 #95642
r=cls
Because other platforms then Unix use the Unix build system, add Makefile.ins to some win
directories so platforms can choose to use the win versions of files


git-svn-id: svn://10.0.0.236/trunk@102893 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-13 23:01:14 +00:00
waterson%netscape.com
9ad4e81448 Bug 99443. Use filtered insertion point of first appended child instead of unfiltered insertion point when appending. r=dbaron, sr=hyatt
git-svn-id: svn://10.0.0.236/trunk@102892 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-13 22:56:55 +00:00
mcgreer%netscape.com
0f765a19da Use NSS_IMPLEMENT in code files for consistency.
Implement some basic certificate routines.
Define some of the PKI types.
Implement some trust domain routines, but only for testing purposes.
Allow for building as shared library.


git-svn-id: svn://10.0.0.236/trunk@102891 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-13 22:16:22 +00:00
mcgreer%netscape.com
96afac4792 ah, first bug. init the token last when creating a slot.
git-svn-id: svn://10.0.0.236/trunk@102890 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-13 22:14:22 +00:00
mcgreer%netscape.com
4a2c156d61 initial checkin of the cryptoki device library code for stan. The current
amount of implemented code does little more than basic initialization of
a module and loading of a module's slots and tokens.


git-svn-id: svn://10.0.0.236/trunk@102889 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-13 22:06:10 +00:00
alecf%netscape.com
b83f1b96a6 back out this change, it was unintentional
r=bryner
no a=


git-svn-id: svn://10.0.0.236/trunk@102888 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-13 22:03:27 +00:00
wtc%netscape.com
7a6591ae62 Bugzilla bug 98335: fixed two errors identified by compiler warnings
and deleted an unnecessary if.  The patch is contributed by
timeless@mac.com.


git-svn-id: svn://10.0.0.236/trunk@102887 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-13 21:39:05 +00:00
timeless%mac.com
53bd53d97b bugzilla wasn't catching mozilla on 98 which was annoying. r=jake
git-svn-id: svn://10.0.0.236/trunk@102885 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-13 20:41:59 +00:00
jake%acutex.net
f30e44a89e Fix for bug 58436 - javascript strict warnings in query.cgi
Patch by Christian Reis <kiko@async.com.br>
r= caillon@returnzero.com, jake@acutex.net


git-svn-id: svn://10.0.0.236/trunk@102884 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-13 20:04:40 +00:00
timeless%mac.com
a28f045020 Bugzilla Bug 99465 FreeBSD not recognized!
r=jake


git-svn-id: svn://10.0.0.236/trunk@102881 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-13 18:21:07 +00:00
gerv%gerv.net
5f3a15bc40 Backing that out. <sigh>. Trunk, branch. Branch, trunk. How hard can it be?
git-svn-id: svn://10.0.0.236/trunk@102879 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-13 17:40:57 +00:00
gerv%gerv.net
764742fd24 Prevent problems with NS initial start page appearing, by renaming pref. Bug 99441. r=syd, gerv, sr=jband. This will be backed out immediately after 0.9.4 ships.
git-svn-id: svn://10.0.0.236/trunk@102878 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-13 16:57:41 +00:00
axel%pike.org
06c1dcb37b updating testcase. IE needs to have dummy-param declared, synching with version from the website
git-svn-id: svn://10.0.0.236/trunk@102877 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-13 14:58:26 +00:00
nboyd%atg.com
9ede964b6a Fix broken link
git-svn-id: svn://10.0.0.236/trunk@102876 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-13 13:49:23 +00:00
timeless%mac.com
f99092b056 Bug 51844 about:blank is invalid
The new about blank:
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"><html><head><title></title></head><body></body></html>

patch by cbiesinger@web.de r=bbaetz sr=darin


git-svn-id: svn://10.0.0.236/trunk@102875 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-13 13:48:44 +00:00
locka%iol.ie
95541d8e3c NOT PART OF BUILD. Updated pluginhostctrl project to remove some duff targets and added a README file
git-svn-id: svn://10.0.0.236/trunk@102874 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-13 13:34:22 +00:00
timeless%mac.com
493a18f5a7 Bug 90380 Get rid of |#ifdef _IMPL_NS_XPRINT|
patch by Roland.Mainz@informatik.med.uni-giessen.de
r=jesup,jag,dcran sr=blizzard


git-svn-id: svn://10.0.0.236/trunk@102873 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-13 13:29:58 +00:00
locka%iol.ie
8aeeeed60a NOT PART OF BUILD. Test files for ActiveX control for hosting Netscape plugins in IE
git-svn-id: svn://10.0.0.236/trunk@102872 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-13 12:38:20 +00:00
locka%iol.ie
987d15ef62 NOT PART OF BUILD. Plugin SDK headers for building ActiveX control for hosting Netscape plugins in IE
git-svn-id: svn://10.0.0.236/trunk@102871 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-13 12:37:11 +00:00
locka%iol.ie
c90b07582a NOT PART OF BUILD. New ActiveX control that allows Netscape plugins to run in IE without modification.
git-svn-id: svn://10.0.0.236/trunk@102870 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-13 12:36:17 +00:00
despotdaemon%netscape.com
61073b6c12 Pseudo-automatic update of changes made by glazman@netscape.com.
git-svn-id: svn://10.0.0.236/trunk@102869 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-13 12:14:17 +00:00
syd%netscape.com
c6fdc17778 More 88844 stuff, make sure we create the key if it doesn't exist.
git-svn-id: svn://10.0.0.236/trunk@102865 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-13 09:37:50 +00:00
axel%pike.org
45ecfc4658 bug 98704, kill ContextState|ProcessorState|DOMHelper::getParentNode, r=sicking, peterv; sr=jst
git-svn-id: svn://10.0.0.236/trunk@102864 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-13 09:23:44 +00:00
syd%netscape.com
04476a3966 Trunk version of latest 88844 stuff, look for "Mozilla Quick Launch" instead of
trying to construct a string based on the app name, which is not working.
r=ssu, sr=brendan, a=asa


git-svn-id: svn://10.0.0.236/trunk@102863 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-13 09:09:06 +00:00
andreas.otte%primus-online.de
07ebb01e7e fix bug 97988 [contractid of nsAuthURLParser same as of nsNoAuthURLParser] seems to be a simple cut and paste error now corrected, r=dougt@netscape.com, sr=darin@netscape.com
git-svn-id: svn://10.0.0.236/trunk@102862 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-13 07:42:22 +00:00
cls%seawood.org
bd89b42517 Adding newline to end of file to fix HP-UX bustage
git-svn-id: svn://10.0.0.236/trunk@102861 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-13 03:42:52 +00:00
bienvenu%netscape.com
8e2d5732de default for unsent messages should be escaped uri, r=sspitzer, sr=mscott 79245
git-svn-id: svn://10.0.0.236/trunk@102860 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-13 03:00:59 +00:00
darin%netscape.com
76c7355ac1 checking bbaetz's patch for bug 89500 "SOCKS: only http|https re-directted in (post Mozilla 0.9.2)"
patch=bbaetz, r=dougt, sr=darin


git-svn-id: svn://10.0.0.236/trunk@102859 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-13 02:21:05 +00:00
darin%netscape.com
eb65859c5a mac project change for bug 89500
git-svn-id: svn://10.0.0.236/trunk@102858 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-13 02:20:52 +00:00
waldemar%netscape.com
d71222e9b1 Fixed template overinstantiation bug
git-svn-id: svn://10.0.0.236/trunk@102857 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-13 01:04:22 +00:00
sonmi%netscape.com
299c5faba1 took out some outdated 3.2 workarounds
put in debug info for sjsu


git-svn-id: svn://10.0.0.236/trunk@102856 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-13 01:03:07 +00:00
jaggernaut%netscape.com
df1bc44219 Oops, messed up the copyright in the license part, rectifying that. r=michel@rubberchicken.nl
git-svn-id: svn://10.0.0.236/trunk@102855 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-13 00:31:47 +00:00
rjesup%wgate.com
b88ac2aaa0 Bug 98711: Fix misuses of string.Right(). r=jfrancis, sr=jst
git-svn-id: svn://10.0.0.236/trunk@102854 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-13 00:09:49 +00:00
cls%seawood.org
fea7889357 Increase GOT buffer for irix (debug) builds when building gkcontent.
Thanks to nickb@adacel.com.au (Nick Blievers) for the patch.
Bug #99395 r=cls


git-svn-id: svn://10.0.0.236/trunk@102853 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-12 23:48:26 +00:00
edburns%acm.org
05e81fc36e 99188
r=ashuk
a=edburns

re-implement prompt for cookies.

Modified Files:
 	CBrowserContainer.cpp PromptActionEvents.cpp ns_util.cpp
 	ns_util.h


git-svn-id: svn://10.0.0.236/trunk@102852 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-12 23:45:37 +00:00
heikki%netscape.com
8ef0ee4d61 Bug 78021, Copy Link Address context menu does not work for image maps (<area> elements), <link> elements or simple XLinks. r=harishd, sr=vidur.
git-svn-id: svn://10.0.0.236/trunk@102850 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-12 23:31:37 +00:00
bienvenu%netscape.com
db3558d8b8 fix problems enabling reply/forward and related commands when offline w/o offline msg bodies (91352) and problem with delete key getting disabled after next unread (84260) r=naving, sr=sspitzer
git-svn-id: svn://10.0.0.236/trunk@102849 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-12 23:26:33 +00:00
bienvenu%netscape.com
3d50835873 cosmetic, whitespace changes only
git-svn-id: svn://10.0.0.236/trunk@102848 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-12 23:19:36 +00:00
bienvenu%netscape.com
2d2ba143df fix handling of limiting offline download checkbox rs=sspitzer prefs ui was setting the wrong pref 96335
git-svn-id: svn://10.0.0.236/trunk@102847 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-12 23:15:33 +00:00
bienvenu%netscape.com
789e928684 fix assertions on exit trying to remove biff servers r=racham, sr=sspitzer 97240
git-svn-id: svn://10.0.0.236/trunk@102846 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-12 23:14:02 +00:00
bnesse%netscape.com
2ea4145ea4 Fixes for bug 98582 (add title to about:config window) and bug 99291 (correctness: use defines instead of hard coded numbers in switch statement). r=dveditz, sr=waterson (98582) and r=bnesse, sr=brendan (99291). Checking in for chipc.
git-svn-id: svn://10.0.0.236/trunk@102844 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-12 22:50:00 +00:00
waterson%netscape.com
d9b076b1a6 Fix missing return value on ChildIterator::operator=().
git-svn-id: svn://10.0.0.236/trunk@102843 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-12 22:41:49 +00:00
alecf%netscape.com
6e7817f040 oops, back out this line - didn't mean to check it in
git-svn-id: svn://10.0.0.236/trunk@102842 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-12 22:32:19 +00:00
locka%iol.ie
d2678d6cea NOT PART OF BUILD. Doxygen config file updated slightly
git-svn-id: svn://10.0.0.236/trunk@102841 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-12 22:09:17 +00:00
kaie%netscape.com
516c90280a Mozilla bug 99052, fixing crash.
Adding null and error checks.
r=nelsonb


git-svn-id: svn://10.0.0.236/trunk@102840 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-12 21:58:06 +00:00
cavin%netscape.com
7c5a99d724 Removing newlines (^M).
git-svn-id: svn://10.0.0.236/trunk@102839 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-12 21:48:33 +00:00
waterson%netscape.com
e9f40bddfa Use C-style cast to make gcc-2.7.2.3 happy.
git-svn-id: svn://10.0.0.236/trunk@102838 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-12 21:37:20 +00:00
alecf%netscape.com
b7598a10b0 Add REQUIRES to many modules for win32 support, bug 98372 r=cls
git-svn-id: svn://10.0.0.236/trunk@102837 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-12 21:32:10 +00:00
alecf%netscape.com
b5515d626e oops, back this out!
git-svn-id: svn://10.0.0.236/trunk@102836 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-12 21:30:31 +00:00
alecf%netscape.com
d6583a39a3 oops, missed this in my last checkin
git-svn-id: svn://10.0.0.236/trunk@102834 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-12 21:03:13 +00:00
ssu%netscape.com
ad5c0c10a3 fixing bug 99340 - Installer dies with error 2 under Win9x. r=syd,dveditz sr=mscott a=asa. not part of tinderbox builds. affects windows installers only.
git-svn-id: svn://10.0.0.236/trunk@102833 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-12 20:59:48 +00:00
varada%netscape.com
0c696b9b47 fix for 99146- performance improvement for mailcompose window- getting rid of unnecessary logging; r/sr= sspitzer
git-svn-id: svn://10.0.0.236/trunk@102830 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-12 20:47:38 +00:00
varada%netscape.com
22b379f9f3 fix for bug#99146;performance improvement for mailcompose;r/sr=sspitzer
git-svn-id: svn://10.0.0.236/trunk@102829 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-12 20:47:28 +00:00
vidur%netscape.com
7149298284 Fix for bug 12189. Added NS_ERROR_MODULE_GENERAL as an return code base for non-core components that don't care if their return codes overlap. r=dougt, sr=rpotts
git-svn-id: svn://10.0.0.236/trunk@102828 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-12 20:43:49 +00:00
peterlubczynski%netscape.com
9b969a0e52 Fix for crash when checking for a sub document bug 96579 r=av sr=attinasi
git-svn-id: svn://10.0.0.236/trunk@102827 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-12 20:43:40 +00:00
alecf%netscape.com
f3d9c9c141 Add REQUIRES to many modules for win32 support, bug 98372 r=cls
git-svn-id: svn://10.0.0.236/trunk@102825 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-12 20:32:40 +00:00
alecf%netscape.com
18b7e93c42 Update mailnews REQUIRES and MODULEs for bug 98371, r=cls
git-svn-id: svn://10.0.0.236/trunk@102824 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-12 20:30:32 +00:00
alecf%netscape.com
95ff5385bc more updates to rules to support REQUIRES on windows, bug 98371, r=cls
git-svn-id: svn://10.0.0.236/trunk@102823 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-12 20:27:13 +00:00
bienvenu%netscape.com
243bf35f37 fix imap copying messages status rs=sspitzer 99358
git-svn-id: svn://10.0.0.236/trunk@102822 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-12 20:23:28 +00:00
waterson%netscape.com
b2c5eb44e4 Bug 84645. Move XBL insertion point stuff in frame constructor so it can get along with continuing frames. r=dbaron, sr=hyatt
git-svn-id: svn://10.0.0.236/trunk@102821 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-12 20:22:21 +00:00
waterson%netscape.com
25df26f9d3 Bug 84645. Move XBL insertion point logic into nsCSSFrameConstructor, where it can interact nicely with continuing frames. r=dbaron, sr=hyatt
git-svn-id: svn://10.0.0.236/trunk@102820 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-12 20:19:41 +00:00
bzbarsky%mit.edu
eadb233ab0 Add line-wrapping capability to the view source window. Bug 22022,
r=bzbarsky, sr=alecf


git-svn-id: svn://10.0.0.236/trunk@102819 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-12 20:16:32 +00:00
cavin%netscape.com
216eb63309 Bug #99101: In RenameLeaf(), unescape the folder name before searching for hierarchy delimiter (to figure out parent pathname). r=naving, sr=bienvenu.
git-svn-id: svn://10.0.0.236/trunk@102818 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-12 20:14:35 +00:00
nicolson%netscape.com
93fa7382af Fix 99375: UnsatisfiedLinkError gives misleading description
git-svn-id: svn://10.0.0.236/trunk@102815 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-12 18:55:03 +00:00
alecf%netscape.com
bbdc10e41a add platform support
git-svn-id: svn://10.0.0.236/trunk@102813 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-12 18:46:31 +00:00
jaggernaut%netscape.com
2b5d7e4de9 Add perl script that cleans up the REQUIRES lines in Makefile.in files by removing module names which aren't "REQUIRE"d any longer.
git-svn-id: svn://10.0.0.236/trunk@102812 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-12 18:06:07 +00:00
danm%netscape.com
9acc98ddc3 disable the code that gets the application name by initializing an http protocol handler before XPCOM is initalized. bug 99286 code=dp r=danm
git-svn-id: svn://10.0.0.236/trunk@102811 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-12 17:56:40 +00:00
dbaron%fas.harvard.edu
60089011e0 Oops.
git-svn-id: svn://10.0.0.236/trunk@102810 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-12 16:57:21 +00:00
dbaron%fas.harvard.edu
51a98f11f2 Add script that uses gcc-generated dependency files to count the number of C/C++ files for which each header file is brought in.
git-svn-id: svn://10.0.0.236/trunk@102809 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-12 16:55:38 +00:00
alecf%netscape.com
a390414a3e oops, comment out some code that I wasn't done with
git-svn-id: svn://10.0.0.236/trunk@102808 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-12 16:52:26 +00:00
alecf%netscape.com
44443bfe09 first time added
generates graphviz-style .dot files from REQUIRES/MODULE entries in makefiles


git-svn-id: svn://10.0.0.236/trunk@102807 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-12 16:51:11 +00:00
rjesup%wgate.com
23c9a74723 Bug 92576. nsVoidArray->nsAutoVoidArray. sr=jst, r=waterson, r=pavlov, r=kin, r=kmcclusk
git-svn-id: svn://10.0.0.236/trunk@102805 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-12 14:59:11 +00:00
locka%iol.ie
a9d85d95f7 NOT PART OF BUILD. Doxygen config file for generating documents from Mozilla's public include and idl files.
git-svn-id: svn://10.0.0.236/trunk@102804 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-12 14:53:46 +00:00
jaggernaut%netscape.com
9985dcc528 Clean up REQUIRES lines, put content in its own module instead of in layout's, r=cls.
git-svn-id: svn://10.0.0.236/trunk@102802 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-12 12:48:23 +00:00
bryner%netscape.com
37f7eb6022 REQUIRES updates. Patch from jag, r=cls.
git-svn-id: svn://10.0.0.236/trunk@102800 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-12 08:16:34 +00:00
andreas.otte%primus-online.de
aae2540b4c bug 95677 [update urltest.cpp] update urltest to reflect changes in urlparser, changing format of testfiles, adding special testfiles for fileurls, r=dougt@netscape.com, sr=darin@netscape.com
git-svn-id: svn://10.0.0.236/trunk@102799 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-12 08:01:12 +00:00
cls%seawood.org
ba0eafb017 Create active header list for each module during the export phase.
At the end of the export loop, remove the outdated files.
Requires setting MOZ_TRACK_MODULE_DEPS to activate
Bug #59454 r=bryner sr=alecf


git-svn-id: svn://10.0.0.236/trunk@102798 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-12 06:42:26 +00:00
cls%seawood.org
db81759000 Recursively compare pre-generated list of active header files against current include directory contents. If the directory contains extra entries, remove them.
Bug #59454 r=bryner sr=alecf


git-svn-id: svn://10.0.0.236/trunk@102797 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-12 06:39:56 +00:00
brendan%mozilla.org
9457b2de04 1. Fix jsdhash/pldhash.[ch] so that add/remove cycles for a given k do not
create a long chain of removed sentinels.  Also, when adding k to a table
    where k is not mapped, but where k hashes to a chain that includes removed
    sentinels, recycle the first removed sentinel in the chain for k's entry.
2.  Cache cx->resolving till js_DestroyContext, to avoid high JSDHashTable
    new/destroy overhead in js_LookupProperty.
3.  Add NS_TraceStack to nsTraceMalloc.[ch] and clean the .c file up a bit.


git-svn-id: svn://10.0.0.236/trunk@102796 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-12 06:39:31 +00:00
cls%seawood.org
6d47ac1557 Make generated header use common install rules.
Bug #59454 r=bryner sr=alecf


git-svn-id: svn://10.0.0.236/trunk@102795 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-12 06:35:50 +00:00
cls%seawood.org
9c104e0cdb Drop delay between retrying locks from 1sec to 100ms and drop the overall timeout value from 60 secs to 10secs.
Bug #59454 r=bryner sr=alecf


git-svn-id: svn://10.0.0.236/trunk@102794 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-12 06:34:06 +00:00
cls%seawood.org
8c6f8fdd2e Add support for adding multiple items to list at once.
Read entire file into mem to avoid overhead of exec'ing multiple greps.
Bug #59454 r=bryner sr=alecf


git-svn-id: svn://10.0.0.236/trunk@102793 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-12 06:32:35 +00:00
simon%softel.co.il
be6ca20704 Change the title of ISO-8859-8 encoding from Visual Hebrew to Hebrew Visual so that it appears with the other Hebrew encodings in the sorted list. Bug 84181, r=tao.
git-svn-id: svn://10.0.0.236/trunk@102792 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-12 06:32:16 +00:00
peterlubczynski%netscape.com
5b05cad31c Correct ussages of data= for object tags embedding documents bug 97799 r=dcone sr=attinasi
git-svn-id: svn://10.0.0.236/trunk@102791 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-12 04:00:52 +00:00
leaf%mozilla.org
f97f65b810 Automated update
git-svn-id: svn://10.0.0.236/trunk@102790 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-12 03:28:43 +00:00
blizzard%redhat.com
3afe7411a3 Checking in for Ulrich Drepper. Bug #99246. r=beard, sr=brendan
git-svn-id: svn://10.0.0.236/trunk@102789 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-12 03:19:08 +00:00
stephend%netscape.com
2994843c26 Bug 60658. JavaScript strict warning. r=timeless, sr=shaver
git-svn-id: svn://10.0.0.236/trunk@102788 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-12 03:01:56 +00:00
mkaply%us.ibm.com
4648d4241f #96050
Removing unnecessary files from xprint for Roland.Mainz@informatik.med.uni-giessen.de


git-svn-id: svn://10.0.0.236/trunk@102787 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-12 02:35:51 +00:00
blakeross%telocity.com
6bfd582786 Quitting from Composer does not work correctly when in turbo (99318) and another non turbo-related quitting bug. r/sr=ben
git-svn-id: svn://10.0.0.236/trunk@102786 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-12 02:20:50 +00:00
markh%activestate.com
6173ac0a20 Add support for unwrap() testing, and also add some better messages
for xpcom sample component missing.

Not part of the build


git-svn-id: svn://10.0.0.236/trunk@102785 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-12 01:47:22 +00:00
markh%activestate.com
3da7154e02 Add unwrap support.
Not part of the build.


git-svn-id: svn://10.0.0.236/trunk@102784 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-12 01:46:43 +00:00
markh%activestate.com
25a26c0129 Fix up bogus casts of nsXPTType pointers - fixes segment faults on some
platforms.

Not part of the build.


git-svn-id: svn://10.0.0.236/trunk@102783 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-12 01:45:57 +00:00
markh%activestate.com
6c0218a0d0 Add unwrap support.
Not part of the build


git-svn-id: svn://10.0.0.236/trunk@102782 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-12 01:44:42 +00:00
markh%activestate.com
1b547eec4b Add unwrap support (the ability to get the Python object behind an
anonymous Python implemented xpcom object)

Not part of the build.


git-svn-id: svn://10.0.0.236/trunk@102781 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-12 01:43:33 +00:00
blakeross%telocity.com
2584dcf72b Committing a file I forgot yesterday in an r/sr/a'd checkin (caused an xml error when opening the addressbook sidebar panel).
git-svn-id: svn://10.0.0.236/trunk@102780 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-12 01:00:14 +00:00
bienvenu%netscape.com
4724750747 fix leak of temp file while saving imap message as draft offline r=cavin, sr=sspitzer 81690
git-svn-id: svn://10.0.0.236/trunk@102778 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-12 00:27:10 +00:00
danm%netscape.com
6b1424917c unmaximize the window any time it's moved or sized. bug 98701 r=hyatt,jaggernaut
git-svn-id: svn://10.0.0.236/trunk@102776 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-12 00:19:25 +00:00
waterson%netscape.com
8b1cbb3fd2 Bug 97383. Add regression test.
git-svn-id: svn://10.0.0.236/trunk@102771 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-11 22:49:15 +00:00
waterson%netscape.com
edab5b07b2 Bug 98844. Don't include LDAP libs when DISABLE_LDAP build flag is set. r=rpotts, sr=jst.
git-svn-id: svn://10.0.0.236/trunk@102767 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-11 22:27:32 +00:00
wtc%netscape.com
4567105730 Bugzilla bug 96571: fixed the PL_strn* functions that may read beyond
the end of buffer if the buffer is not null-terminated.
Modified files: strchr.c strcstr.c strlen.c strpbrk.c strstr.c


git-svn-id: svn://10.0.0.236/trunk@102763 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-11 22:22:16 +00:00
waterson%netscape.com
9a5298ffca Bug 72152. Be sure to update the pres context's visible area after doing a resize reflow. r=dbaron, sr=attinasi
git-svn-id: svn://10.0.0.236/trunk@102762 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-11 22:21:21 +00:00
waterson%netscape.com
56661b67f2 Bug 97383. Include the float's max-element-width in computation of the line's max-element-width so that we're guaranteed to place content next to a left floater. Revert some of the NOWRAP changes that should no longer be necessary. r=dbaron, sr=attinasi
git-svn-id: svn://10.0.0.236/trunk@102761 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-11 22:17:21 +00:00
attinasi%netscape.com
0808e2e5a9 Fixed a typo that was causing an assertion in one of my testcases: b=99229, r=karnaze sr=waterson
git-svn-id: svn://10.0.0.236/trunk@102760 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-11 21:28:38 +00:00
timeless%mac.com
8dceacd894 Bugzilla Bug 98929 Implementation of Content-Language in HTTP
patch by drepper@cygnus.com r=peterv sr=jst


git-svn-id: svn://10.0.0.236/trunk@102759 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-11 21:12:23 +00:00
dp%netscape.com
29c892e459 letting factories overrride native components. Fixes embedding
smoketest blocker bug# 99130 r=adamlock


git-svn-id: svn://10.0.0.236/trunk@102757 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-11 18:10:31 +00:00
shrutiv%netscape.com
7fa533958e Fix for bug 7717: Cancel button should have confirm dialog (r=tao)
git-svn-id: svn://10.0.0.236/trunk@102756 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-11 17:22:53 +00:00
mkaply%us.ibm.com
746b35c5f6 OS/2 breakage
git-svn-id: svn://10.0.0.236/trunk@102755 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-11 13:08:11 +00:00
peterv%netscape.com
cddb6a17e5 Fix for bug 98031 (Composer adds space(s) when saving doc with link between parentheses). r=brade, sr=jst.
git-svn-id: svn://10.0.0.236/trunk@102754 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-11 09:32:51 +00:00
timeless%mac.com
1344b908fb Bugzilla Bug 85543 Extra blank box to the left of 'Done.' on mac classic skin.
r=ksosez sr=blake


git-svn-id: svn://10.0.0.236/trunk@102752 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-11 08:45:15 +00:00
mcafee%netscape.com
195d9616b2 Avoid stomping on build status when testing for Embed build status. One line change, rest is whitespace cleanup
git-svn-id: svn://10.0.0.236/trunk@102751 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-11 07:43:37 +00:00
peterv%netscape.com
0ee150e531 Fix for bug 85708 (Should support "text/xml" MIME media type). Recognize text/xml and application/xml in the type attribute of a stylesheet PI. r=Pike, sr=jst.
git-svn-id: svn://10.0.0.236/trunk@102749 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-11 07:14:29 +00:00
peterv%netscape.com
1761db333c Fix for bug 99044 (Big memory leak in DOMHelper.cpp). Switch arguments to correct order in the Map::put call and set ownership model for the Map. r=Pike, sr=jst.
git-svn-id: svn://10.0.0.236/trunk@102748 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-11 07:09:23 +00:00
beard%netscape.com
acc4c8f8c6 fix for bug #98290, keep stack aligned to 16 byte boundaries, r=beard, sr=sfraser
git-svn-id: svn://10.0.0.236/trunk@102747 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-11 06:10:31 +00:00
naving%netscape.com
39abfc8109 Just crashed here. Make sure filterList is not null. no bug
git-svn-id: svn://10.0.0.236/trunk@102746 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-11 05:37:48 +00:00
mkaply%us.ibm.com
ac2c728dcb OS/2 breakage - forgotten member variable
git-svn-id: svn://10.0.0.236/trunk@102745 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-11 05:16:07 +00:00
mkaply%us.ibm.com
76fc2451f3 These files are somehow crosslinked in CVS - putting them back
git-svn-id: svn://10.0.0.236/trunk@102744 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-11 04:50:13 +00:00
jst%netscape.com
34c33bcf31 Removing unnecessary casts. No code change
git-svn-id: svn://10.0.0.236/trunk@102743 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-11 04:48:31 +00:00
mkaply%us.ibm.com
b1120cb472 #76856
Night of the Living Dead CVS files - rekilling files that got changes made after they were killed


git-svn-id: svn://10.0.0.236/trunk@102742 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-11 04:45:47 +00:00
mkaply%us.ibm.com
2fa9205419 #76856
Night of the Living Dead CVS files - rekilling files that got changes made after they were killed


git-svn-id: svn://10.0.0.236/trunk@102741 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-11 04:34:45 +00:00
mkaply%us.ibm.com
f2e45e6f41 #76856
Night of the Living Dead CVS files - rekilling files that got changes made after they were killed


git-svn-id: svn://10.0.0.236/trunk@102740 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-11 04:25:14 +00:00
bienvenu%netscape.com
1c553c1d4a fix saving of newsrc files on shutdown when the prefs service has gone away rs=sspitzer 98816
git-svn-id: svn://10.0.0.236/trunk@102739 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-11 04:18:15 +00:00
mkaply%us.ibm.com
17e9e184bf #76856
Night of the Living Dead CVS files - rekilling files that got changes made after they were killed


git-svn-id: svn://10.0.0.236/trunk@102738 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-11 03:50:35 +00:00
jst%netscape.com
412f672172 Reoving unnecessary casts and giving this code some more nsCOMPtr love. r=bryner@netscape.com, sr=me
git-svn-id: svn://10.0.0.236/trunk@102737 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-11 03:35:30 +00:00
peterlubczynski%netscape.com
0924fbda32 Use memmove instead of strncpy bug 98705 r=av sr=attinasi
git-svn-id: svn://10.0.0.236/trunk@102736 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-11 03:29:20 +00:00
mkaply%us.ibm.com
7e93f022c8 #76856
Night of the Living Dead CVS files - rekilling files that got changes made after they were killed


git-svn-id: svn://10.0.0.236/trunk@102734 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-11 03:22:16 +00:00
vidur%netscape.com
49d869d53e Fix for bug 98815. Implement DOM Level 3 namespace methods for prefix and URI lookup. r=heikki, sr=jst
git-svn-id: svn://10.0.0.236/trunk@102733 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-11 03:05:15 +00:00
vidur%netscape.com
10d80cd1e9 Fix for bug 98815. Implement DOM Level 3 namespace methods for prefix and URI lookup. The implementation of these may be changed later if we get rid of the nsINameSpace interface. r=heikki, sr=jst
git-svn-id: svn://10.0.0.236/trunk@102732 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-11 03:04:49 +00:00
shrutiv%netscape.com
1aef6dea67 Fixing bug 93113: Enhancement for disabled look of Navigator check box
(r=tao)


git-svn-id: svn://10.0.0.236/trunk@102731 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-11 01:48:28 +00:00
sonmi%netscape.com
8bbd8b95f0 removed obsolete workaround, not running pk12util tests because of 3.2 failures
git-svn-id: svn://10.0.0.236/trunk@102730 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-11 01:46:09 +00:00
blizzard%redhat.com
bc90ba2ebd Fix bug #99118. X remote client can't find any running clients. We need to find the inner window that is the window managed window, not just the toplevel windows. "I can't believe this ever worked." r=bryner,sr=alecf
git-svn-id: svn://10.0.0.236/trunk@102729 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-11 01:36:19 +00:00
bienvenu%netscape.com
b997ab9e29 fix topcrash when you delete a local folder while it's being reparsed rs=sspitzer 90253
git-svn-id: svn://10.0.0.236/trunk@102728 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-11 01:30:44 +00:00
shrutiv%netscape.com
ad041c24da Fixing bug 93019: Logo button URL c11n should work on all logo buttons
(r=tao)


git-svn-id: svn://10.0.0.236/trunk@102727 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-11 01:29:27 +00:00
bienvenu%netscape.com
775401e954 part of fix for problems saving imap messages offline as templates, rs=sspitzer 81690
git-svn-id: svn://10.0.0.236/trunk@102726 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-11 01:23:51 +00:00
bienvenu%netscape.com
9a5be8fb8a part of fix for problems saving imap messages offline as templates, r=cavin, sr=sspitzer 81690
git-svn-id: svn://10.0.0.236/trunk@102725 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-11 01:22:59 +00:00
blakeross%telocity.com
2ecc2b033f Fixing minor problem from turbo landing. r/sr=ben
git-svn-id: svn://10.0.0.236/trunk@102724 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-11 01:18:18 +00:00
bienvenu%netscape.com
78db366c6b fix problem opening folders after imap connection cache is full and connections have timed out r=sspitzer, sr=mscott 99228
git-svn-id: svn://10.0.0.236/trunk@102723 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-11 01:17:36 +00:00
sonmi%netscape.com
e77c634b64 added debug info on linux failure (bad password certutil -K)
git-svn-id: svn://10.0.0.236/trunk@102721 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-11 01:10:46 +00:00
shrutiv%netscape.com
f4dee49d42 Fix for bug 83679: Ability to create customized Linux builds of N6.1+
Graying out feature (r=tao)


git-svn-id: svn://10.0.0.236/trunk@102720 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-11 01:08:15 +00:00
shrutiv%netscape.com
e385d9fdfc Fix for bug 83679: Ability to create customized Linux builds of N6.1+
Removing trimming of text for linux tar file edit field (r=tao)


git-svn-id: svn://10.0.0.236/trunk@102719 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-11 01:01:14 +00:00
sonmi%netscape.com
610f505129 workaround for BAckward compatibility failures (newly added test had
not been accounted for)
changed number of expected tests


git-svn-id: svn://10.0.0.236/trunk@102718 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-11 00:59:50 +00:00
jst%netscape.com
2ec1ee65c2 Fixing bug 98828. Cache a few nsSpaceManager objects to avoid spending 43%cvs ci -m ! of the time spent in PresShell::ProcessReflowCommand() in new and delete. r=dbaron@fas.harvard.edu, sr=waterson@netscape.com
git-svn-id: svn://10.0.0.236/trunk@102715 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-11 00:55:05 +00:00
shrutiv%netscape.com
d6ab1d171f Fix for bug 83679: Ability to create customized Linux builds of N6.1+
(r=tao)


git-svn-id: svn://10.0.0.236/trunk@102714 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-11 00:45:57 +00:00
dbaron%fas.harvard.edu
80b9856a97 Removing commented-out remnant of old hand-crafted nsIFactory implementation. b=97491 r=edburns sr=waterson
git-svn-id: svn://10.0.0.236/trunk@102713 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-11 00:42:52 +00:00
mscott%netscape.com
e8b9cb2e4b Bug #88315 --> fix the default selection for the auto complete widget
to make it match 4.x
r=ducarroz
sr=hewitt


git-svn-id: svn://10.0.0.236/trunk@102712 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-11 00:39:15 +00:00
leaf%mozilla.org
5fadd26caa change the trunk windows installer version to 0.9.4+, so trunk nightlies
don't over-write installed 0.9.4 installations. bug 98615, r=ssu, sr=mscott


git-svn-id: svn://10.0.0.236/trunk@102711 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-11 00:33:23 +00:00
syd%netscape.com
a489ccb294 Fix typo in last checkin, wanted "Quick Launch", not "QuickLaunch"
git-svn-id: svn://10.0.0.236/trunk@102709 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-11 00:17:32 +00:00
attinasi%netscape.com
c51c04dbab Fixed performance issue by restricting the cases in which we traverse up the frame tree looking for a containing block with a real computed height. b=85016 r=karnaze sr=waterson
git-svn-id: svn://10.0.0.236/trunk@102708 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-11 00:12:28 +00:00
bzbarsky%mit.edu
0f66a22500 Bug 74759. Make the default userChrome.css file have some useful
comments.  Also add a @namespace rule to make it be in the XUL
namespace.  r=rbs, sr=alecf.


git-svn-id: svn://10.0.0.236/trunk@102706 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-11 00:01:02 +00:00
syd%netscape.com
c9a24cde3f Fix for 88844. Turbo mode changes to installer. r=ssu, sr=blake, a=asa
git-svn-id: svn://10.0.0.236/trunk@102705 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-10 23:59:33 +00:00
shrutiv%netscape.com
47f20b90fa Fixing bug 83679: Ability to create customized Linux builds of N6.1+
Including Linux_page.ini in wizard (r=tao)


git-svn-id: svn://10.0.0.236/trunk@102704 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-10 23:58:38 +00:00
shrutiv%netscape.com
8fee20f5ef Bug 83679: Ability to create customized Linux builds of N6.1+
Adding .ini file for specifying platform information in wizard (r=tao)


git-svn-id: svn://10.0.0.236/trunk@102703 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-10 23:55:19 +00:00
blakeross%telocity.com
e46d7734bb (fixing license)
git-svn-id: svn://10.0.0.236/trunk@102702 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-10 23:51:55 +00:00
blakeross%telocity.com
cf77d7a48c Turbo landing:
- Turbo mode should run Mozilla from registry (88844). r=ccarlen sr=ben
- Systray menu for turbo should include components (89532). r=syd sr=ben
- Installer checkbox needs to turn turbo on properly (96936, 97338). r=ccarlen sr=ben
- Add 'Disable Quick Launch' menuitem to turbo systray icon (98770). r=syd sr=ben
- Need confirmation dialog when 'Disable Quick Launch' is selected (98805). r=syd sr=ben
- Show dialog when last window is closed in turbo mode (89166). r=ccarlen sr=ben

and some cleanup.


git-svn-id: svn://10.0.0.236/trunk@102701 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-10 23:48:09 +00:00
shrutiv%netscape.com
d3e1780457 Fix for bug 93159: Incorrect explanation under Browser Windows Title Bar
Text (r=tao)


git-svn-id: svn://10.0.0.236/trunk@102700 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-10 23:32:22 +00:00
danm%netscape.com
51fa80385a complain if callers try to unregister a null window (it was being done, and I got bushwhacked by it). bug 98792 r=alecf,ccarlen
git-svn-id: svn://10.0.0.236/trunk@102699 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-10 23:27:11 +00:00
danm%netscape.com
8a33dd4047 clean up use of nsAppShellService.UnregisterTopLevelWindow. bug 98792 r=alecf,ccarlen
git-svn-id: svn://10.0.0.236/trunk@102698 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-10 23:27:08 +00:00
mscott%netscape.com
f73c9721b9 Remove obsolete file from the build.
git-svn-id: svn://10.0.0.236/trunk@102697 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-10 23:19:06 +00:00
pschwartau%netscape.com
d531f59d48 Trivial whitespace cleanup.
git-svn-id: svn://10.0.0.236/trunk@102696 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-10 23:16:43 +00:00
leaf%mozilla.org
f699ef37a9 update user agent string and mac binary version, r=dveditz, sr=mscott, bug
93164


git-svn-id: svn://10.0.0.236/trunk@102695 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-10 23:11:09 +00:00
pschwartau%netscape.com
facd45d64c Initial add. Regression test for bug 97921.
git-svn-id: svn://10.0.0.236/trunk@102694 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-10 23:05:12 +00:00
jband%netscape.com
ed436aa174 Not part of the build - updating status page to reflect pavlov's great accomplishment. Also adding title attributes to <img> tags so that we can see the tip text on mozilla too.
git-svn-id: svn://10.0.0.236/trunk@102693 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-10 23:03:37 +00:00
alecf%netscape.com
7574047850 fix potential win32 bustage (thanks dbaron!)
git-svn-id: svn://10.0.0.236/trunk@102692 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-10 23:02:53 +00:00
alecf%netscape.com
3ae41e83f1 fix win32 bustage
git-svn-id: svn://10.0.0.236/trunk@102691 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-10 22:59:12 +00:00
mkaply%us.ibm.com
1571e688b7 #76856
Night of the Living Dead CVS files - rekilling files that got changes made after they were killed


git-svn-id: svn://10.0.0.236/trunk@102690 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-10 22:59:04 +00:00
nicolson%netscape.com
f93b61af9b Fix 95666: ImportDERPublicKey assigns CK_KEY_TYPE to pubkey->type.
git-svn-id: svn://10.0.0.236/trunk@102688 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-10 22:53:34 +00:00
shrutiv%netscape.com
e05d2e08e3 Fix for bug 7717: Cancel button should have confirm dialog (r=tao)
git-svn-id: svn://10.0.0.236/trunk@102687 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-10 22:51:55 +00:00
radha%netscape.com
009b995541 Removing a printf statement that I mistakenly included in the previous checkin. Got permission
from leaf to checkin this fix  with out  r and sr comments.


git-svn-id: svn://10.0.0.236/trunk@102686 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-10 22:47:17 +00:00
dougt%netscape.com
47e11a7754 fixes sending e-mail address as anonymous ftp passwd doesn't work. Patch submitted by jrgm@netscape.com, r=bbaetz, sr=me 57763
git-svn-id: svn://10.0.0.236/trunk@102685 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-10 22:31:34 +00:00
dsirnapalli%netscape.com
8b5873b2c8 Test case for nsIDocCharset interface.
git-svn-id: svn://10.0.0.236/trunk@102684 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-10 22:30:54 +00:00
hwaara%chello.se
0d935a86cc #94836, "Open Web Location' dialog needs cleanup [Open Address']". UI remake of the Open Web Location dialog. Now known as Open Address.
r=cmanske, sr=blake


git-svn-id: svn://10.0.0.236/trunk@102683 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-10 22:30:53 +00:00
waldemar%netscape.com
90addddd67 Added support for list-sets, some, and every. Removed tuple and record tags. Made many minor semantic notation improvements.
git-svn-id: svn://10.0.0.236/trunk@102681 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-10 22:10:36 +00:00
sonmi%netscape.com
f094b6d884 fixed 2 problems with local QA, right usage information and
absolute PATHS in NT understood as well now


git-svn-id: svn://10.0.0.236/trunk@102680 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-10 22:09:29 +00:00
rginda%netscape.com
47c65ebd0c - venkman only -
increase max string display length


git-svn-id: svn://10.0.0.236/trunk@102679 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-10 22:07:23 +00:00
blakeross%telocity.com
e447b81207 Updating the license that I intended for this file. r/sr=ben
git-svn-id: svn://10.0.0.236/trunk@102678 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-10 22:05:17 +00:00
edburns%acm.org
0e646abf4f 99099
r=ashuk
a=edburns
This bug fix uses os.name as the way to tell platform.


git-svn-id: svn://10.0.0.236/trunk@102676 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-10 22:02:05 +00:00
sonmi%netscape.com
a73d4719ac fixed a problems related to bug 96758 (typo in variable name)
and added comment about weird behavior and weirder solution


git-svn-id: svn://10.0.0.236/trunk@102675 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-10 21:55:52 +00:00
cmanske%netscape.com
235234e482 Check if HTML Source has been edited when loading into existing Composer window, b=98768, r=syd, sr=kin
git-svn-id: svn://10.0.0.236/trunk@102674 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-10 21:50:12 +00:00
sonmi%netscape.com
0c77c1a0d4 changed behavior so rsh is not necessary anymore
git-svn-id: svn://10.0.0.236/trunk@102670 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-10 21:30:26 +00:00
sonmi%netscape.com
b0edf43591 trieing again, the same change as a week ago, setting TMPDIR and TEMP
to the HOSTDIR as well


git-svn-id: svn://10.0.0.236/trunk@102669 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-10 21:29:29 +00:00
harishd%netscape.com
8badc43252 98645 - Added SELECT to the set of tags that cannot be crossed over when an end tag ( block-level ) tries to close it's matching open tag on the stack. r=heikki, sr=vidur
git-svn-id: svn://10.0.0.236/trunk@102668 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-10 21:29:27 +00:00
sonmi%netscape.com
e191084d3d added perl to the HP path
git-svn-id: svn://10.0.0.236/trunk@102667 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-10 21:27:13 +00:00
gerv%gerv.net
86fd0a166e Make Bugzilla support <link> tag for buglists. Bug 87818. r=jake, caillon.
git-svn-id: svn://10.0.0.236/trunk@102665 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-10 21:26:05 +00:00
alecf%netscape.com
d0766d027e add REQUIRES support to jpeg, sun-java, db, etc.. b=98371 r=cls
git-svn-id: svn://10.0.0.236/trunk@102664 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-10 20:48:38 +00:00
blakeross%telocity.com
6ba15f6554 App hangs sometimes when scrolling addressbook panel (99121). r=varada,hwaara sr=sspitzer
git-svn-id: svn://10.0.0.236/trunk@102663 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-10 20:47:24 +00:00
alecf%netscape.com
7e8f1eff5d add REQUIRES support to layou, content, gfx, gfx2, widget and modules/libpr0n b=98371 r=cls
git-svn-id: svn://10.0.0.236/trunk@102662 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-10 20:46:52 +00:00
alecf%netscape.com
35cb5d6fd3 add REQUIRES support to mailnews b=98371 r=cls
git-svn-id: svn://10.0.0.236/trunk@102661 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-10 20:42:53 +00:00
mscott%netscape.com
d7d4a08c64 Bug # 98846 --> fix a leak of a nsFileSpec object.
r=naving, hawara
sr=sspitzer


git-svn-id: svn://10.0.0.236/trunk@102659 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-10 20:16:48 +00:00
alecf%netscape.com
d59c272cc0 add REQUIRES support to intl
b=98371 r=cls


git-svn-id: svn://10.0.0.236/trunk@102658 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-10 20:03:25 +00:00
dbaron%fas.harvard.edu
d042c2ddb4 Replace uses of deprecated NS_IMPL_ISUPPORTS and NS_IMPL_QUERYINTERFACE macros with NS_IMPL_{ISUPPORTS,QUERYINTERFACE}{1,0}. r=jag sr=alecf b=45797
git-svn-id: svn://10.0.0.236/trunk@102656 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-10 19:54:27 +00:00
dbaron%fas.harvard.edu
fdc3365574 Clean up nsIAppShellService.idl. b=98026 r=danm sr=alecf
git-svn-id: svn://10.0.0.236/trunk@102655 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-10 19:42:54 +00:00
dbaron%fas.harvard.edu
3513e49a5e Change NS_SUCCEEDED check to null-check since GetDocument may return a null document. r=jag sr=waterson b=99056
git-svn-id: svn://10.0.0.236/trunk@102654 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-10 19:39:25 +00:00
dbaron%fas.harvard.edu
dd62233a09 Null check to fix topcrash bug 97226. r=hixie sr=waterson
git-svn-id: svn://10.0.0.236/trunk@102653 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-10 19:36:59 +00:00
axel%pike.org
a826b8c933 bug 98704, xml/dom part of beating DOMHelper::getParentNode out of the tree, r=peterv, rs=brendan
git-svn-id: svn://10.0.0.236/trunk@102651 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-10 18:01:23 +00:00
jake%acutex.net
5c859df96e Fix for bug 76140 - Adding some more sanity checks.
Patch by Matthew Tuck <matty@chariot.net.au>
r= caillon@returnzero.com, jake@acutex.net


git-svn-id: svn://10.0.0.236/trunk@102650 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-10 15:20:11 +00:00
jake%acutex.net
e9503eff4f Fix for bug 97657 - in defparams.pl, the sillyness sub should be called defparams_pl_sillyness
Patch by David D. Kilzer <ddkilzer@theracingworld.com>
r= jake@acutex.net


git-svn-id: svn://10.0.0.236/trunk@102649 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-10 14:57:12 +00:00
beard%netscape.com
54bebf1f06 [not part of build] Changed MIME type to be compatible with windows plugin.
git-svn-id: svn://10.0.0.236/trunk@102648 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-10 14:56:47 +00:00
beard%netscape.com
cdfc1133b9 Added version attribute to nsI4xScriptablePlugin.idl.
git-svn-id: svn://10.0.0.236/trunk@102647 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-10 14:56:04 +00:00
kin%netscape.com
08f0c16feb Fix for bug 98018: Impossible to delete text in textbox
nsEditor::CreateTxnForDeleteInsertionPoint() shouldn't
use count-1 when calculating isLast, in the non-text case.

r=jfrancis@netscape.com  sr=sfraser@netscape.com


git-svn-id: svn://10.0.0.236/trunk@102646 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-10 14:46:57 +00:00
jake%acutex.net
e2de88b45f Fix for bug 71664 - Don't complain about a bad keyword cache for a bug that doesn't exist.
Patch by Matthew Tuck <matty@chariot.net.au>
r= afranke@ags.uni-sb.de, jake@acutex.net


git-svn-id: svn://10.0.0.236/trunk@102645 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-10 14:12:10 +00:00
jake%acutex.net
5aa31d5f98 Fix for bug 95060 - Correct the instructions on how to view your current votes.
Patch by Gavin Shelley <gavins@iplbath.com>
r= jake@acutex.net x2


git-svn-id: svn://10.0.0.236/trunk@102644 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-10 14:00:48 +00:00
jake%acutex.net
866f721d34 Fix for bug 8647 - Add an option to the query page to sort by Last Changed date.
Patch by Matthew Tuck <matty@chariot.net.au>
r= jake@acutex.net x2


git-svn-id: svn://10.0.0.236/trunk@102643 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-10 13:49:26 +00:00
brade%netscape.com
763d8c555c not in the build
git-svn-id: svn://10.0.0.236/trunk@102642 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-10 13:16:45 +00:00
kaie%netscape.com
844e15ee2e b=96018 r=jag
Fix wrong attribute name introduced by checkin on Friday


git-svn-id: svn://10.0.0.236/trunk@102640 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-10 11:50:11 +00:00
mcafee%netscape.com
07ffa554fe po/ChangeLog hack, for gettext bug
git-svn-id: svn://10.0.0.236/trunk@102639 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-10 09:07:29 +00:00
ben%netscape.com
17f0c9d48f Add some more code to the prototype resizable popup binding. Not complete yet, but unused.
Part of fix for 95401 - implement resizable popups.
r=jag, sr=hyatt


git-svn-id: svn://10.0.0.236/trunk@102638 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-10 07:35:56 +00:00
ben%netscape.com
cbf8597d4f Add implementation for MoveTo method to nsMenuPopupFrame (exposed through nsIPopupBoxObject), etc.
Also change static mDismissalListener to sDismissalListener.
Part of fix for 95401
r=jag, sr=hyatt


git-svn-id: svn://10.0.0.236/trunk@102637 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-10 07:34:54 +00:00
ben%netscape.com
558801a6ac Add |sizeTo| and |moveTo| methods to nsIPopupBoxObject, allow popups to have their automatic rollup, keyboard navigator and auto positioning functionality disabled.
Part of fix for 95401.
r=jag, sr=hyatt


git-svn-id: svn://10.0.0.236/trunk@102636 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-10 07:33:33 +00:00
ben%netscape.com
15f9cf3f0e Add implementation for left, top, persist, ref, and datasources attributes on nsIDOMXULElement per XUL1.0 spec.
Part of fix for 95401 - implement resizable popups.
r=jag, sr=hyatt


git-svn-id: svn://10.0.0.236/trunk@102635 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-10 07:32:20 +00:00
ben%netscape.com
8e75312333 Add left, top, persist, ref, and datasources attributes to nsIDOMXULElement per XUL1.0 spec.
Part of fix for 95401 - implement resizable popups.
r=jag, sr=hyatt


git-svn-id: svn://10.0.0.236/trunk@102634 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-10 07:31:38 +00:00
leaf%mozilla.org
9026810a2f Automated update
git-svn-id: svn://10.0.0.236/trunk@102633 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-10 05:28:42 +00:00
cls%seawood.org
373451a083 Install LDAP headers into seperate ldap include dir.
Bug #98924 r=dmose


git-svn-id: svn://10.0.0.236/trunk@102632 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-10 05:17:41 +00:00
leaf%mozilla.org
53e59756d4 Automated update
git-svn-id: svn://10.0.0.236/trunk@102631 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-10 05:13:43 +00:00
cls%seawood.org
85334dd439 If building for 64bit target, pass --enable-64bit to NSPR as it does not do 64bit-autodetection. r=pavlov
git-svn-id: svn://10.0.0.236/trunk@102630 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-10 04:58:38 +00:00
dougt%netscape.com
81ae60cfe7 fixes 98735. r=adamlock, sr=rpotts. Basic problem is that the first argument of NS_InitXPCOM2 was not returning an nsIServiceManager
git-svn-id: svn://10.0.0.236/trunk@102628 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-10 04:28:37 +00:00
mcafee%netscape.com
ad12d36dff Fixing some logic errors
git-svn-id: svn://10.0.0.236/trunk@102627 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-10 03:27:27 +00:00
jaggernaut%netscape.com
a86e757d5f Add "exthandler" and "mimetype" to REQUIRES line for dependency tracking builds.
git-svn-id: svn://10.0.0.236/trunk@102626 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-10 02:07:52 +00:00
oeschger%netscape.com
1f5fa2a738 adding help key for content updates, a=asa, bug=85925, r=cotter
git-svn-id: svn://10.0.0.236/trunk@102625 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-10 00:55:46 +00:00
darin%netscape.com
29bd0e8f8d backing out patch for bug 97528 due to regression/smoketest-blocker bug 98838.
git-svn-id: svn://10.0.0.236/trunk@102624 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-10 00:42:50 +00:00
ian%hixie.ch
d8bb2290c9 First stab at an e-mail output service. Also added support for checking addresses for validity and used that when creating a new account.
git-svn-id: svn://10.0.0.236/trunk@102623 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-09 21:02:33 +00:00
jfrancis%netscape.com
c52350e6b5 fixes 98543: backspace/delete was crossing table structure boundaries. Also fixed other flavors of this bug that had not been discovered yet.
r=fm; sr=kin


git-svn-id: svn://10.0.0.236/trunk@102622 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-09 20:57:46 +00:00
zach%zachlipton.com
ca5d6d78c2 Oops. Forgot to check this is.
git-svn-id: svn://10.0.0.236/trunk@102621 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-09 19:48:15 +00:00
ian%hixie.ch
f2c4a72d49 Reduced the ErrorContext from 2 to 1. 2 is too much.
git-svn-id: svn://10.0.0.236/trunk@102620 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-09 19:48:14 +00:00
ian%hixie.ch
e4abc2ef8a corrected a comment, corrected the spelling of a method call, and added a placeholder in 'login.failed' which will eventually have to be replaced by code which finds the list of contact methods.
git-svn-id: svn://10.0.0.236/trunk@102619 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-09 19:47:04 +00:00
ian%hixie.ch
447d63ebe4 Added ErrorContext to the Expat arguments so that well formedness errors are easier to track down.
git-svn-id: svn://10.0.0.236/trunk@102618 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-09 19:38:24 +00:00
ian%hixie.ch
06727db199 Corrected and improved some comments.
Corrected a problem with scope and the 'escape' attribute of <text> elements.
Renamed 'shrink' and 'expand' to the slightly more accurate 'flatten' and 'rounden'. (ahem)
Changed the ordering of symbol unescaping in roundening to be less (not?) susceptible to incorrect expansion.
Changed the ordering of symbol escaping in flattening to be consistent with the unescape order when roundening.
Made <text> trim one leading and one trailing newline in text nodes if xml:space="default" (makes COSES files neater).
Added a 'coses: original keys' hash to values whose keys are sanitised
Made the 'escape' values be lower case instead of upper case (makes COSES files neater).


git-svn-id: svn://10.0.0.236/trunk@102617 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-09 19:36:23 +00:00
ian%hixie.ch
bf75d78321 Corrected the SQL for 'SHOW COLUMNS FROM' so that it actually works...
git-svn-id: svn://10.0.0.236/trunk@102616 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-09 19:21:17 +00:00
ian%hixie.ch
67dc277de0 Added a string data source which gets the strings from a file instead of from the database, useful as a fallback.
git-svn-id: svn://10.0.0.236/trunk@102615 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-09 19:19:05 +00:00
ian%hixie.ch
8c9220bbac Made the error message printed when no string expander can be found more explicit (it now mentions the name and type of the string).
git-svn-id: svn://10.0.0.236/trunk@102614 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-09 19:08:58 +00:00
ian%hixie.ch
37f35ccfe7 Added a comment clarification.
git-svn-id: svn://10.0.0.236/trunk@102613 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-09 19:06:13 +00:00
ian%hixie.ch
d14ad445fd Changed the magic piping array so that it is more consistent by removing the special casing of when there is only one return value.
git-svn-id: svn://10.0.0.236/trunk@102612 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-09 19:04:37 +00:00
ian%hixie.ch
03f038f0c1 Added the message level number to the debug output to help gauge what level is useful.
git-svn-id: svn://10.0.0.236/trunk@102611 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-09 17:55:21 +00:00
ian%hixie.ch
c6af0b8abd Added header and stylistic note.
Clarified some of the text.
Made the use of quotes more consistent.
Wrote Chapter 5, "USING GET SERVICE".
Added an empty Chapter 10, "THE SERVICE REFERENCE".


git-svn-id: svn://10.0.0.236/trunk@102610 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-09 17:48:07 +00:00
sicking%bigfoot.com
f9ef17c1ea Fix bustage. gcc dosn't like function-results used as non-const argument.
git-svn-id: svn://10.0.0.236/trunk@102609 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-09 17:02:15 +00:00
sicking%bigfoot.com
6cafa71f04 Implement xsl:import. This dosn't implement any import precedence but gives us the infrastructure to do so.
b=78068 r=peterv sr=shaver


git-svn-id: svn://10.0.0.236/trunk@102608 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-09 16:09:57 +00:00
bernd.mielke%snafu.de
485411b457 Adding xhtml table testfiles to the regression tests not part of the build
git-svn-id: svn://10.0.0.236/trunk@102607 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-09 14:27:52 +00:00
jaggernaut%netscape.com
a1b3647d73 Bug 73353: clean up REQUIRES. r=cls
git-svn-id: svn://10.0.0.236/trunk@102606 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-09 13:36:07 +00:00
cls%seawood.org
3268fb198e Set MODULE so that headers are grouped properly.
git-svn-id: svn://10.0.0.236/trunk@102604 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-09 07:43:48 +00:00
jaggernaut%netscape.com
f6fb205f3f Bug 97328: switch XPIDL from nsAReadableString (and nsAWritableString) to const nsAString. r=cls, sr=shaver
git-svn-id: svn://10.0.0.236/trunk@102603 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-09 07:17:17 +00:00
mkaply%us.ibm.com
eee9fc790b #98387
OS/2 only
Use getopt from mac LDAP so we can get rid of GPLed code


git-svn-id: svn://10.0.0.236/trunk@102601 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-08 22:37:24 +00:00
mcafee%netscape.com
0a62606bf3 Backing out my change to avoid pulling by date on branches, my assertion that this didn't work was incorrect. thanks to cls for figuring this out.
git-svn-id: svn://10.0.0.236/trunk@102600 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-08 22:31:24 +00:00
dp%netscape.com
ad73acbae3 Fixing build bustage.
git-svn-id: svn://10.0.0.236/trunk@102599 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-08 22:01:22 +00:00
bzbarsky%mit.edu
198ed50ec9 Bug 98663. Make Presshell not call InsertRule() on strings that contain
multiple rules.  r=dbaron, sr=attinasi


git-svn-id: svn://10.0.0.236/trunk@102598 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-08 21:42:02 +00:00
cls%seawood.org
3ca2a3f334 Set MOZILLA_FIVE_HOME to use $binary dir on each loop
git-svn-id: svn://10.0.0.236/trunk@102597 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-08 21:37:06 +00:00
dp%netscape.com
eb731f9c5d bug# 98786 Eliminating url cloning r=gagan,sr=jst
git-svn-id: svn://10.0.0.236/trunk@102596 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-08 21:13:20 +00:00
attinasi%netscape.com
e2f7d9afcc Tweaked the existing CalcQuirkContainingBlockHeight method to allows for percentage based elements in deeply nested blocks, instead of just elements that are directly in the BODY. b=85016 r=karnaze sr=waterson
git-svn-id: svn://10.0.0.236/trunk@102595 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-08 20:09:08 +00:00
attinasi%netscape.com
82570cc02b Fix for image wrapping problems in table cells. b=97619 r=bernd sr=waterson
git-svn-id: svn://10.0.0.236/trunk@102594 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-08 19:26:34 +00:00
cls%seawood.org
25625e84ea Replace cat<<EOF with echos to avoid potential security risk with predictable /tmp files.
Thanks to Ashu Kulkarni <ashuk@eng.sun.com> for the patch.
Bug #98723 r=cls a=blizzard


git-svn-id: svn://10.0.0.236/trunk@102593 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-08 19:16:27 +00:00
pschwartau%netscape.com
f12f5af680 Trivial change to comment and whitespace.
git-svn-id: svn://10.0.0.236/trunk@102592 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-08 18:58:40 +00:00
dbaron%fas.harvard.edu
e59c2701d9 Make forward-compatible the DOCTYPE handling for determining whether to be in quirks mode or strict mode: properly parse the DOCTYPE declaration and use a list of known public identifiers that should trigger quirks. Remove some remnants of modes that no longer exist. b=55264 r=harishd sr=vidur
git-svn-id: svn://10.0.0.236/trunk@102591 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-08 18:37:19 +00:00
dbaron%fas.harvard.edu
0998d9523b Move trace-malloc readers from mozilla/xpcom/base/ to mozilla/tools/trace-malloc/. Add a --shutdown-leaks option to nsTraceMalloc to dump, to the file given as an argument to the option, information about allocations still live at shutdown. Add a new trace-malloc reader (leakstats.c) to print leak statistics. b=84831 r=jag sr=brendan
git-svn-id: svn://10.0.0.236/trunk@102590 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-08 18:29:24 +00:00
aaronl%netscape.com
7df41cc87e Reversing 82207 patch - mac problems.
git-svn-id: svn://10.0.0.236/trunk@102589 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-08 17:05:09 +00:00
aaronl%netscape.com
d45d392f62 Bug 82207. XUL Checkbox working with MSAA. r=jgaunt, sr=hyatt
git-svn-id: svn://10.0.0.236/trunk@102588 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-08 16:22:09 +00:00
andreas.otte%primus-online.de
306f3914a2 fix bug 94796 [code cleanup in nsURLHelper.cpp] remove nsURLEscape/nsURLUnescape from nsURLHelper and replace all usage with nsStdEscape/nsStdUnescape, r=ccarlen@netscape.com, sr=dougt@netscape.com
git-svn-id: svn://10.0.0.236/trunk@102586 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-08 12:47:05 +00:00
cls%seawood.org
15b3554227 AIX linker requires that all symbols be resolved at link time so link against MOZ_COMPONENT_LIBS when building shared lib. Should fix tinderbox bustage.
git-svn-id: svn://10.0.0.236/trunk@102585 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-08 08:09:14 +00:00
leaf%mozilla.org
9fb6641e49 Automated update
git-svn-id: svn://10.0.0.236/trunk@102584 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-08 07:58:42 +00:00
cls%seawood.org
0e7879c814 Remove -DMOZ_MAIL_NEWS from build system.
Bug #66543 r=pavlov


git-svn-id: svn://10.0.0.236/trunk@102583 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-08 07:44:13 +00:00
cls%seawood.org
2f251f476b Updating module dependencies
git-svn-id: svn://10.0.0.236/trunk@102582 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-08 07:40:14 +00:00
blizzard%redhat.com
f2df3f8b5c Rewrite XRemote code. It sucks less now. Fixes bugs 62250, 66543, 84239, 89911, 90580, 94289, 98764. r=jag, sr=alecf
git-svn-id: svn://10.0.0.236/trunk@102581 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-08 05:08:13 +00:00
blizzard%redhat.com
64c08dd915 Fix bug #98600. Handle the return of NS_ERROR_NO_CONTENT in the URI loader. mailto: urls shouldn't assert now. r=rpotts, sr=mscott
git-svn-id: svn://10.0.0.236/trunk@102580 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-08 04:58:59 +00:00
cotter%netscape.com
8aadb7f32b revised Show Example bitmaps
git-svn-id: svn://10.0.0.236/trunk@102579 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-08 04:27:13 +00:00
cotter%netscape.com
b9a9d25ffe privacy & security help content updates per b=85925, for new reset master password dialog (b=96019) and related changes. a=asa, r=oeschger
git-svn-id: svn://10.0.0.236/trunk@102578 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-08 04:22:47 +00:00
mkaply%us.ibm.com
6a345da4df OS/2 and AIX bustage - use path.get()
Fix from dbaron
And since I am in here, I'm removing the IBM spam


git-svn-id: svn://10.0.0.236/trunk@102577 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-08 02:53:31 +00:00
mkaply%us.ibm.com
89f9578c8e Remove C++ style comment to fix OSF bustage
git-svn-id: svn://10.0.0.236/trunk@102576 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-08 02:46:22 +00:00
kaie%netscape.com
59964b4cc2 oops, fixing code per bug 96018
r=jag


git-svn-id: svn://10.0.0.236/trunk@102575 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-08 02:24:27 +00:00
nicolson%netscape.com
158dec054e More work on running an SSLSocket over a generic Socket. This is required
for JSSE compliance.


git-svn-id: svn://10.0.0.236/trunk@102574 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-08 01:53:38 +00:00
jaggernaut%netscape.com
5002e73042 Removing newlines (^M) to fix bustage.
git-svn-id: svn://10.0.0.236/trunk@102573 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-08 01:47:44 +00:00
naving%netscape.com
682421a488 fix whitespace from last checkin
git-svn-id: svn://10.0.0.236/trunk@102572 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-08 01:12:36 +00:00
sspitzer%netscape.com
727e138a05 fix for #98793. r=varada, sr=mscott. pre-cache the unread / read / flagged / unflagged thread pane images
so that they don't fail to show when you launch mail (because of bug #92512)


git-svn-id: svn://10.0.0.236/trunk@102571 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-08 01:09:18 +00:00
av%netscape.com
d07e1e546f Fix for bug 98285 -- adding possibility for plugins to access the service manager, r=beard, sr=vidur
git-svn-id: svn://10.0.0.236/trunk@102570 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-08 01:04:03 +00:00
jst%netscape.com
21fc764dbf Comment change only, sr=me
git-svn-id: svn://10.0.0.236/trunk@102569 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-08 00:53:38 +00:00
kaie%netscape.com
d943972f0f b=96018 r=ddrinan sr=blake
New "Reset Master Password" functionality, for users who have forgotten their password.


git-svn-id: svn://10.0.0.236/trunk@102568 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-08 00:52:21 +00:00
kaie%netscape.com
39c6379c87 b=96018 r=ddrinan sr=blake
New "Reset Master Password" functionality, for users who have forgotten their password.


git-svn-id: svn://10.0.0.236/trunk@102567 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-08 00:44:39 +00:00
naving%netscape.com
b8d8cdd0c1 98391 98470 r=bienvenu sr=sspitzer. Make rename folder work again for folders having
subfolders. Also make filters work for a local folder whose parent is renamed.


git-svn-id: svn://10.0.0.236/trunk@102566 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-08 00:40:05 +00:00
despotdaemon%netscape.com
bafa37bfb2 Pseudo-automatic update of changes made by mhein@netscape.com.
git-svn-id: svn://10.0.0.236/trunk@102565 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-08 00:31:21 +00:00
av%netscape.com
8d0ac39f1b Fix for bug 98285 -- added a new value to the NPNVariable enum type to enable access to the service manager from plugins, r=beard, sr=vidur
git-svn-id: svn://10.0.0.236/trunk@102564 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-08 00:23:07 +00:00
vidur%netscape.com
381f948d15 Fix for bug 98597. The event held onto from the document's load handler was bogus by the time we sent it to the XMLHttpRequest's event listeners (DOM events have members that are stack-based and, despite being reference-counted objects, should not be held across a call. Instead we create a new event of our own for the XMLHttpRequest load. r=heikki, sr=jst
git-svn-id: svn://10.0.0.236/trunk@102563 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-08 00:18:45 +00:00
vidur%netscape.com
44736581ad Part of fix for bug 98597. Null checks so that accessing properties on a DOM event without an underlying PresContext doesn't crash. r=heikki, sr=jst
git-svn-id: svn://10.0.0.236/trunk@102562 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-08 00:16:04 +00:00
dp%netscape.com
4869247c4f bug# 96457 Fixing ReInit() to account for the new factory entry type
r=gagan, sr=jband


git-svn-id: svn://10.0.0.236/trunk@102561 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-08 00:01:03 +00:00
danm%netscape.com
826be1b5f2 restoring rev 1.11 (bug 97514 r=hyatt,pchen). the root cause of bug 98732 (and rev 1.12) has been fixed elsewhere (bug 98785).
git-svn-id: svn://10.0.0.236/trunk@102560 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-07 23:38:06 +00:00
danm%netscape.com
301323f895 restoring rev 1.159 (bug 97514 r=hyatt,pchen). the root cause of bug 98732 (and rev 1.160) has been fixed elsewhere (bug 98785).
git-svn-id: svn://10.0.0.236/trunk@102559 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-07 23:37:16 +00:00
danm%netscape.com
c2fbecce04 now _blank windows without a parent will actually open in a new window. wow. bugs like that shouldn't still exist. bug 98785 r=hyatt,rpotts
git-svn-id: svn://10.0.0.236/trunk@102558 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-07 23:24:34 +00:00
tao%netscape.com
b3adefd3b5 71517: Dynamically select platform jar in langxxxx.xpi.
(r=jbetak,sr=mscott). Build en-{win,unix}.jar on Mac.


git-svn-id: svn://10.0.0.236/trunk@102556 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-07 22:45:31 +00:00
darin%netscape.com
5ef7161975 mac project changes for bug 97528
git-svn-id: svn://10.0.0.236/trunk@102555 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-07 22:37:38 +00:00
darin%netscape.com
66747c911f fixes bug 97528 "1200 urls created on startup about:blank"
r=dp, sr=dougt


git-svn-id: svn://10.0.0.236/trunk@102554 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-07 22:32:50 +00:00
shanjian%netscape.com
9a550abb76 #90581 Cyrillic is not autodetected by nsIStringCharsetDetector
r= roy, sr=waterson


git-svn-id: svn://10.0.0.236/trunk@102553 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-07 22:28:38 +00:00
heikki%netscape.com
cd37d0dbd3 Not part of build. Test more stuff.
git-svn-id: svn://10.0.0.236/trunk@102552 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-07 22:09:06 +00:00
radha%netscape.com
cb733e6f90 Fix for bug 79063 r=rpotts sr=darin
git-svn-id: svn://10.0.0.236/trunk@102551 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-07 22:06:08 +00:00
cavin%netscape.com
a2c859066d Bug #98294: In nsImapService::DiscoverChildren(), make sure we have a consistent server hierarchy delimiter. r=sspitzer, sr=mscott.
Bug #98433: In nsImapService::GetListOfFoldersWithPath(), if the folder path contains 'INBOX' of any forms, we need to convert it to uppercase before finding it under the root folder. r=naving, sr=mscott.


git-svn-id: svn://10.0.0.236/trunk@102550 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-07 21:55:38 +00:00
rangansen%netscape.com
ef69772aa4 b=94026 r=rangansen sr=hewitt a=asa Changing UI string
git-svn-id: svn://10.0.0.236/trunk@102549 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-07 21:39:13 +00:00
svn%xmlterm.org
5ef4cb6e35 --NOT PART OF DEFAULT BUILD--
XMLterm changes only.
Major restructuring of the xmlterm build process. Split lineterm from xmlterm.
IDLified all interfaces (bug 69002). Eliminated printing to console in opt
builds (bug 78641)


git-svn-id: svn://10.0.0.236/trunk@102548 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-07 21:33:32 +00:00
rjesup%wgate.com
02ba8117de Bug 93999: 1-liner fix to unhork xlib (fix to typo by imot). r/sr=blake
via IRC


git-svn-id: svn://10.0.0.236/trunk@102547 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-07 21:32:54 +00:00
sonmi%netscape.com
bf5ff59388 took some machines out that are not in the commonly used environment now
git-svn-id: svn://10.0.0.236/trunk@102546 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-07 21:28:08 +00:00
sonmi%netscape.com
dbea0f6dea changes to eliminate the need for tortoise
git-svn-id: svn://10.0.0.236/trunk@102545 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-07 21:27:17 +00:00
sonmi%netscape.com
c41caab5bc changes reflecting the RE build area move
git-svn-id: svn://10.0.0.236/trunk@102544 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-07 21:25:16 +00:00
sonmi%netscape.com
be509fc071 added information about OS to the .nssqa file
git-svn-id: svn://10.0.0.236/trunk@102543 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-07 21:24:43 +00:00
sonmi%netscape.com
72130b9970 changed masterbuild etc. to reflect RE changes
git-svn-id: svn://10.0.0.236/trunk@102542 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-07 21:23:23 +00:00
mitesh%netscape.com
ca72868cd3 Fix for the regression caused by bug 92447
movinf request for the nsPrefService out of Init()
r=bnesse and sr=alecf


git-svn-id: svn://10.0.0.236/trunk@102540 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-07 21:12:41 +00:00
bryner%netscape.com
cbfe25d575 Bug 42313 - unable to scroll over iframes with mousewheel. We now
correctly bubble up the scroll to the parent document if the iframe is
unable to scroll (either because it isn't scrollable, or because we're
already at the top/bottom of it).  r=saari, sr=hyatt.


git-svn-id: svn://10.0.0.236/trunk@102539 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-07 21:00:57 +00:00
sspitzer%netscape.com
841c0f5106 remove ^Ms for varada. no bug. rs=bienvenu
git-svn-id: svn://10.0.0.236/trunk@102538 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-07 20:58:16 +00:00
sspitzer%netscape.com
e9470a3d39 backing out danm's changes for #97514, as they cause the regression bug #98732
a=heikki


git-svn-id: svn://10.0.0.236/trunk@102536 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-07 19:29:43 +00:00
wtc%netscape.com
99b1973ff0 Bugzilla bug 98741: replaced NPL by MPL/GPL.
Modified files: prerr.et prmkdir.bat pr/src/md/os2/objs.mk


git-svn-id: svn://10.0.0.236/trunk@102535 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-07 18:37:58 +00:00
wtc%netscape.com
11f1593318 Bugzilla bug 98741: removed the extra NPL header.
git-svn-id: svn://10.0.0.236/trunk@102534 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-07 18:28:31 +00:00
wtc%netscape.com
5b8e1cf962 Bugzilla bug 98741: changed the license URL to http://www.mozilla.org/MPL/.
Modified Files:
	pr/src/prvrsion.c lib/ds/plvrsion.c lib/libc/src/plvrsion.c
	lib/prstreams/plvrsion.c


git-svn-id: svn://10.0.0.236/trunk@102533 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-07 18:27:33 +00:00
locka%iol.ie
aecb361ff6 Fix for fallout in embedding from component/service manager merge. b=98721 r=ccarlen@netscape.com sr=blizzard@mozilla.org
git-svn-id: svn://10.0.0.236/trunk@102532 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-07 18:05:50 +00:00
beard%netscape.com
ad548ee4ed [not part of build] Mac files for scriptable NPAPI plugin.
git-svn-id: svn://10.0.0.236/trunk@102529 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-07 15:54:40 +00:00
jaggernaut%netscape.com
4847353edd Bug 97571: Any <label> in <groupbox> becomes <caption> per XUL 1.0. r=ben, sr=hyatt
git-svn-id: svn://10.0.0.236/trunk@102528 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-07 14:23:21 +00:00
kaie%netscape.com
e5381ddaba b=87578 r=ssaux sr=blizzard
Changing one word in a user interface string


git-svn-id: svn://10.0.0.236/trunk@102527 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-07 14:23:19 +00:00
kaie%netscape.com
ec46d5529a b=97571 r=ben sr=hyatt
Checking in for jag


git-svn-id: svn://10.0.0.236/trunk@102526 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-07 14:19:18 +00:00
mkaply%us.ibm.com
1f4cc8ef09 #94055
r=saari, sr=blizzard
Make OS/2 go down WIN32 only #ifdef as well to fix tabbing issues


git-svn-id: svn://10.0.0.236/trunk@102525 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-07 12:19:55 +00:00
cls%seawood.org
86c34d2c2b Adding newline to end of file to fix hpux bustage
git-svn-id: svn://10.0.0.236/trunk@102524 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-07 11:00:48 +00:00
pavlov%netscape.com
699a6c2a09 fix for table 64bit lameness. bug 98686. r=gisburnd sr=jst
git-svn-id: svn://10.0.0.236/trunk@102522 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-07 09:58:16 +00:00
peterv%netscape.com
8da59ee228 Implement TreeWalker in DOM2-traversal.
b=82625, r=fabian, sr=jst


git-svn-id: svn://10.0.0.236/trunk@102521 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-07 09:32:00 +00:00
sicking%bigfoot.com
1f749a9c7d Implement TreeWalker in DOM2-traversal.
b=82625, r=fabian, sr=jst


git-svn-id: svn://10.0.0.236/trunk@102520 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-07 09:30:03 +00:00
cls%seawood.org
70e416b21b Update dependencies to handle static libs used by installer
git-svn-id: svn://10.0.0.236/trunk@102519 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-07 08:04:13 +00:00
cls%seawood.org
27a923b30f The AIX compiler cannot handle string literals inside of a triconditional statement so use named literals instead.
Thanks to David Baron <dbaron@fas.harvard.edu> for the patch.
Fixing tinderbox bustage.


git-svn-id: svn://10.0.0.236/trunk@102518 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-07 07:33:15 +00:00
despotdaemon%netscape.com
aa914a892c Pseudo-automatic update of changes made by jshin@pantheon.yale.edu.
git-svn-id: svn://10.0.0.236/trunk@102517 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-07 05:29:23 +00:00
leaf%mozilla.org
1b52bcee42 Automated update
git-svn-id: svn://10.0.0.236/trunk@102516 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-07 05:13:43 +00:00
cls%seawood.org
6c600f25bf Remove unused fullcircle build references.
Bug #98293 r=namachi


git-svn-id: svn://10.0.0.236/trunk@102515 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-07 04:59:44 +00:00
markh%activestate.com
01db5ffb50 Fix bug in makefile when building from Python binaries rather than Python sources
Not part of the build.


git-svn-id: svn://10.0.0.236/trunk@102514 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-07 04:52:06 +00:00
jst%netscape.com
ab462ac543 Fixing bug 98292. Adding support for image.x and image.y for compatibility with NS4.x, r=jrgm@netscape.com, sr=blizzard@mozilla.org
git-svn-id: svn://10.0.0.236/trunk@102511 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-07 04:00:37 +00:00
jaggernaut%netscape.com
3cec579db1 Bug 93071: Incorrect test in UnregisterComponent: we want to unregister if the registry name matches. r=bryner, sr=shaver
git-svn-id: svn://10.0.0.236/trunk@102510 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-07 03:48:37 +00:00
rjesup%wgate.com
0202c4da49 Bug 96710: (try 2). Right() takes number-of-chars-to-return, not position.
r=jag, sr=jst


git-svn-id: svn://10.0.0.236/trunk@102509 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-07 03:44:33 +00:00
shanjian%netscape.com
eda91c291b #90595 Crash when switch to different Simplified Chinese IME a few times
r=yokoyama, sr=waterson


git-svn-id: svn://10.0.0.236/trunk@102508 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-07 03:43:07 +00:00
justdave%syndicomm.com
f0c275702c Fix for bug 98468: sample email regexp for username-only address changed from ^[^@]*$ to ^[^@]+$ and the default emailregexp changed from ^[^@]*@[^@]*\\.[^@]*$ to ^[^@]+@[^@]+\\.[^@]+$
Patch by Dave Miller <justdave@syndicomm.com>
r= jake@acutex.net x2


git-svn-id: svn://10.0.0.236/trunk@102507 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-07 03:25:33 +00:00
dbaron%fas.harvard.edu
d015d63bf1 Make getComputedStyle remove the extra default font that we add to the end of the font-family list so it returns the original computed value. b=94078 r=hyatt sr=jst
git-svn-id: svn://10.0.0.236/trunk@102506 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-07 02:28:10 +00:00
sspitzer%netscape.com
622ab66c0e move the unused 4.x mapi code to mozilla/mailnews/mapi/old to make room for the new mapi code coming.
rs=bienvneu


git-svn-id: svn://10.0.0.236/trunk@102505 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-07 02:14:34 +00:00
wtc%netscape.com
e5218cd198 Bugzilla bug 95836: Added _PR_CleanupIO() and made it call
_PR_CleanupFdCache().  PR_Cleanup() now calls _PR_CleanupIO() and does
not call _PR_CleanupFdCache() directly.
Modified files: primpl.h prio.c prinit.c ptio.c ptthread.c


git-svn-id: svn://10.0.0.236/trunk@102504 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-07 01:55:49 +00:00
relyea%netscape.com
f19270c4f2 Free the Pairs, not the previous values.
git-svn-id: svn://10.0.0.236/trunk@102502 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-07 01:34:18 +00:00
relyea%netscape.com
8cdfd556f7 Free the data, in the array, not the array;).
git-svn-id: svn://10.0.0.236/trunk@102501 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-07 01:33:22 +00:00
justdave%syndicomm.com
cc43b69ce0 refix for bug 91808: previous patch for this bug used an INNER JOIN construct in the SQL, which is not supported by the
minimum version of MySQL that we require.
Patch by Matthew Tuck <matty@chariot.net.au>
r= justdave x2


git-svn-id: svn://10.0.0.236/trunk@102500 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-07 01:32:13 +00:00
hyatt%netscape.com
8cdd4a4654 98337 fix (r/sr=danm,brendan), also fix for 96610 from jgaunt/aaronl (sr from me, just checking it in since aaronl is on vacation)
git-svn-id: svn://10.0.0.236/trunk@102499 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-07 01:26:00 +00:00
rjesup%wgate.com
4c270b21d7 Bug 93999: Minor bustage fix for HPUX (doesn't allow delete [] of void *);
dbaron looked it over and agrees.


git-svn-id: svn://10.0.0.236/trunk@102496 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-07 00:57:52 +00:00
bryner%netscape.com
f426319898 Removing obsolete file. r=cls.
git-svn-id: svn://10.0.0.236/trunk@102495 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-07 00:38:23 +00:00
pierre%netscape.com
53dfaf64c7 Bug 93371 (WRMB: Treat classes case insensitively in quirks mode). Back out ianh's patch in nsCSSParser.cpp and nsHTMLAttributes.cpp. Treat classes and IDs case insensitively as described in Bug 35522. r=glazman (+dbaron/jst) sr=hyatt
git-svn-id: svn://10.0.0.236/trunk@102494 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-07 00:23:37 +00:00
wtc%netscape.com
a44592e2b8 Bugzilla bug 95817: destroy _pr_sleeplock in PR_Cleanup(). The patch is
contributed by jeff@NerdOne.com.
Modified files: prinit.c ptthread.c


git-svn-id: svn://10.0.0.236/trunk@102492 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-07 00:15:21 +00:00
wtc%netscape.com
40b3bff0fa Bugzilla bug 95773: Added _PR_CleanupEnv() and call it from PR_Cleanup().
The patch is contributed by jeff@NerdOne.com.
Modified files: primpl.h prenv.c prinit.c ptthread.c


git-svn-id: svn://10.0.0.236/trunk@102491 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-07 00:05:50 +00:00
sicking%bigfoot.com
c9f433c3dc Push and pop xslt-current node only when needed. Also evaluate xsl:with-param only once in an xsl:apply-templates.
b=97405, r=peterv, sr=jst


git-svn-id: svn://10.0.0.236/trunk@102489 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-07 00:04:02 +00:00
bryner%netscape.com
0d507fb37f Bug 98420 - nsIFontRetrieverService, nsIFontNameIterator, and nsIFontSizeIterator are obsolete. Also, some cleanup to nsWidgetsCID.h. r=pavlov, sr=blizzard.
git-svn-id: svn://10.0.0.236/trunk@102487 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-06 23:50:02 +00:00
relyea%netscape.com
71fc851f32 Change the keydb reset code from walking down deleting all the key entries to
closing the keydb and reopenning it truncated.


git-svn-id: svn://10.0.0.236/trunk@102486 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-06 23:23:42 +00:00
rjesup%wgate.com
f686201c7a Bug 97345: fixing bustage, checked wrong version in (without return).
git-svn-id: svn://10.0.0.236/trunk@102485 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-06 23:20:16 +00:00
beard%netscape.com
0051338311 [not part of build] fixes for bug #98382, r=av, allow building on Mac.
git-svn-id: svn://10.0.0.236/trunk@102484 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-06 23:18:07 +00:00
beard%netscape.com
b43f7e045a [not part of build] Mac files for scriptable NPAPI plugin.
git-svn-id: svn://10.0.0.236/trunk@102483 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-06 23:15:57 +00:00
vidur%netscape.com
795ea6cca5 Out parameters should be set to null to account for failure cases. r=jband, sr=jst@netscape.com
git-svn-id: svn://10.0.0.236/trunk@102481 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-06 23:05:21 +00:00
rjesup%wgate.com
5f20dbeac5 bug 93999: reduce number of image creations in gtk/xlib. Patch by imot
(Tomi.Leppikangas@oulu.fi).  r=pavlov, sr=brendan, r=bbaetz on c++ issues,
 jst said "check it in" on c++ issues.


git-svn-id: svn://10.0.0.236/trunk@102480 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-06 23:00:49 +00:00
rginda%netscape.com
62a5fb2141 - venkman only -
prepare for "group/ungroup" UI in the file list


git-svn-id: svn://10.0.0.236/trunk@102479 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-06 22:57:34 +00:00
rginda%netscape.com
af90d76aa3 - venkman only -
fix sort tests


git-svn-id: svn://10.0.0.236/trunk@102478 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-06 22:56:56 +00:00
rjesup%wgate.com
34bdbec8d4 bug 97345: insertion of <option>'s into <select> is very slow.
r=rods, sr=jst


git-svn-id: svn://10.0.0.236/trunk@102477 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-06 22:54:44 +00:00
pinkerton%netscape.com
b30e2850a9 allow changing of the label of a submenu. r=saari/sr=smfr/a=asa. bug# 97549.
git-svn-id: svn://10.0.0.236/trunk@102476 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-06 22:49:55 +00:00
waldemar%netscape.com
4d24ce62eb Split out parseFunctionExpression
git-svn-id: svn://10.0.0.236/trunk@102475 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-06 22:44:32 +00:00
waldemar%netscape.com
4937ee8e4d Added missing library
git-svn-id: svn://10.0.0.236/trunk@102474 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-06 22:31:29 +00:00
waldemar%netscape.com
3f0f2f0e97 Added missing files
git-svn-id: svn://10.0.0.236/trunk@102473 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-06 22:31:05 +00:00
rginda%netscape.com
08c69f7e45 - venkman only -
fix line ending split regexp to avoid the brain dead $ meta character (which considers \r\n to be TWO line endings.)


git-svn-id: svn://10.0.0.236/trunk@102472 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-06 22:29:14 +00:00
rginda%netscape.com
0ca89379fd - venkman only -
fix imput history regression


git-svn-id: svn://10.0.0.236/trunk@102471 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-06 22:28:09 +00:00
ccarlen%netscape.com
de5f8fea5c Fixing bustage - didn't remove file from both targets
git-svn-id: svn://10.0.0.236/trunk@102470 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-06 22:16:57 +00:00
mkaply%us.ibm.com
5521f4e839 OS/2 build bustage - thanks gerv
git-svn-id: svn://10.0.0.236/trunk@102469 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-06 22:10:51 +00:00
yokoyama%netscape.com
6c6445fd09 bug 91193
Makefile.win change. Correcting dll name
/r=ftang;/sr=waterson


git-svn-id: svn://10.0.0.236/trunk@102468 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-06 22:06:55 +00:00
rginda%netscape.com
086a4d9e61 bug 95534, r=brendan, sr=jband
fix semantics of JSTRAP_CONTINUE to prevent a debugger client from telling the engine to continue when we all know it'll proobably just crash.


git-svn-id: svn://10.0.0.236/trunk@102465 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-06 21:46:18 +00:00
naving%netscape.com
e6a794f445 95501 r/sr=bienvenu sr=mscott. Fix nsDocShell leaks for pop3 accts on start-up and shutdown.
git-svn-id: svn://10.0.0.236/trunk@102460 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-06 21:32:11 +00:00
jband%netscape.com
c25a7edcbb Slightly modify the WIN32 flags check to catch missing XP_WIN32 define also. Add a comment to help people tripping over this so that they can see what we are telling them to fix. See bug 65727. rs=jband
git-svn-id: svn://10.0.0.236/trunk@102459 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-06 21:26:08 +00:00
gerv%gerv.net
64eeb6482f Set start page override and home page to be http://www.mozilla.org/start , a page encouraging people to get involved with Mozilla. r,a=asa.
git-svn-id: svn://10.0.0.236/trunk@102458 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-06 21:24:43 +00:00
relyea%netscape.com
6ea5d224d7 For a search reload after the database has been cleared.
git-svn-id: svn://10.0.0.236/trunk@102456 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-06 21:20:16 +00:00
relyea%netscape.com
658b7a021a Don't reuse sessions that have already be closed.
git-svn-id: svn://10.0.0.236/trunk@102455 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-06 21:19:13 +00:00
relyea%netscape.com
ab5346358b Add option to reset the cert and key database.
git-svn-id: svn://10.0.0.236/trunk@102454 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-06 21:18:13 +00:00
relyea%netscape.com
96a8daf191 Fix Updating the slot in modutil.
Add option to dump the raw PKCS #11 strings.


git-svn-id: svn://10.0.0.236/trunk@102453 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-06 21:16:51 +00:00
relyea%netscape.com
523dee343c Export functions for Modutil (need to fix the names to be global!)
git-svn-id: svn://10.0.0.236/trunk@102452 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-06 21:15:09 +00:00
ccarlen%netscape.com
ef0da78764 removed nsServiceManager.cpp, nsRepository.cpp for dougt
git-svn-id: svn://10.0.0.236/trunk@102451 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-06 21:14:30 +00:00
relyea%netscape.com
2dcc708078 Allow modutil to get the raw pkcs #11 strings.
fix NSS_Init_NO_DB().


git-svn-id: svn://10.0.0.236/trunk@102450 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-06 21:14:06 +00:00
dougt%netscape.com
6abd1d51a4 Merge ServiceManager and ComponentManager. Bug 96457. r=dp@netscape.com, sr=wat
erson@netscape.com


git-svn-id: svn://10.0.0.236/trunk@102449 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-06 21:13:11 +00:00
rjesup%wgate.com
8b0885ab65 bug 92573: VoidArray->AutoVoidArray changes for layout/*. r=kin, sr=attinasi
git-svn-id: svn://10.0.0.236/trunk@102448 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-06 21:11:44 +00:00
relyea%netscape.com
a85264d923 Fix Modutil delete.
add function to modutil to display raw pkcs #11 module strings


git-svn-id: svn://10.0.0.236/trunk@102447 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-06 21:08:44 +00:00
relyea%netscape.com
56d45b5359 1) fix bug in module deletion.
2) Add new function in modutil to desplay the raw PKCS #11 module strings


git-svn-id: svn://10.0.0.236/trunk@102446 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-06 21:06:39 +00:00
blizzard%redhat.com
fcaadca915 honor the running state of the xremote service. not part of the build.
git-svn-id: svn://10.0.0.236/trunk@102445 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-06 20:46:57 +00:00
blizzard%redhat.com
3a60039893 loading urls into the most recently used window works properly now and other cleanups. not part of the build.
git-svn-id: svn://10.0.0.236/trunk@102444 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-06 20:34:16 +00:00
kaie%netscape.com
eb20d6cd23 r=87578 r=ddrinan sr=blizzard
Enable a user to use (or switch to) an empty security password, i.e. no password at all.


git-svn-id: svn://10.0.0.236/trunk@102443 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-06 20:29:07 +00:00
shanjian%netscape.com
df5bf28667 #97516 crash in nsRenderingContextWin::GetWidth() in certain situation
r=rbs, sr=waterson


git-svn-id: svn://10.0.0.236/trunk@102442 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-06 20:21:59 +00:00
kaie%netscape.com
ee77cee24a b=93103 r=relyea/ddrinan sr=blizzard
Enable display of complete chains when viewing certificates.


git-svn-id: svn://10.0.0.236/trunk@102441 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-06 20:20:50 +00:00
hwaara%chello.se
1ed017745c #82104, "`Software Installation' alert is unneccessarily complicated".
r=dveditz, sr=blizzard.


git-svn-id: svn://10.0.0.236/trunk@102440 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-06 20:18:15 +00:00
blizzard%redhat.com
7a94ab9706 More work in progress. Added ping command and you can now open mail/news and browser windows remotely. Not part of the build.
git-svn-id: svn://10.0.0.236/trunk@102438 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-06 20:09:30 +00:00
varada%netscape.com
26d0fdafa3 fix for bug#82120;disable editable fields during sending of mail;r=cmanske;sr=sspitzer
git-svn-id: svn://10.0.0.236/trunk@102437 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-06 19:46:49 +00:00
rjesup%wgate.com
977fe6eac8 Bug 96710: Misuse of string.Mid() - uses should be string.Right().
r=kin, sr=jst


git-svn-id: svn://10.0.0.236/trunk@102436 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-06 19:38:20 +00:00
bnesse%netscape.com
2651ba14d0 Fix for bug 49776. Add additional bulletproofing to nsPrefBranch. r=mitesh, sr=alecfl.
git-svn-id: svn://10.0.0.236/trunk@102435 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-06 19:30:47 +00:00
hwaara%chello.se
1f6b8b786e #72203, optimize local search a bit by short-circuiting our evaluation code.
Original patch submitted by Michael Tiemann.

r=naving, sr=sspitzer.


git-svn-id: svn://10.0.0.236/trunk@102434 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-06 19:30:13 +00:00
rjesup%wgate.com
2e2ef60158 bug 97480: missing virtual in destructor in nsFontCache. r=bstell, sr=kin
git-svn-id: svn://10.0.0.236/trunk@102433 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-06 19:27:38 +00:00
hwaara%chello.se
58ad9ef22d #97834, checking in the final change to not mark a msg as read in the db if it already is...
r/sr=bienvenu, sspitzer


git-svn-id: svn://10.0.0.236/trunk@102431 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-06 19:20:49 +00:00
rjesup%wgate.com
3d0a34aaca Bug 92575: voidarray->autovoidarray changes in content/*, minus mChildren
changes in nsXULContentSink.cpp and nsGenericElement.cpp as per jst.
  r=hyatt r=pierre sr=jst


git-svn-id: svn://10.0.0.236/trunk@102430 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-06 19:16:03 +00:00
naving%netscape.com
13d658c059 96921 r=suresh sr=mscott, part of the fix that was not checked in.
git-svn-id: svn://10.0.0.236/trunk@102429 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-06 19:13:45 +00:00
waterson%netscape.com
b7c9fb7cd4 Bug 98456. Fix meta-modules on Linux. r=dp, sr=cls.
git-svn-id: svn://10.0.0.236/trunk@102428 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-06 19:13:41 +00:00
jband%netscape.com
2416ed1694 fix bug 96511. Meant #ifdef not #if. sr=brendan r=jband
git-svn-id: svn://10.0.0.236/trunk@102425 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-06 19:01:17 +00:00
cotter%netscape.com
a633ad4bb5 privacy & security help content update per b=85925, a=asa, r=oeschger
git-svn-id: svn://10.0.0.236/trunk@102424 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-06 18:55:28 +00:00
jgaunt%netscape.com
e7791d639e patch for bug 98101 patch from jband r=jgaunt sr=waterson
add OBJDIR to 2 makefile.win files


git-svn-id: svn://10.0.0.236/trunk@102423 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-06 18:48:40 +00:00
cotter%netscape.com
5611782025 privacy & security help content updates per b=85925, a=asa, r=oeschger
git-svn-id: svn://10.0.0.236/trunk@102422 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-06 18:46:13 +00:00
danm%netscape.com
73a2cec18e XULWindow no longer needs to cache the widget size mode. bug 96475 r=hyatt,pchen
git-svn-id: svn://10.0.0.236/trunk@102421 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-06 18:35:59 +00:00
danm%netscape.com
759e12d6fc remove bug 70283's optimization to persist window size state only if it (apparently) hasn't changed. bug 86955, 89740. also set a newly opened window's main widget's zoom state even if it's not yet visible. bug 96475 r=hyatt,pchen
git-svn-id: svn://10.0.0.236/trunk@102420 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-06 18:35:55 +00:00
danm%netscape.com
fd9c5602bd tell nsWindowWatcher about window creation/destruction so its enumerators will work. bug 97514 r=hyatt,pchen
git-svn-id: svn://10.0.0.236/trunk@102418 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-06 18:26:52 +00:00
attinasi%netscape.com
3742456a40 New testcase added. Not part of build
git-svn-id: svn://10.0.0.236/trunk@102417 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-06 18:18:48 +00:00
attinasi%netscape.com
30c0aaac9d New table layout regression test. Not part of build
git-svn-id: svn://10.0.0.236/trunk@102416 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-06 18:18:10 +00:00
kestes%walrus.com
9719c2f833 better documentation both internal and external. Reevaluate the steps
to make a build each iteration to allow builds to create time stamped output.
catch some errrors using eval so that they will appear in the tinderbox mail and not as fatal errors. Strip a few more 'dangerous variables' from the environment.


git-svn-id: svn://10.0.0.236/trunk@102415 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-06 18:15:53 +00:00
attinasi%netscape.com
cf6ab32fb9 Added table layout regression test for bug 97619. Not part of build
git-svn-id: svn://10.0.0.236/trunk@102414 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-06 17:49:46 +00:00
attinasi%netscape.com
52e9a07c29 New table layuout regression test: not part of build.
git-svn-id: svn://10.0.0.236/trunk@102413 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-06 17:40:55 +00:00
nboyd%atg.com
ea2f8a8c22 patch (with my modifications) from jj@mail.ahc.umn.edu:
It would be nice if the rhino shell would accept a URL as the source
for javascript.

I've added this feature to my local copy so that I can launch rhino
with js scripts using  JavaWebStart.

Below is a context diff of the changes I made to
toolsrc/org/mozilla/javascript/tools/shell/Main.java


git-svn-id: svn://10.0.0.236/trunk@102412 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-06 16:53:29 +00:00
dbaron%fas.harvard.edu
1d897716fd Fix topcrash bug 96563 by reading only the number of characters of string that we have, rather than double that number. r=pavlov sr=blizzard
git-svn-id: svn://10.0.0.236/trunk@102410 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-06 14:30:38 +00:00
bstell%netscape.com
cf763bcfc1 bug 97533, patch by dbaron@fas.harvard.edu, r=bstell, sr=blizzard
check return status from getIntPref


git-svn-id: svn://10.0.0.236/trunk@102409 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-06 14:22:08 +00:00
blizzard%redhat.com
43506cd4ce Fix bug #97851. Make sure that file permissions are set properly on the temporary file used for file uploads. r=pete, sr=waterson
git-svn-id: svn://10.0.0.236/trunk@102407 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-06 13:25:15 +00:00
bzbarsky%mit.edu
bafa24e23a Re-fix bug 93977 and fix bug 98358 (lack of underlining on links). The
CSS parser parses "foo, bar { decls }" into two separate rules -- one
for foo and one for bar.  So ParseRule() has to return an array of
rules, not just a rule.  r=dbaron, sr=jst


git-svn-id: svn://10.0.0.236/trunk@102406 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-06 13:14:35 +00:00
jdunn%netscape.com
99fae25d41 fixing cement IRIX tinderbox bustage
git-svn-id: svn://10.0.0.236/trunk@102405 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-06 12:50:38 +00:00
jake%acutex.net
b9a3313a65 Fix for bug 30597 - Hyperlinking the number of votes was causing some confusion because it was such a small link, yet the most useful. Instead, we now have a link labeled "Show votes for this bug".
Patch by Matthew Tuck <matty@chariot.net.au>
r= louie@ximian.com, jake@acutex.net


git-svn-id: svn://10.0.0.236/trunk@102404 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-06 12:42:47 +00:00
leaf%mozilla.org
d1a74e42dd Automated update
git-svn-id: svn://10.0.0.236/trunk@102402 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-06 11:28:40 +00:00
katakai%japan.sun.com
529ec58458 bug 95258
Need to add a new extension to support Complex Text Layout
changing configure and configure.in
check for prabhat.hegde@sun.com
r=leaf sr=cls


git-svn-id: svn://10.0.0.236/trunk@102401 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-06 11:19:25 +00:00
pavlov%netscape.com
ee52ce4677 fixing warnings/build bustage from checkin a minute ago
git-svn-id: svn://10.0.0.236/trunk@102399 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-06 09:07:08 +00:00
pavlov%netscape.com
efc36dfc55 adding additional tests. part of sparcv9 work.. bug 91840. r=me/cls@seawood.org/rogerl rs=brendan
git-svn-id: svn://10.0.0.236/trunk@102397 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-06 08:27:43 +00:00
pavlov%netscape.com
9121ce11c0 Enabling the sparcv9 xptcall code. Bug 91840. r=me/cls@seawood.org/rogerl rs=brendan
git-svn-id: svn://10.0.0.236/trunk@102396 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-06 08:23:09 +00:00
glazman%netscape.com
99716e4ffe getComputedStyle answered for background-color #ffffff instead of transparent; b=97771, r=pierre, sr=hyatt
git-svn-id: svn://10.0.0.236/trunk@102395 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-06 08:20:50 +00:00
pavlov%netscape.com
dcf116656b Adding a few more comments about what is going on and fixing the couple of issues brought up by brendan. Work for bug 91840. not part of build
git-svn-id: svn://10.0.0.236/trunk@102394 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-06 08:18:24 +00:00
blizzard%redhat.com
28f2ef4767 More new X Remote work. This code is now in better shape than the original. Not part of the build.
git-svn-id: svn://10.0.0.236/trunk@102392 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-06 06:43:54 +00:00
jband%netscape.com
870c86ceaf fix bug 98450. We need to be calling OBJ_DROP_PROPERTY after OBJ_LOOKUP_PROPERTY. Also, this was refactored on dbradley's suggestion. sr=brendan r=dbradley
git-svn-id: svn://10.0.0.236/trunk@102391 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-06 06:29:19 +00:00
jst%netscape.com
b3062e8e60 Fixing leaks introduced by my fix for 91241. Breaking circular namespace manager -> XUL element factory -> namespace manager reference that kept one namespace manager and one XUL and XML element factory alive. sr=jband@netscape.com
git-svn-id: svn://10.0.0.236/trunk@102390 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-06 06:18:31 +00:00
rpotts%netscape.com
32390b41d3 bug #98469 (r=pavlov, sr=jst). Using the _content window target sometimes fails...
git-svn-id: svn://10.0.0.236/trunk@102388 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-06 05:31:14 +00:00
naving%netscape.com
3100f77e68 98377 r/sr=bienvenu fix nsMsgMailNewsUrl mlk on copying local messages.
git-svn-id: svn://10.0.0.236/trunk@102386 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-06 04:41:03 +00:00
alecf%netscape.com
ab0aba9085 string changes for MOZ_TRACK_MODULE_DEPS - bug 98371 r=cls
git-svn-id: svn://10.0.0.236/trunk@102385 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-06 04:06:10 +00:00
mkaply%us.ibm.com
0bee895f7b No bug
r=mkaply, sr=blizzard
OS/2 only - Got these reversed - on OS/2, NEWFRAME is used at the end of a page, not the beginning


git-svn-id: svn://10.0.0.236/trunk@102384 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-06 04:01:45 +00:00
mkaply%us.ibm.com
3594d5d6bb No bug
r=mkaply, sr=blizzard
OS/2 only - code from javier - more font improvements - better scaling and text zoom for bitmap fonts


git-svn-id: svn://10.0.0.236/trunk@102383 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-06 04:00:07 +00:00
alecf%netscape.com
1a422e5b81 dumb
CVS :nd string makefile updates for 98371 r=cls----------------------------------------------------------------------


git-svn-id: svn://10.0.0.236/trunk@102380 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-06 03:56:35 +00:00
alecf%netscape.com
8e8f64c3fd adding MOZ_TRACK_MODULE_DEPS support to win32 build
the rest of the makefiles are not ready
for bug 98371
r=cls


git-svn-id: svn://10.0.0.236/trunk@102379 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-06 03:49:50 +00:00
stephend%netscape.com
4ef67e6533 Bug 98453. Use 'Mail & Newsgroups' consistently throughout the UI. r/sr=sspitzer@netscape.com
git-svn-id: svn://10.0.0.236/trunk@102378 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-06 03:41:10 +00:00
blizzard%redhat.com
194f563358 get mailto: links working, clean up a lot of debugging code. not part of the build.
git-svn-id: svn://10.0.0.236/trunk@102377 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-06 03:39:51 +00:00
bienvenu%netscape.com
a77f3b626f don't mark news msg read when reading it if it's already read original patch from hwaara, r=bienvenu sr=sspitzer 97834
git-svn-id: svn://10.0.0.236/trunk@102376 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-06 03:23:43 +00:00
bienvenu%netscape.com
0fefb8fc0a don't mark imap msg read when reading it if it's already read rs=sspitzer 97834
git-svn-id: svn://10.0.0.236/trunk@102375 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-06 03:21:29 +00:00
justdave%syndicomm.com
1cb991e0dc Fix for bug 42337: Adding the usual red box for errors uploading attachments.
Patch by Matthew Tuck <matty@chariot.net.au>
r= louie@ximian.com, justdave@syndicomm.com


git-svn-id: svn://10.0.0.236/trunk@102374 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-06 03:20:34 +00:00
nelsonb%netscape.com
44cf59d2ab Fix a crash. An attempt to move a sensitive key longer than 48 bytes
from one token to another will no longer crash.  Instead, it will fail
with the new error code SEC_ERROR_CANNOT_MOVE_SENSITIVE_KEY.  Bug 97887.
In addition, DHE key pairs are now generated with CKA_SENSITIVE false.


git-svn-id: svn://10.0.0.236/trunk@102373 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-06 03:00:39 +00:00
hyatt%netscape.com
36a8713c53 Missed another file from 93180.
git-svn-id: svn://10.0.0.236/trunk@102372 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-06 02:21:55 +00:00
justdave%syndicomm.com
9dabccd718 Fix for bug 69616: If you have tweakparams privs, the "Sanity check" link was listed with a group of items that said "Edit" so
it appeared as if you were going to edit the sanity checks if you clicked on it, when in fact you were going to run them.
This patch rewords the links so Sanity check is in a group by itself in the block of links on the right.
Patch by Matthew Tuck <matty@chariot.net.au>
r= justdave x2


git-svn-id: svn://10.0.0.236/trunk@102371 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-06 02:19:04 +00:00
hyatt%netscape.com
a6f8ebbafe Fix bustage.
git-svn-id: svn://10.0.0.236/trunk@102369 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-06 02:10:11 +00:00
brendan%mozilla.org
6d5f73866a Don't cache chrome scripts unless their master document URL is chrome too (we need the prototype cache to root the script objects; 98207, sr=jband&waterson, a=asa).
git-svn-id: svn://10.0.0.236/trunk@102368 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-06 02:01:40 +00:00
rginda%netscape.com
079b48a06f - venkman only -
fixing popup events


git-svn-id: svn://10.0.0.236/trunk@102367 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-06 01:54:53 +00:00
rginda%netscape.com
8c7d55aef9 - venkman only -
init xpconnect on the debugger's default context so that xpconnect can use it when it has to.  r=jband


git-svn-id: svn://10.0.0.236/trunk@102366 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-06 01:34:44 +00:00
av%netscape.com
c2b06c9bd5 Fixing bug 96804 -- isReplaced is not set for object frames created with <embed> tag, patch by timkoogleblowsgoats@yahoo.com, r=peterl, sr=attinasi
git-svn-id: svn://10.0.0.236/trunk@102365 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-06 01:26:14 +00:00
attinasi%netscape.com
e0458cee7d Two QuirkMode only fixes: 1) prevent bullets from getting resized with LI and 2) collapse margins for empty elements in BODY and table cells. b=97351 r=pierre sr=waterson b=97361 r=pierre sr=hyatt
git-svn-id: svn://10.0.0.236/trunk@102363 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-06 01:22:55 +00:00
hyatt%netscape.com
7168876239 Adding stack testcase to the debug menu for 93180.
git-svn-id: svn://10.0.0.236/trunk@102362 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-06 01:09:35 +00:00
hyatt%netscape.com
f82ab97f32 Removing file for 93180.
git-svn-id: svn://10.0.0.236/trunk@102361 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-06 01:07:56 +00:00
hyatt%netscape.com
459bc5fe31 Fix for 93180. r-jag, sr=jst
git-svn-id: svn://10.0.0.236/trunk@102360 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-06 01:07:40 +00:00
rginda%netscape.com
ab633fa73d - venkman only -
strict mode fixes


git-svn-id: svn://10.0.0.236/trunk@102359 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-06 01:05:50 +00:00
rginda%netscape.com
d6b2dbf16d - venkman only -
remove debug spoo


git-svn-id: svn://10.0.0.236/trunk@102358 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-06 01:05:20 +00:00
rginda%netscape.com
e9b8b7e003 - venkman only -
record last stack depth. when the stack depth changes, we display a frame header in the console for single step mode.


git-svn-id: svn://10.0.0.236/trunk@102357 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-06 01:05:02 +00:00
rginda%netscape.com
d28982ed49 - venkman only -
strict mode fixes.


git-svn-id: svn://10.0.0.236/trunk@102356 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-06 01:04:01 +00:00
rginda%netscape.com
e6fd4e7ecc - venkman only -
move debugTrap code that may involve network activity from venkman-debugger.js to this file.
strict mode fixes.
fix outliner select events, which range checked against the wrong properties.


git-svn-id: svn://10.0.0.236/trunk@102355 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-06 01:03:06 +00:00
rginda%netscape.com
489e14dff4 - venkman only -
move calls that might involve network activity to *after* te enterNestedEventLoop() call so their requests go on the pushed thread.  The call is made after enterNestedEventLoop (which, by definition, blocks) via a setTimeout call.


git-svn-id: svn://10.0.0.236/trunk@102353 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-06 01:01:34 +00:00
rginda%netscape.com
06b249145d - venkman only -
strict mode fixes
remove some debugging spoo


git-svn-id: svn://10.0.0.236/trunk@102352 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-06 00:59:24 +00:00
nelsonb%netscape.com
9859fd8821 Detect Null pointer. Assert if null, else don't crash here. Bug 97887.
git-svn-id: svn://10.0.0.236/trunk@102351 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-06 00:49:39 +00:00
sfraser%netscape.com
b01c4aa84d Add an explicit search path to 'Carbon Support' first to ensure that we pick up CarbonLib 1.4, rather than the older version in Univeral Headers.
git-svn-id: svn://10.0.0.236/trunk@102350 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-06 00:46:38 +00:00
dp%netscape.com
7045611501 bug# 97528 Eliminating the extra Clone() on chrome urls. Plus
optimizing nsChromeRegistry::Canonify() to only SetSpec() if there is
a change. r=brendan,hyatt sr=waterson


git-svn-id: svn://10.0.0.236/trunk@102349 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-06 00:45:16 +00:00
yokoyama%netscape.com
7ff3a20943 Bug 96318:
Fixing accidental removal of nsIFontPackageService.
/r=ftang;/sr=waterson;/a=asa


git-svn-id: svn://10.0.0.236/trunk@102348 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-06 00:26:13 +00:00
bryner%netscape.com
ec6a6ca84a Removing obsolete/unused file. Not part of the build.
git-svn-id: svn://10.0.0.236/trunk@102347 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-06 00:08:42 +00:00
pschwartau%netscape.com
e4d5a55745 Trivial whitespace fix.
git-svn-id: svn://10.0.0.236/trunk@102344 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-05 23:35:07 +00:00
mitesh%netscape.com
c20c2c2a0e Fix for bug 97228 - multiple appends of email address
r=bnesse and sr=shaver


git-svn-id: svn://10.0.0.236/trunk@102343 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-05 23:25:54 +00:00
kaie%netscape.com
f2bf305181 b=97369 r=kaie sr=blizzard
Checking in for walk84


git-svn-id: svn://10.0.0.236/trunk@102342 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-05 23:22:31 +00:00
pschwartau%netscape.com
90d6d1ad55 Completely rethinking this testcase. Reduced test as much as possible, added try...catch blocks and for-loop to stress-test the code.
git-svn-id: svn://10.0.0.236/trunk@102341 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-05 23:21:33 +00:00
kaie%netscape.com
e6b2897694 b=78720 r=javi sr=blizzard
Checking in for walk84


git-svn-id: svn://10.0.0.236/trunk@102340 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-05 23:20:41 +00:00
despotdaemon%netscape.com
b53ccc277a Pseudo-automatic update of changes made by leaf@mozilla.org.
git-svn-id: svn://10.0.0.236/trunk@102339 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-05 23:19:39 +00:00
ducarroz%netscape.com
cfde140b23 Fix for bug 97256. Don't be case sensitive when checking for a RFC822 header!
Patch provided by Denis Antrushin <adu@sparc.spb.su>. R=ducarroz, SR=sspitzer


git-svn-id: svn://10.0.0.236/trunk@102338 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-05 23:04:55 +00:00
hwaara%chello.se
b8eeb24c68 #90774, "Up and Down should be 'Up Arrow' and 'Down Arrow'".
Patch by Neil <neil@parkwaycc.co.uk>.

r=rchen, sr=blizzard.


git-svn-id: svn://10.0.0.236/trunk@102336 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-05 22:59:15 +00:00
valeski%netscape.com
5bca1cb1dd fixing IRIX bustage. win line endings wound up in the new .h file. this diff converts them to raw line ending chars
git-svn-id: svn://10.0.0.236/trunk@102335 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-05 22:52:43 +00:00
bryner%netscape.com
4513ecc825 Bug 81398 -- tabbing doesn't go into out-of-flow frames. r=saari, sr=hyatt.
git-svn-id: svn://10.0.0.236/trunk@102334 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-05 22:52:18 +00:00
jaggernaut%netscape.com
fa712547bb Bug 96721: Make nsAppRunner use WindowOpen instead of CreateTopLevelWindow, r=danm, sr=alecf
git-svn-id: svn://10.0.0.236/trunk@102333 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-05 22:34:20 +00:00
sspitzer%netscape.com
70275e6d21 fix for #97585. if the user happens to have a directory for their sig file, don't go into
an infinite loop.  r=ducarroz, sr=bienvenu


git-svn-id: svn://10.0.0.236/trunk@102331 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-05 22:24:43 +00:00
blizzard%redhat.com
5569c2d112 More WIP on new X Remote code. Not part of the build. OpenURL() with and without arguments work now.
git-svn-id: svn://10.0.0.236/trunk@102330 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-05 21:48:23 +00:00
kaie%netscape.com
f759fc8db1 removing a fprintf(stderr) from my previous checkin
git-svn-id: svn://10.0.0.236/trunk@102329 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-05 21:34:38 +00:00
rginda%netscape.com
59d192da29 - venkman only -
turn off verbose debugging for me
push a thread event queue for necko before we enter a nested event loop


git-svn-id: svn://10.0.0.236/trunk@102328 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-05 21:29:59 +00:00
valeski%netscape.com
8db35965a8 r=dbaron, sr=dougt. 97667. nsIInterfaceRequestor is now frozen. nsIInterfaceRequestorUtils.h is now required if you want to use do_GetInterface() for convenience. The two were split because the stuff that is now in nsIInterfaceRequestorUtils.h wasn't ready for freezing. Also, .idl files should just contain interface defs anyway.
git-svn-id: svn://10.0.0.236/trunk@102327 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-05 21:28:38 +00:00
kaie%netscape.com
7b5cf182e5 Checking in for valeski. In case of problems you can reach me at kai.engert@gmx.de
r=dbaron, sr=dougt. 97667. nsIInterfaceRequestor is now frozen. nsIInterfaceRequestorUtils.h is now
required if you want to use do_GetInterface() for convenience. The two were split because the stuff
that is now in nsIInterfaceRequestorUtils.h wasn't ready for freezing. Also, .idl files should just
contain interface defs anyway.


git-svn-id: svn://10.0.0.236/trunk@102326 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-05 21:27:22 +00:00
jband%netscape.com
453d5271bf fix bug 97444. It is not good to patch a different fun into the frame. Let's safely shunt aside the callee frame instead. r=rogerl sr=brendan
git-svn-id: svn://10.0.0.236/trunk@102325 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-05 21:25:09 +00:00
pschwartau%netscape.com
737218a125 Improved accuracy of test, and added more cases.
git-svn-id: svn://10.0.0.236/trunk@102324 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-05 21:15:43 +00:00
aaronl%netscape.com
5f30f30f80 Bug 96473, added accessible.properties to Mac Build - r=tao, sr=waterson
git-svn-id: svn://10.0.0.236/trunk@102323 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-05 21:13:54 +00:00
waterson%netscape.com
43c613727c Bug 55086. Change nsContainerFrame::PositionFrameView() to position child views. Eliminate the |aView| parameter from that method, because the view can be retrieved from the frame and need not be done by the caller. Eliminate the NS_FRAME_NO_MOVE_CHILD_VIEWS flag, which was read-only; i.e., never set by anyone. r=dbaron, sr=attinasi
git-svn-id: svn://10.0.0.236/trunk@102321 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-05 20:27:19 +00:00
locka%iol.ie
34ed787b7e Remove winEmbed from embedding dist. b=90614 r=rpotts@netscape.com sr=blizzatf@mozilla.org a=asa@mozilla.org
git-svn-id: svn://10.0.0.236/trunk@102320 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-05 20:26:42 +00:00
sicking%bigfoot.com
03deb5c948 Make myAnchorElement.text return the same as NS4.x. Patch from Fabian Guisset (hidday@geocities.com).
b=85448, r=sicking, sr=jst


git-svn-id: svn://10.0.0.236/trunk@102319 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-05 20:20:50 +00:00
locka%iol.ie
c76cf87cf2 NOT PART OF BUILD. Fixed a couple of silly build breakages for when MOZ_ACTIVEX_PLUGIN_LIVECONNECT is not defined.
git-svn-id: svn://10.0.0.236/trunk@102318 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-05 20:10:04 +00:00
dsirnapalli%netscape.com
391db898b3 added two more test cases.
git-svn-id: svn://10.0.0.236/trunk@102317 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-05 19:25:49 +00:00
pschwartau%netscape.com
6d6f70b18b Warning suppression, plus getting date files into mac build
git-svn-id: svn://10.0.0.236/trunk@102316 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-05 18:38:17 +00:00
bienvenu%netscape.com
c0493c59e1 fix alignment of text following text boxes rs=sspitzer 97697
git-svn-id: svn://10.0.0.236/trunk@102315 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-05 18:31:36 +00:00
sspitzer%netscape.com
6214f4a8bb remove control Ms.
git-svn-id: svn://10.0.0.236/trunk@102314 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-05 18:30:23 +00:00
kin%netscape.com
91a6d5f254 Fix for bug #97387: WRMB:iframe with frameborder="no" does not work
Call ParseFrameborderValue() with value returned from InNavQuirksMode(),
instead of hardcoded PR_TRUE.

r=karnaze@netscape.com  sr=attinasi@netscape.com


git-svn-id: svn://10.0.0.236/trunk@102313 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-05 18:25:24 +00:00
bnesse%netscape.com
dec4d71678 Fix for bug 92447. Internalize loading of config file so it can be re-read if the preferences are reset. r=chipc, mitesh. sr=sfraser.
git-svn-id: svn://10.0.0.236/trunk@102312 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-05 18:22:10 +00:00
pschwartau%netscape.com
430684703a Adding comment regarding regress-97646-001-n.js, regress-97646-002-n.js
git-svn-id: svn://10.0.0.236/trunk@102311 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-05 17:47:11 +00:00
kaie%netscape.com
b52007e705 Trying to fix BeOS bustage
git-svn-id: svn://10.0.0.236/trunk@102310 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-05 17:35:47 +00:00
pschwartau%netscape.com
8153af34c7 Correcting comments at top of file, plus bug and summary values.
git-svn-id: svn://10.0.0.236/trunk@102309 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-05 17:13:14 +00:00
pschwartau%netscape.com
2ae8b14bf9 Correcting date at top of file.
git-svn-id: svn://10.0.0.236/trunk@102308 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-05 17:03:32 +00:00
pschwartau%netscape.com
b8f6189c5e Correcting comments at top of file, plus bug and summary values.
git-svn-id: svn://10.0.0.236/trunk@102307 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-05 17:01:03 +00:00
nboyd%atg.com
6544d41b2d Patch from Igor.
git-svn-id: svn://10.0.0.236/trunk@102303 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-05 16:54:37 +00:00
nboyd%atg.com
5c7eda79e4 Patch from jeffh@aiinet.com:
There is a bug in the JavaMembers class called to wrap a Java object.

In JavaMembers.lookup(), code was added to override the static type.  The
code works in the case of an Enumeration returning an Object which would
have to be casted to the appropriate type.

The code does not work when the static type is an interface.  In this case,
the interface class is the one which should be reflected, not a parent class
of the dynamic type.  A simple staticType.isInterface() check around the
parent traversal code fixes the problem.

Jeff


git-svn-id: svn://10.0.0.236/trunk@102302 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-05 16:52:39 +00:00
nboyd%atg.com
e899c924a5 Patch from jeffh@aiinet.com:
I have found a couple problems with running Rhino 1.5R2 in a heavily
multi-threaded environment.  The attached patches fix the problems.

- org.mozilla.javascript.optimizer.InvokerImpl - This class was accessing
the shared classNumber outside of the synchronized block.

- org.mozilla.javascript.optimizer.OptClassNameHelper - The reset method was
not synchronized.  It needs to be because the class using the classNames map
is synchronized and does not handle nulling of the variable while it's
looping on the map.

Jeff


git-svn-id: svn://10.0.0.236/trunk@102301 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-05 16:50:26 +00:00
nboyd%atg.com
82bb8039ec Update for new tests.
git-svn-id: svn://10.0.0.236/trunk@102300 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-05 16:48:31 +00:00
kaie%netscape.com
a18e083aff b=24847 r=dcone sr=attinasi
Implement printing of Landscape in Unix.
Contact me at kai.engert@gmx.de


git-svn-id: svn://10.0.0.236/trunk@102297 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-05 14:30:16 +00:00
karnaze%netscape.com
10f9310e62 bug 95688 - null check on base url which might fix the talkback reports. sr=kin, r=alexsavulov.
git-svn-id: svn://10.0.0.236/trunk@102295 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-05 14:05:01 +00:00
jaggernaut%netscape.com
1536b0881b Remove #define nsString2 nsString and #define nsAutoString2 nsAutoString and fix last few uses of them. r=dbradley, rs=scc
git-svn-id: svn://10.0.0.236/trunk@102294 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-05 12:42:54 +00:00
jaggernaut%netscape.com
54a31f5907 Bug 92581: [xlib] Implement Xlib error handler for Xlib-toolkit. Patch by Roland Mainz (aka gisburn) <Roland.Mainz@informatik.med.uni-giessen.de>, r=syd, sr=kin
git-svn-id: svn://10.0.0.236/trunk@102293 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-05 11:34:29 +00:00
jaggernaut%netscape.com
234588f481 Bug 98153: Remove SubsumeStr. r=dbaron, sr=scc
git-svn-id: svn://10.0.0.236/trunk@102292 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-05 10:46:45 +00:00
axel%pike.org
6fa04b04c1 bug 94834, without png and mng, DIRS was " ", r=pavlov, sr=jst
git-svn-id: svn://10.0.0.236/trunk@102291 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-05 08:48:54 +00:00
bryner%netscape.com
24e290ab05 Removing unused/obsolete file. r=pavlov.
git-svn-id: svn://10.0.0.236/trunk@102289 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-05 08:19:53 +00:00
bryner%netscape.com
66b6116e42 Bug 90886 - eStyleStruct_BorderPaddingShortcut is obsolete. r=jag, sr=hyatt.
git-svn-id: svn://10.0.0.236/trunk@102288 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-05 08:09:45 +00:00
bryner%netscape.com
61da61b224 Bug 94491 - make the filepicker not allow multiple selection, since our filepicker API doesn't support it. r=jag, sr=jst.
git-svn-id: svn://10.0.0.236/trunk@102287 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-05 08:06:09 +00:00
cls%seawood.org
02515d8bc5 Deactivate sidebar panels when the panel is not selected.
Special thanks to matt@netscape.com for providing this patch.
Bug #53239 r=cls sr=ben a=asa


git-svn-id: svn://10.0.0.236/trunk@102285 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-05 07:43:17 +00:00
mscott%netscape.com
1790afbb1b Adding prototype property file to project from mscott's mac. This is hyatt.
git-svn-id: svn://10.0.0.236/trunk@102284 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-05 07:39:38 +00:00
mscott%netscape.com
807f017cd5 File has been added to manifest for XBL brutal sharing. This is hyatt.
git-svn-id: svn://10.0.0.236/trunk@102283 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-05 07:39:11 +00:00
mscott%netscape.com
3570f28c34 Landing XBL brutal sharing from mscott's machine. This is hyatt. The bug has r/sr=hyatt,brendan.
git-svn-id: svn://10.0.0.236/trunk@102282 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-05 07:36:55 +00:00
bryner%netscape.com
e4db469fc4 Bug 85388 - Xprint prints transparent images with black background. Patch from Roland.Mainz@informatik.med.uni-giessen.de, r=jesup@wgate.com, sr=kin.
git-svn-id: svn://10.0.0.236/trunk@102281 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-05 07:29:26 +00:00
sspitzer%netscape.com
9aa04494aa update the icons for #88970 for marlon. r/sr=hewitt,sspitzer
git-svn-id: svn://10.0.0.236/trunk@102278 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-05 06:44:39 +00:00
sspitzer%netscape.com
1c17106ca0 landing new icons for modern skin for marlon. #92429 r=sspitzer, sr=hewitt
git-svn-id: svn://10.0.0.236/trunk@102277 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-05 06:43:12 +00:00
cls%seawood.org
725755040b Updating module dependencies caused by checkin for bug 29839 and/or bug 63408 .
git-svn-id: svn://10.0.0.236/trunk@102276 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-05 06:41:12 +00:00
sspitzer%netscape.com
afd84df604 landing new icons for modern skin for marlon. #92429
r=sspitzer, sr=hewitt


git-svn-id: svn://10.0.0.236/trunk@102275 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-05 06:40:51 +00:00
cls%seawood.org
911a6f4163 Updating module dependencies caused by checkin for bug 97380
git-svn-id: svn://10.0.0.236/trunk@102273 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-05 06:37:42 +00:00
pschwartau%netscape.com
2a346d4ab4 Initial add. Regression test for bug 98306.
git-svn-id: svn://10.0.0.236/trunk@102272 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-05 06:27:25 +00:00
dougt%netscape.com
440e888df5 fix build bustage.
git-svn-id: svn://10.0.0.236/trunk@102271 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-05 04:37:13 +00:00
jst%netscape.com
1ecab07c09 Fixing bug 62613, patch from Fabian <hidday@geocities.com>. CSSStyleDeclaration objects didn't support the array syntax in JS for calling the item() method. r=harishd@netscape.com, sr=jst@netscape.com
git-svn-id: svn://10.0.0.236/trunk@102270 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-05 04:35:21 +00:00
jst%netscape.com
5a93f1f248 Fixing compiler warning (i might be used uninitialized in this function)
git-svn-id: svn://10.0.0.236/trunk@102269 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-05 04:30:12 +00:00
jst%netscape.com
f26b002773 Fixing bug 95840. Speeding up global property access in JS. r=mstoltz@netscape.com, sr=vidur@netscape.com
git-svn-id: svn://10.0.0.236/trunk@102268 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-05 04:29:13 +00:00
jst%netscape.com
2de4e518a6 Fixing bug 91241. Don't use the service manager to get the element factory everty time it's needed, cache it per namespace id, we spent about 0.9% of startup getting the element factory service. r=dp@netscape.com, sr=rpotts@netscape.com
git-svn-id: svn://10.0.0.236/trunk@102267 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-05 04:20:54 +00:00
edburns%acm.org
753ec174c7 r=peterl
sr=waterson
a=asa


modules/plugin/base/src/nsIPluginInstanceOwner.h
modules/plugin/base/src/nsPluginHostImpl.cpp
modules/plugin/base/src/nsPluginHostImpl.h
modules/plugin/base/src/nsPluginViewer.cpp
modules/oji/src/nsJVMManager.cpp
modules/oji/src/nsJVMManager.h
layout/html/base/src/nsObjectFrame.cpp
xpfe/global/resources/locale/en-US/region.properties


Here's what I did to fix this bug.

I pestered Rick Potts about the problem of
nsIWebBrowserChrome->SetStatus() not being synchronous.  He fixed that
under bug 97227.

Taking advantage of Rick's fix to 97227, I modified
nsIPluginInstanceOwner to have new method, ShowStatus(const PRUnichar
*aStatusMsg).  This is necessary to allow for localized messages to be
posted from the plugin, such as "Starting plugin for type
application/x-java-vm" or "Beginnen steckbar für Art
application/x-java-vm".

I modified all the implementations of nsIPluginInstanceOwner:

  layout/html/base/src/nsObjectFrame.cpp
  modules/plugin/base/src/nsPluginViewer.cpp

I inserted a call to nsIPluginInstanceOwner->ShowStatus() at the part
just before the big "whole damn app freezes when starting java" thing
happens.

I also modifed nsJVMManager.cpp ShowJavaConsole() to do the same.  These
are the two places I know of now that can start java.


git-svn-id: svn://10.0.0.236/trunk@102266 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-05 03:58:34 +00:00
dougt%netscape.com
8e801f7f38 Upload Channel API changes. Bug 29839. r=darin@Netscape.com, sr=rpotts@netscape.com.
Also fixes bug 63408, not alerting when file-not-found. r/sr same as above


git-svn-id: svn://10.0.0.236/trunk@102265 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-05 03:52:26 +00:00
dougt%netscape.com
120f1da920 Trival change to fix 58792 submitted by jkobal@us.ibm.com
git-svn-id: svn://10.0.0.236/trunk@102264 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-05 03:51:38 +00:00
ccarlen%netscape.com
a51a68f739 Adding nsIUploadChannel.idl for dougt
git-svn-id: svn://10.0.0.236/trunk@102263 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-05 03:42:32 +00:00
dougt%netscape.com
466a519589 adding nsIUploadChannel to the build. r=darin, sr=rpotts
git-svn-id: svn://10.0.0.236/trunk@102262 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-05 03:32:23 +00:00
dbaron%fas.harvard.edu
eb5b72dd4c Make the "browser.display.screen_resolution" pref work again. b=69205 r=bryner sr=waterson
git-svn-id: svn://10.0.0.236/trunk@102261 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-05 03:15:55 +00:00
dbaron%fas.harvard.edu
10a638521f Replace per-struct Check*Properties with property tables and account for the possibility of having an explicit 'inherit' value. b=91054 r=hyatt sr=waterson
git-svn-id: svn://10.0.0.236/trunk@102260 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-05 03:13:58 +00:00
blizzard%redhat.com
e152d59a63 Rev the serial number, remove some old patches. Not part of the build.
git-svn-id: svn://10.0.0.236/trunk@102259 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-05 03:06:01 +00:00
peterlubczynski%netscape.com
4ff5889753 Fix for not setting reflow state on object frame in printing case bug 97563 r=av sr=attinasi
git-svn-id: svn://10.0.0.236/trunk@102257 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-05 02:45:48 +00:00
stephend%netscape.com
3ee98a68f6 Bug 48053. Remove sidebar-messenger* from the tree. r=cls, sr=sspitzer
git-svn-id: svn://10.0.0.236/trunk@102256 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-05 02:43:37 +00:00
sspitzer%netscape.com
7c0740a860 fix for bug #98299. clean up fallout from #97487. rs=bienvenu
git-svn-id: svn://10.0.0.236/trunk@102255 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-05 02:20:41 +00:00
zach%zachlipton.com
ab18280466 Adding a test for safe system and exec calls. Part of this code by Dave.
git-svn-id: svn://10.0.0.236/trunk@102254 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-05 01:43:25 +00:00
rginda%netscape.com
c9da2557a6 - venkman only -
remove guessed function style, as this is now indicated by surrounding the function name in square brackets.


git-svn-id: svn://10.0.0.236/trunk@102253 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-05 01:41:07 +00:00
rginda%netscape.com
a6b55d6cbf - venkman only -
add formatting messages, remove fclear


git-svn-id: svn://10.0.0.236/trunk@102252 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-05 01:40:01 +00:00
rginda%netscape.com
5ffce21c70 - venkman only -
make dump tree function taka a param
remove bogus _cache dance
add matchesScriptRecord method to breakpoint record
only do the icode replacement if the breakpoint is enabled in addScriptRecord


git-svn-id: svn://10.0.0.236/trunk@102251 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-05 01:39:09 +00:00
rginda%netscape.com
60b571c7bc - venkman only -
remove unused messages
add used messages


git-svn-id: svn://10.0.0.236/trunk@102250 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-05 01:37:11 +00:00
rginda%netscape.com
f1de04bbc1 - venkman only -
change string concats to getMsg calls, to make bidi more better
don't duplicate setBreakpoints()s efforts by checking for matching files in onInputBreak
reimpliment onInputFBreak
remove onInputFClear.  future breakpoints can now be cleared wit the standard clear command.
remove dead onScriptCreated function


git-svn-id: svn://10.0.0.236/trunk@102249 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-05 01:36:44 +00:00
rginda%netscape.com
7b5157ac4c - venkman only -
dont pay attention to scripts without filenames
remove script from the script tree when it is unloaded
if a newly created script matches an existing breakpoint record, add that script to the breakpoint record.
remove obsoleted future breakpoint functions


git-svn-id: svn://10.0.0.236/trunk@102248 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-05 01:34:23 +00:00
rginda%netscape.com
ae5684e0f2 - venkman only -
remove fclear command, future breakpoints now share the same list as normal breakpoints.  the standard clear comman will suffice


git-svn-id: svn://10.0.0.236/trunk@102247 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-05 01:31:56 +00:00
rginda%netscape.com
453f11b043 - venkman only -
reset childIndex and parentRecord on a removed tree item


git-svn-id: svn://10.0.0.236/trunk@102246 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-05 01:30:59 +00:00
ftang%netscape.com
9324fd7c9f back out change of 56863 because it cause 98233
git-svn-id: svn://10.0.0.236/trunk@102244 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-05 01:21:27 +00:00
pschwartau%netscape.com
0fa3d563e6 Skipping two new tests that use non-EMCA functionality: toSource() and uneval().
git-svn-id: svn://10.0.0.236/trunk@102243 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-05 01:07:17 +00:00
bryner%netscape.com
d30e97109d Removing obsolete/unused file. Not part of the build.
git-svn-id: svn://10.0.0.236/trunk@102242 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-05 01:04:31 +00:00
rbs%maths.uq.edu.au
8cedb518ee Back-end to allow viewsource to toggle wrapping of long lines. b=22022 r=bzbarsky sr=jst
git-svn-id: svn://10.0.0.236/trunk@102241 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-05 01:02:58 +00:00
pschwartau%netscape.com
216a755d04 Improved readabilty. Improved accuracy of stripBraces() function.
git-svn-id: svn://10.0.0.236/trunk@102240 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-05 00:49:31 +00:00
bryner%netscape.com
e21ebf8cf6 Removing obsolete/unused file. Not part of the build. r=cls.
git-svn-id: svn://10.0.0.236/trunk@102239 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-05 00:48:43 +00:00
pschwartau%netscape.com
c1a88c8a50 This is more accurate. Also using sorting now, for definiteness in comparisons.
git-svn-id: svn://10.0.0.236/trunk@102238 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-05 00:46:24 +00:00
bryner%netscape.com
e988e3408f Bug 96438 - file name and type descriptions aren't aligned with fields. r=jag, sr=sfraser.
git-svn-id: svn://10.0.0.236/trunk@102237 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-05 00:39:00 +00:00
bryner%netscape.com
79e8b202e3 Oops -- missed adding this code from nsFileWidget. This should fix the beos bustage.
git-svn-id: svn://10.0.0.236/trunk@102236 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-05 00:17:04 +00:00
naving%netscape.com
5c336e927f 96921 r=suresh sr=mscott. fix mlk of nsSupportsArray elements because they were
being addref'ed twice.


git-svn-id: svn://10.0.0.236/trunk@102235 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-05 00:06:30 +00:00
bzbarsky%mit.edu
0f2651a119 Fix the nsIDOMMediaList interface to have the right properties. Make
media rules implement nsIDOMCSSMediaRule.  Fix insertRule() to be able
to insert into the middle of a rule list.  Fix issues with stylesheets
not getting dirtied when media lists are modified.  bug 93977,
r=pierre, sr=jst


git-svn-id: svn://10.0.0.236/trunk@102234 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-05 00:00:18 +00:00
stephend%netscape.com
283731508b Bug 94839. 'Open Web Location dialog shouldn't have an icon'. Patch by Bradley Hart <bhart00@yahoo.com>. r=hwaara, sr=ben
git-svn-id: svn://10.0.0.236/trunk@102232 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-04 23:40:33 +00:00
danm%netscape.com
32c574645c add new file nsAppShellWindowEnumerator. bug 96151 r=hyatt,sfraser
git-svn-id: svn://10.0.0.236/trunk@102231 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-04 23:30:58 +00:00
danm%netscape.com
5a76e32252 add new z-level enumerators. bug 96151 r=hyatt,sfraser
git-svn-id: svn://10.0.0.236/trunk@102230 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-04 23:30:46 +00:00
danm%netscape.com
487aa46a02 move window enumerators to new file; add new z-level enumerators. bug 96151 r=hyatt,sfraser
git-svn-id: svn://10.0.0.236/trunk@102229 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-04 23:30:41 +00:00
cls%seawood.org
a4d3cd95e7 Updating REQUIRES
git-svn-id: svn://10.0.0.236/trunk@102228 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-04 23:30:27 +00:00
danm%netscape.com
bffa3bd421 new implementation for window enumerators, including new z-level enumerators. bug 96151 r=hyatt,sfraser
git-svn-id: svn://10.0.0.236/trunk@102227 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-04 23:30:24 +00:00
naving%netscape.com
8458096beb 67836 r/sr=sspitzer. Use PL_strchr instead of PL_strstr for finding end of line.
git-svn-id: svn://10.0.0.236/trunk@102226 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-04 23:30:06 +00:00
cls%seawood.org
d984e53eff Update REQUIRES
git-svn-id: svn://10.0.0.236/trunk@102225 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-04 23:24:04 +00:00
naving%netscape.com
8f290007b2 97530 r=cavin sr=bienvenu. Save the filterlist if the destination folder for a
filter has been renamed/deleted.


git-svn-id: svn://10.0.0.236/trunk@102224 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-04 23:19:39 +00:00
av%netscape.com
72c385ca9f Fixing bug 86642 -- crash in DOMMimeTypeImpl::DOMMimeTypeImpl() when assigning fields missing from the plugin version stamp, r=peterl, sr=attinasi
git-svn-id: svn://10.0.0.236/trunk@102223 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-04 23:17:48 +00:00
danm%netscape.com
bda3afbc6a ignore width or height of 0 (as in 'width=') when opening windows. bug 67947 r=hyatt,joki
git-svn-id: svn://10.0.0.236/trunk@102222 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-04 23:14:31 +00:00
darin%netscape.com
1a25fee22d fixes bug 59016 "jpg don't display" r=gagan, sr=dougt
git-svn-id: svn://10.0.0.236/trunk@102221 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-04 23:11:46 +00:00
darin%netscape.com
f90e1af576 fixes bug 83526 "http should use fewer connections per server per page"
r=bbaetz sr=dougt,blizzard


git-svn-id: svn://10.0.0.236/trunk@102220 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-04 23:02:26 +00:00
blizzard%redhat.com
2ede81a925 Ongoing new X Remote Code. Not part of the build.
git-svn-id: svn://10.0.0.236/trunk@102219 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-04 23:01:23 +00:00
blizzard%redhat.com
198d4dc6fe Ongoing WIP for new X Remote code. Not part of the build.
git-svn-id: svn://10.0.0.236/trunk@102218 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-04 22:59:39 +00:00
naving%netscape.com
33de6f0e0b 98180 r/sr=sspitzer. Do not preflight the date pikcer w/ current date, if there is already an exisiting
date


git-svn-id: svn://10.0.0.236/trunk@102214 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-04 22:58:12 +00:00
bryner%netscape.com
f5ed2a3be4 Bug 47551 -- removing obsolete nsIFileSpecWithUI and nsIFileWidget. r=pavlov, sr=ben.
git-svn-id: svn://10.0.0.236/trunk@102213 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-04 22:56:38 +00:00
saari%netscape.com
4e08eef5ef checking in mac project changes for bryner, bug 47551
git-svn-id: svn://10.0.0.236/trunk@102212 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-04 22:54:02 +00:00
rogerl%netscape.com
6a5d50c542 Added setXXX funciton implementations.
git-svn-id: svn://10.0.0.236/trunk@102210 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-04 22:07:32 +00:00
rogerl%netscape.com
88a6e5c796 Added jsdate & prmjtime to build.
git-svn-id: svn://10.0.0.236/trunk@102209 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-04 21:10:21 +00:00
rogerl%netscape.com
9778122dbe Fix for apparent missing region compare in gcc version of basic_string.
git-svn-id: svn://10.0.0.236/trunk@102208 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-04 21:02:10 +00:00
relyea%netscape.com
2b8b0be222 Don't skip certs that are already in the database. We may have to tweak
with the trust bits.


git-svn-id: svn://10.0.0.236/trunk@102207 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-04 20:20:48 +00:00
relyea%netscape.com
2d76d3deb0 Allow 'importing' certificates that already exist in the database.
Use the import to change the trust flags on the given certificate.


git-svn-id: svn://10.0.0.236/trunk@102206 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-04 20:19:26 +00:00
mcgreer%netscape.com
eb6d8a3074 checkin for colin@theblakes.com, OpenVMS fix
r=javi,sr=cls,a=dbaron


git-svn-id: svn://10.0.0.236/trunk@102205 18797224-902f-48f8-a5cc-f745e15eee43
2001-09-04 14:51:08 +00:00
97 changed files with 12441 additions and 8125 deletions

View File

@@ -1,78 +0,0 @@
/* ***** BEGIN LICENSE BLOCK *****
* Version: MPL 1.1/GPL 2.0/LGPL 2.1
*
* The contents of this file are subject to the Mozilla Public License Version
* 1.1 (the "License"); you may not use this file except in compliance with
* the License. You may obtain a copy of the License at
* http://www.mozilla.org/MPL/
*
* Software distributed under the License is distributed on an "AS IS" basis,
* WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
* for the specific language governing rights and limitations under the
* License.
*
* The Original Code is mozilla.org code.
*
* The Initial Developer of the Original Code is
* Netscape Communications Corporation.
* Portions created by the Initial Developer are Copyright (C) 2001
* the Initial Developer. All Rights Reserved.
*
* Contributor(s):
* Srilatha Moturi <srilatha@netscape.com>
*
* Alternatively, the contents of this file may be used under the terms of
* either the GNU General Public License Version 2 or later (the "GPL"), or
* the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
* in which case the provisions of the GPL or the LGPL are applicable instead
* of those above. If you wish to allow use of your version of this file only
* under the terms of either the GPL or the LGPL, and not to allow others to
* use your version of this file under the terms of the MPL, indicate your
* decision by deleting the provisions above and replace them with the notice
* and other provisions required by the GPL or the LGPL. If you do not delete
* the provisions above, a recipient may use your version of this file under
* the terms of any one of the MPL, the GPL or the LGPL.
*
* ***** END LICENSE BLOCK ***** */
#include "nsISupports.idl"
interface nsIDOMWindow;
/**
* This interface provides support for registering Mozilla as the default
* Mail Client. This interface can also be used to get/set the user preference
* for the default Mail Client.
*
*/
[scriptable, uuid(c5be14ba-4e0a-4eec-a1b8-04363761d63c)]
interface nsIMapiRegistry: nsISupports {
/** This is set to TRUE if Mozilla is the default Application
*/
readonly attribute boolean isDefaultMailClient;
/** This is set TRUE only once per session.
*/
readonly attribute boolean showDialog;
/** This will update the registry keys to set Mozilla as default Mail Client.
*/
void setDefaultMailClient();
/** This will reset the registry keys for the default Mail Client.
*/
void unsetDefaultMailClient();
/** This will bring the dialog asking the user if he/she wants to set
* Mozilla as default Mail Client.
* Call this only if Mozilla is not the default Mail client
*/
void showMailIntegrationDialog(in nsIDOMWindow parentWindow);
};
%{C++
#define NS_IMAPIWINHOOK_CONTRACTID "@mozilla.org/mapiregistry;1"
#define NS_IMAPIWINHOOK_CLASSNAME "Mozilla MAPI Registry"
%}

View File

@@ -1,57 +0,0 @@
<!doctype html public "-//w3c//dtd html 4.0 transitional//en">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
<meta name="Generator" content="Microsoft Word 97">
<meta name="GENERATOR" content="Mozilla/4.7 [en] (WinNT; U) [Netscape]">
</head>
<body>
<blockquote><b><u><font face="Arial"><font size=+0>Instruction for using
the MAPI_SUPP_BRANCH for the Mapi Support feature</font></font></u></b></blockquote>
<ol>
<li>
<font face="Arial"><font size=+0>Get the latest 0.94 branch or the the
trunk and build it</font></font></li>
</ol>
<ol>
<li>
<font face="Arial"><font size=+0>Now go to the dir where u have mozilla
and get the branch from Mapi, do :</font></font></li>
</ol>
<font face="Arial"><font size=+0>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
"cvs co -rMAPI_SUPP_BRANCH mozilla/mailnews/mapi".</font></font>
<p><font face="Arial"><font size=+0>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
This will get the latest branch for mapi support. The branch MAPI_SUPP_BRANCH
for mapi support is NOT the full tree,</font></font>
<br><i><font face="Arial"><font size=+0>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
it is just the mapi&nbsp; dir within mozilla/mailnews.</font></font></i>
<ol>
<li>
<font face="Arial"><font size=+0>Go to mozilla/mailnews/mapi, build the
mapi dir : 'nmake -f makefile.win'.&nbsp; This completes the building part.</font></font></li>
</ol>
<ol>
<li>
<font face="Arial"><font size=+0>Now run mozilla from your build. Go to
menuitem Edit/Preferences, this will&nbsp; bring up the Preferences dialog.
Go to category Mail &amp; NewsGroups. In the General setting section u
will see the checkbox 'Use Mozilla Mail as the default mail application.'
Check the checkbox to enable the MAPI support in Mozilla and close the
Prefs dialog.</font></font></li>
</ol>
<ol>
<li>
<font face="Arial"><font size=+0>You are now ready to test the mozilla's
MAPI support. Run Word, WordPad, Powerpoint, or Excel. Open a document
in the app and do File/Send from the app. You should see the Mozilla mailnews
compose window come up with your document attached to the opened mail.
Type in the recipients (To, Cc, etc) and send the mail.</font></font></li>
</ol>
</body>
</html>

View File

@@ -1,47 +0,0 @@
; ***** BEGIN LICENSE BLOCK *****
; Version: MPL 1.1/GPL 2.0/LGPL 2.1
;
; The contents of this file are subject to the Mozilla Public License Version
; 1.1 (the "License"); you may not use this file except in compliance with
; the License. You may obtain a copy of the License at
; http://www.mozilla.org/MPL/
;
; Software distributed under the License is distributed on an "AS IS" basis,
; WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
; for the specific language governing rights and limitations under the
; License.
;
; The Original Code is Mozilla.
;
; The Initial Developer of the Original Code is
; Netscape Communications Corp.
; Portions created by the Initial Developer are Copyright (C) 2001
; the Initial Developer. All Rights Reserved.
;
; Contributor(s): Krishna Mohan Khandrika (kkhandrika@netscape.com)
;
; Alternatively, the contents of this file may be used under the terms of
; either the GNU General Public License Version 2 or later (the "GPL"), or
; the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
; in which case the provisions of the GPL or the LGPL are applicable instead
; of those above. If you wish to allow use of your version of this file only
; under the terms of either the GPL or the LGPL, and not to allow others to
; use your version of this file under the terms of the MPL, indicate your
; decision by deleting the provisions above and replace them with the notice
; and other provisions required by the GPL or the LGPL. If you do not delete
; the provisions above, a recipient may use your version of this file under
; the terms of any one of the MPL, the GPL or the LGPL.
;
; ***** END LICENSE BLOCK *****
LIBRARY MapiProxy.dll
DESCRIPTION 'Proxy/Stub DLL'
EXPORTS
DllGetClassObject @1 PRIVATE
DllCanUnloadNow @2 PRIVATE
GetProxyDllInfo @3 PRIVATE
DllRegisterServer @4 PRIVATE
DllUnregisterServer @5 PRIVATE

View File

@@ -1,68 +0,0 @@
# ***** BEGIN LICENSE BLOCK *****
# Version: MPL 1.1/GPL 2.0/LGPL 2.1
#
# The contents of this file are subject to the Mozilla Public License Version
# 1.1 (the "License"); you may not use this file except in compliance with
# the License. You may obtain a copy of the License at
# http://www.mozilla.org/MPL/
#
# Software distributed under the License is distributed on an "AS IS" basis,
# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
# for the specific language governing rights and limitations under the
# License.
#
# The Original Code is Mozilla.
#
# The Initial Developer of the Original Code is
# Netscape Communications Corp.
# Portions created by the Initial Developer are Copyright (C) 2001
# the Initial Developer. All Rights Reserved.
#
# Contributor(s): Krishna Mohan Khandrika (kkhandrika@netscape.com)
#
# Alternatively, the contents of this file may be used under the terms of
# either the GNU General Public License Version 2 or later (the "GPL"), or
# the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
# in which case the provisions of the GPL or the LGPL are applicable instead
# of those above. If you wish to allow use of your version of this file only
# under the terms of either the GPL or the LGPL, and not to allow others to
# use your version of this file under the terms of the MPL, indicate your
# decision by deleting the provisions above and replace them with the notice
# and other provisions required by the GPL or the LGPL. If you do not delete
# the provisions above, a recipient may use your version of this file under
# the terms of any one of the MPL, the GPL or the LGPL.
#
# ***** END LICENSE BLOCK *****
DEPTH=..\..\..
MODULE = MapiProxy
EXPORT_LIBRARY = $(MODULE)
LIBRARY_NAME = $(MODULE)
DEFFILE = MapiProxy.def
include <$(DEPTH)\config\config.mak>
##################################################################
LCFLAGS=-DREGISTER_PROXY_DLL -DUNICODE -D_UNICODE
OBJS= .\$(OBJDIR)\dlldata.obj \
.\$(OBJDIR)\msgMapi_p.obj \
.\$(OBJDIR)\msgMapi_i.obj \
$(NULL)
WIN_LIBS= rpcrt4.lib
EXPORTS= msgMapi.h \
$(NULL)
include <$(DEPTH)\config\rules.mak>
msgMapi.h msgMapi_p.c msgMapi_i.c dlldata.c : msgMapi.idl
midl $(UNICODE_FLAGS) msgMapi.idl
clobber::
rm -f dlldata.c msgMapi_i.c msgMapi_p.c msgMapi.h

View File

@@ -1,114 +0,0 @@
/* ***** BEGIN LICENSE BLOCK *****
* Version: MPL 1.1/GPL 2.0/LGPL 2.1
*
* The contents of this file are subject to the Mozilla Public License Version
* 1.1 (the "License"); you may not use this file except in compliance with
* the License. You may obtain a copy of the License at
* http://www.mozilla.org/MPL/
*
* Software distributed under the License is distributed on an "AS IS" basis,
* WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
* for the specific language governing rights and limitations under the
* License.
*
* The Original Code is Mozilla
*
* The Initial Developer of the Original Code is
* Netscape Communications Corp.
* Portions created by the Initial Developer are Copyright (C) 2001
* the Initial Developer. All Rights Reserved.
*
* Contributor(s): Krishna Mohan Khandrika (kkhandrika@netscape.com)
* Contributor(s): Rajiv Dayal (rdayal@netscape.com)
*
* Alternatively, the contents of this file may be used under the terms of
* either the GNU General Public License Version 2 or later (the "GPL"), or
* the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
* in which case the provisions of the GPL or the LGPL are applicable instead
* of those above. If you wish to allow use of your version of this file only
* under the terms of either the GPL or the LGPL, and not to allow others to
* use your version of this file under the terms of the MPL, indicate your
* decision by deleting the provisions above and replace them with the notice
* and other provisions required by the GPL or the LGPL. If you do not delete
* the provisions above, a recipient may use your version of this file under
* the terms of any one of the MPL, the GPL or the LGPL.
*
* ***** END LICENSE BLOCK ***** */
// This idl will be compiled by MIDL. MS-COM is used
// as brdige between MAPI clients and the Mozilla.
import "unknwn.idl";
typedef wchar_t LOGIN_PW_TYPE[256];
typedef struct
{
unsigned long ulReserved;
unsigned long flFlags; /* Flags */
unsigned long nPosition_NotUsed; /* character in text to be replaced by attachment */
LPTSTR lpszPathName; /* Full path name including file name */
LPTSTR lpszFileName; /* Real (original) file name */
unsigned char * lpFileType_NotUsed ;
} nsMapiFileDesc, * lpnsMapiFileDesc;
typedef struct
{
unsigned long ulReserved;
unsigned long ulRecipClass; /* MAPI_TO, MAPI_CC, MAPI_BCC, MAPI_ORIG */
LPTSTR lpszName; /* Recipient name to display */
LPTSTR lpszAddress; /* Recipient email address */
unsigned long ulEIDSize_NotUsed;
unsigned char * lpEntryID_NotUsed ;
} nsMapiRecipDesc, * lpnsMapiRecipDesc;
typedef struct
{
unsigned long ulReserved;
LPTSTR lpszSubject; /* Message Subject */
LPTSTR lpszNoteText; /* Message Text */
LPTSTR lpszMessageType_NotUsed;
LPTSTR lpszDateReceived_notUsed; /* in YYYY/MM/DD HH:MM format */
LPTSTR lpszConversationID_NotUsed; /* conversation thread ID */
unsigned long flFlags; /* unread,return receipt */
lpnsMapiRecipDesc lpOriginator; /* Originator descriptor */
unsigned long nRecipCount; /* Number of recipients */
lpnsMapiRecipDesc lpRecips; /* Recipient descriptors */
unsigned long nFileCount; /* # of file attachments */
lpnsMapiFileDesc lpFiles; /* Attachment descriptors */
} nsMapiMessage, * lpnsMapiMessage;
[
object,
uuid(6EDCD38E-8861-11d5-A3DD-00B0D0F3BAA7),
helpstring("nsIMapi Inteface"),
pointer_default(unique)
]
interface nsIMapi : IUnknown
{
HRESULT Login(unsigned long aUIArg, LOGIN_PW_TYPE aLogin,
LOGIN_PW_TYPE aPassWord, unsigned long aFlags,
[out] unsigned long *aSessionId);
HRESULT Initialize();
HRESULT IsValid();
HRESULT IsValidSession([in] unsigned long aSession);
HRESULT SendMail([in] unsigned long aSession, [in] lpnsMapiMessage aMessage,
[in] short aRecipCount, [in, size_is(aRecipCount)] lpnsMapiRecipDesc aRecips,
[in] short aFileCount, [in, size_is(aFileCount)] lpnsMapiFileDesc aFiles,
[in] unsigned long aFlags, [in] unsigned long aReserved) ;
HRESULT SendDocuments( [in] unsigned long aSession,
[in] LPTSTR aDelimChar, [in] LPTSTR aFilePaths,
[in] LPTSTR aFileNames, [in] ULONG aFlags ) ;
HRESULT Logoff (unsigned long aSession);
HRESULT CleanUp();
};

View File

@@ -1,4 +1,4 @@
# !nmake
#
# The contents of this file are subject to the Mozilla Public
# License Version 1.1 (the "License"); you may not use this file
# except in compliance with the License. You may obtain a copy of
@@ -17,11 +17,12 @@
# Rights Reserved.
#
# Contributor(s):
# Srilatha Moturi <srilatha@netscape.com>
# Krishna Mohan Khandrika <kkhandrika@netscape.com>
#
DEPTH=..\..
DIRS=build mapiDll mapihook resources registry
DIRS=mapihook resources mapiDll
include <$(DEPTH)\config\rules.mak>

View File

@@ -41,11 +41,18 @@ EXPORT_LIBRARY = $(MODULE)
LIBRARY_NAME = $(MODULE)
DEFFILE = Mapi32.def
REQUIRES = MapiProxy \
msgMapi \
xpcom \
string \
$(NULL)
include <$(DEPTH)\config\config.mak>
###############################################################
LCFLAGS=-DUNICODE -D_UNICODE
OBJS= .\$(OBJDIR)\MapiDll.obj
WIN_LIBS= ole32.lib

View File

@@ -1,47 +0,0 @@
; ***** BEGIN LICENSE BLOCK *****
; Version: MPL 1.1/GPL 2.0/LGPL 2.1
;
; The contents of this file are subject to the Mozilla Public License Version
; 1.1 (the "License"); you may not use this file except in compliance with
; the License. You may obtain a copy of the License at
; http://www.mozilla.org/MPL/
;
; Software distributed under the License is distributed on an "AS IS" basis,
; WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
; for the specific language governing rights and limitations under the
; License.
;
; The Original Code is Mozilla.
;
; The Initial Developer of the Original Code is
; Netscape Communications Corp.
; Portions created by the Initial Developer are Copyright (C) 2001
; the Initial Developer. All Rights Reserved.
;
; Contributor(s): Krishna Mohan Khandrika (kkhandrika@netscape.com)
;
; Alternatively, the contents of this file may be used under the terms of
; either the GNU General Public License Version 2 or later (the "GPL"), or
; the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
; in which case the provisions of the GPL or the LGPL are applicable instead
; of those above. If you wish to allow use of your version of this file only
; under the terms of either the GPL or the LGPL, and not to allow others to
; use your version of this file under the terms of the MPL, indicate your
; decision by deleting the provisions above and replace them with the notice
; and other provisions required by the GPL or the LGPL. If you do not delete
; the provisions above, a recipient may use your version of this file under
; the terms of any one of the MPL, the GPL or the LGPL.
;
; ***** END LICENSE BLOCK *****
LIBRARY MapiProxy.dll
DESCRIPTION 'Proxy/Stub DLL'
EXPORTS
DllGetClassObject @1 PRIVATE
DllCanUnloadNow @2 PRIVATE
GetProxyDllInfo @3 PRIVATE
DllRegisterServer @4 PRIVATE
DllUnregisterServer @5 PRIVATE

View File

@@ -1,68 +0,0 @@
# ***** BEGIN LICENSE BLOCK *****
# Version: MPL 1.1/GPL 2.0/LGPL 2.1
#
# The contents of this file are subject to the Mozilla Public License Version
# 1.1 (the "License"); you may not use this file except in compliance with
# the License. You may obtain a copy of the License at
# http://www.mozilla.org/MPL/
#
# Software distributed under the License is distributed on an "AS IS" basis,
# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
# for the specific language governing rights and limitations under the
# License.
#
# The Original Code is Mozilla.
#
# The Initial Developer of the Original Code is
# Netscape Communications Corp.
# Portions created by the Initial Developer are Copyright (C) 2001
# the Initial Developer. All Rights Reserved.
#
# Contributor(s): Krishna Mohan Khandrika (kkhandrika@netscape.com)
#
# Alternatively, the contents of this file may be used under the terms of
# either the GNU General Public License Version 2 or later (the "GPL"), or
# the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
# in which case the provisions of the GPL or the LGPL are applicable instead
# of those above. If you wish to allow use of your version of this file only
# under the terms of either the GPL or the LGPL, and not to allow others to
# use your version of this file under the terms of the MPL, indicate your
# decision by deleting the provisions above and replace them with the notice
# and other provisions required by the GPL or the LGPL. If you do not delete
# the provisions above, a recipient may use your version of this file under
# the terms of any one of the MPL, the GPL or the LGPL.
#
# ***** END LICENSE BLOCK *****
DEPTH=..\..\..
MODULE = MapiProxy
EXPORT_LIBRARY = $(MODULE)
LIBRARY_NAME = $(MODULE)
DEFFILE = MapiProxy.def
include <$(DEPTH)\config\config.mak>
##################################################################
LCFLAGS=-DREGISTER_PROXY_DLL -DUNICODE -D_UNICODE
OBJS= .\$(OBJDIR)\dlldata.obj \
.\$(OBJDIR)\msgMapi_p.obj \
.\$(OBJDIR)\msgMapi_i.obj \
$(NULL)
WIN_LIBS= rpcrt4.lib
EXPORTS= msgMapi.h \
$(NULL)
include <$(DEPTH)\config\rules.mak>
msgMapi.h msgMapi_p.c msgMapi_i.c dlldata.c : msgMapi.idl
midl $(UNICODE_FLAGS) msgMapi.idl
clobber::
rm -f dlldata.c msgMapi_i.c msgMapi_p.c msgMapi.h

View File

@@ -1,114 +0,0 @@
/* ***** BEGIN LICENSE BLOCK *****
* Version: MPL 1.1/GPL 2.0/LGPL 2.1
*
* The contents of this file are subject to the Mozilla Public License Version
* 1.1 (the "License"); you may not use this file except in compliance with
* the License. You may obtain a copy of the License at
* http://www.mozilla.org/MPL/
*
* Software distributed under the License is distributed on an "AS IS" basis,
* WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
* for the specific language governing rights and limitations under the
* License.
*
* The Original Code is Mozilla
*
* The Initial Developer of the Original Code is
* Netscape Communications Corp.
* Portions created by the Initial Developer are Copyright (C) 2001
* the Initial Developer. All Rights Reserved.
*
* Contributor(s): Krishna Mohan Khandrika (kkhandrika@netscape.com)
* Contributor(s): Rajiv Dayal (rdayal@netscape.com)
*
* Alternatively, the contents of this file may be used under the terms of
* either the GNU General Public License Version 2 or later (the "GPL"), or
* the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
* in which case the provisions of the GPL or the LGPL are applicable instead
* of those above. If you wish to allow use of your version of this file only
* under the terms of either the GPL or the LGPL, and not to allow others to
* use your version of this file under the terms of the MPL, indicate your
* decision by deleting the provisions above and replace them with the notice
* and other provisions required by the GPL or the LGPL. If you do not delete
* the provisions above, a recipient may use your version of this file under
* the terms of any one of the MPL, the GPL or the LGPL.
*
* ***** END LICENSE BLOCK ***** */
// This idl will be compiled by MIDL. MS-COM is used
// as brdige between MAPI clients and the Mozilla.
import "unknwn.idl";
typedef wchar_t LOGIN_PW_TYPE[256];
typedef struct
{
unsigned long ulReserved;
unsigned long flFlags; /* Flags */
unsigned long nPosition_NotUsed; /* character in text to be replaced by attachment */
LPTSTR lpszPathName; /* Full path name including file name */
LPTSTR lpszFileName; /* Real (original) file name */
unsigned char * lpFileType_NotUsed ;
} nsMapiFileDesc, * lpnsMapiFileDesc;
typedef struct
{
unsigned long ulReserved;
unsigned long ulRecipClass; /* MAPI_TO, MAPI_CC, MAPI_BCC, MAPI_ORIG */
LPTSTR lpszName; /* Recipient name to display */
LPTSTR lpszAddress; /* Recipient email address */
unsigned long ulEIDSize_NotUsed;
unsigned char * lpEntryID_NotUsed ;
} nsMapiRecipDesc, * lpnsMapiRecipDesc;
typedef struct
{
unsigned long ulReserved;
LPTSTR lpszSubject; /* Message Subject */
LPTSTR lpszNoteText; /* Message Text */
LPTSTR lpszMessageType_NotUsed;
LPTSTR lpszDateReceived_notUsed; /* in YYYY/MM/DD HH:MM format */
LPTSTR lpszConversationID_NotUsed; /* conversation thread ID */
unsigned long flFlags; /* unread,return receipt */
lpnsMapiRecipDesc lpOriginator; /* Originator descriptor */
unsigned long nRecipCount; /* Number of recipients */
lpnsMapiRecipDesc lpRecips; /* Recipient descriptors */
unsigned long nFileCount; /* # of file attachments */
lpnsMapiFileDesc lpFiles; /* Attachment descriptors */
} nsMapiMessage, * lpnsMapiMessage;
[
object,
uuid(6EDCD38E-8861-11d5-A3DD-00B0D0F3BAA7),
helpstring("nsIMapi Inteface"),
pointer_default(unique)
]
interface nsIMapi : IUnknown
{
HRESULT Login(unsigned long aUIArg, LOGIN_PW_TYPE aLogin,
LOGIN_PW_TYPE aPassWord, unsigned long aFlags,
[out] unsigned long *aSessionId);
HRESULT Initialize();
HRESULT IsValid();
HRESULT IsValidSession([in] unsigned long aSession);
HRESULT SendMail([in] unsigned long aSession, [in] lpnsMapiMessage aMessage,
[in] short aRecipCount, [in, size_is(aRecipCount)] lpnsMapiRecipDesc aRecips,
[in] short aFileCount, [in, size_is(aFileCount)] lpnsMapiFileDesc aFiles,
[in] unsigned long aFlags, [in] unsigned long aReserved) ;
HRESULT SendDocuments( [in] unsigned long aSession,
[in] LPTSTR aDelimChar, [in] LPTSTR aFilePaths,
[in] LPTSTR aFileNames, [in] ULONG aFlags ) ;
HRESULT Logoff (unsigned long aSession);
HRESULT CleanUp();
};

View File

@@ -1,77 +1,26 @@
# ***** BEGIN LICENSE BLOCK *****
# Version: MPL 1.1/GPL 2.0/LGPL 2.1
#!nmake
#
# The contents of this file are subject to the Mozilla Public License Version
# 1.1 (the "License"); you may not use this file except in compliance with
# the License. You may obtain a copy of the License at
# http://www.mozilla.org/MPL/
# The contents of this file are subject to the Netscape Public
# License Version 1.1 (the "License"); you may not use this file
# except in compliance with the License. You may obtain a copy of
# the License at http://www.mozilla.org/NPL/
#
# Software distributed under the License is distributed on an "AS IS" basis,
# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
# for the specific language governing rights and limitations under the
# License.
# Software distributed under the License is distributed on an "AS
# IS" basis, WITHOUT WARRANTY OF ANY KIND, either express or
# implied. See the License for the specific language governing
# rights and limitations under the License.
#
# The Original Code is Mozilla.
# The Original Code is mozilla.org code.
#
# The Initial Developer of the Original Code is
# Netscape Communications Corp.
# Portions created by the Initial Developer are Copyright (C) 2001
# the Initial Developer. All Rights Reserved.
# The Initial Developer of the Original Code is Netscape
# Communications Corporation. Portions created by Netscape are
# Copyright (C) 1998 Netscape Communications Corporation. All
# Rights Reserved.
#
# Contributor(s): Srilatha Moturi (srilatha@netscape.com)
#
# Alternatively, the contents of this file may be used under the terms of
# either the GNU General Public License Version 2 or later (the "GPL"), or
# the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
# in which case the provisions of the GPL or the LGPL are applicable instead
# of those above. If you wish to allow use of your version of this file only
# under the terms of either the GPL or the LGPL, and not to allow others to
# use your version of this file under the terms of the MPL, indicate your
# decision by deleting the provisions above and replace them with the notice
# and other provisions required by the GPL or the LGPL. If you do not delete
# the provisions above, a recipient may use your version of this file under
# the terms of any one of the MPL, the GPL or the LGPL.
#
# ***** END LICENSE BLOCK *****
# Contributor(s): kkhandrika@netscape.com
DEPTH=..\..\..
MODULE = msgMapi
EXPORT_LIBRARY = $(MODULE)
LIBRARY_NAME = $(MODULE)
include <$(DEPTH)\config\config.mak>
############################################################################
REQUIRES = xpcom \
string \
$(NULL)
LCFLAGS=-DUNICODE -D_UNICODE
OBJS= \
..\build\$(OBJDIR)\msgMapi_i.obj \
.\$(OBJDIR)\msgMapiFactory.obj \
.\$(OBJDIR)\msgMapiHook.obj \
.\$(OBJDIR)\msgMapiImp.obj \
.\$(OBJDIR)\msgMapiMain.obj \
.\$(OBJDIR)\msgMapiSupport.obj \
$(NULL)
LLIBS= \
$(DIST)\lib\xpcom.lib \
$(DIST)\lib\msgbsutl.lib \
$(LIBNSPR) \
$(NULL)
WIN_LIBS= ole32.lib
EXPORTS= \
msgMapiFactory.h \
msgMapiHook.h \
msgMapiImp.h \
msgMapiMain.h \
msgMapiSupport.h \
$(NULL)
DIRS= build public src
include <$(DEPTH)\config\rules.mak>

View File

@@ -1,121 +0,0 @@
/* ***** BEGIN LICENSE BLOCK *****
* Version: MPL 1.1/GPL 2.0/LGPL 2.1
*
* The contents of this file are subject to the Mozilla Public License Version
* 1.1 (the "License"); you may not use this file except in compliance with
* the License. You may obtain a copy of the License at
* http://www.mozilla.org/MPL/
*
* Software distributed under the License is distributed on an "AS IS" basis,
* WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
* for the specific language governing rights and limitations under the
* License.
*
* The Original Code is Mozilla
*
* The Initial Developer of the Original Code is
* Netscape Communications Corp.
* Portions created by the Initial Developer are Copyright (C) 2001
* the Initial Developer. All Rights Reserved.
*
* Contributor(s): Krishna Mohan Khandrika (kkhandrika@netscape.com)
*
* Alternatively, the contents of this file may be used under the terms of
* either the GNU General Public License Version 2 or later (the "GPL"), or
* the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
* in which case the provisions of the GPL or the LGPL are applicable instead
* of those above. If you wish to allow use of your version of this file only
* under the terms of either the GPL or the LGPL, and not to allow others to
* use your version of this file under the terms of the MPL, indicate your
* decision by deleting the provisions above and replace them with the notice
* and other provisions required by the GPL or the LGPL. If you do not delete
* the provisions above, a recipient may use your version of this file under
* the terms of any one of the MPL, the GPL or the LGPL.
*
* ***** END LICENSE BLOCK ***** */
#undef UNICODE
#undef _UNICODE
#include "msgMapiFactory.h"
#include "msgMapiImp.h"
#include "msgMapi.h"
const CLSID CLSID_nsMapiImp = {0x29f458be, 0x8866, 0x11d5, {0xa3, 0xdd, 0x0, 0xb0, 0xd0, 0xf3, 0xba, 0xa7}};
nsMapiFactory::nsMapiFactory()
: m_cRef(1)
{
}
nsMapiFactory::~nsMapiFactory()
{
}
STDMETHODIMP nsMapiFactory::QueryInterface(const IID& aIid, void** aPpv)
{
if ((aIid == IID_IUnknown) || (aIid == IID_IClassFactory))
{
*aPpv = static_cast<IClassFactory*>(this);
}
else
{
*aPpv = nsnull;
return E_NOINTERFACE;
}
reinterpret_cast<IUnknown*>(*aPpv)->AddRef();
return S_OK;
}
STDMETHODIMP_(ULONG) nsMapiFactory::AddRef()
{
return (PR_AtomicIncrement(&m_cRef));
}
STDMETHODIMP_(ULONG) nsMapiFactory::Release()
{
PRInt32 temp;
temp = PR_AtomicDecrement(&m_cRef);
if (m_cRef == 0)
{
delete this;
return 0;
}
return temp;
}
STDMETHODIMP nsMapiFactory::CreateInstance(IUnknown* aUnknownOuter,
const IID& aIid,
void** aPpv)
{
// Cannot aggregate.
if (aUnknownOuter != nsnull)
{
return CLASS_E_NOAGGREGATION ;
}
// Create component.
nsMapiImp* pImp = new nsMapiImp();
if (pImp == nsnull)
{
return E_OUTOFMEMORY ;
}
// Get the requested interface.
HRESULT hr = pImp->QueryInterface(aIid, aPpv);
// Release the IUnknown pointer.
// (If QueryInterface failed, component will delete itself.)
pImp->Release();
return hr;
}
STDMETHODIMP nsMapiFactory::LockServer(PRBool aLock)
{
return S_OK ;
}

View File

@@ -1,69 +0,0 @@
/* ***** BEGIN LICENSE BLOCK *****
* Version: MPL 1.1/GPL 2.0/LGPL 2.1
*
* The contents of this file are subject to the Mozilla Public License Version
* 1.1 (the "License"); you may not use this file except in compliance with
* the License. You may obtain a copy of the License at
* http://www.mozilla.org/MPL/
*
* Software distributed under the License is distributed on an "AS IS" basis,
* WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
* for the specific language governing rights and limitations under the
* License.
*
* The Original Code is Mozilla
*
* The Initial Developer of the Original Code is
* Netscape Communications Corp.
* Portions created by the Initial Developer are Copyright (C) 2001
* the Initial Developer. All Rights Reserved.
*
* Contributor(s): Krishna Mohan Khandrika (kkhandrika@netscape.com)
*
* Alternatively, the contents of this file may be used under the terms of
* either the GNU General Public License Version 2 or later (the "GPL"), or
* the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
* in which case the provisions of the GPL or the LGPL are applicable instead
* of those above. If you wish to allow use of your version of this file only
* under the terms of either the GPL or the LGPL, and not to allow others to
* use your version of this file under the terms of the MPL, indicate your
* decision by deleting the provisions above and replace them with the notice
* and other provisions required by the GPL or the LGPL. If you do not delete
* the provisions above, a recipient may use your version of this file under
* the terms of any one of the MPL, the GPL or the LGPL.
*
* ***** END LICENSE BLOCK ***** */
#ifndef MSG_MAPI_FACTORY_H
#define MSG_MAPI_FACTORY_H
#include <windows.h>
#include <objbase.h>
#include "nspr.h"
class nsMapiFactory : public IClassFactory
{
public :
// IUnknown
STDMETHODIMP QueryInterface (REFIID aIid, void** aPpv);
STDMETHODIMP_(ULONG) AddRef(void);
STDMETHODIMP_(ULONG) Release(void);
// IClassFactory
STDMETHODIMP CreateInstance (LPUNKNOWN aUnkOuter, REFIID aIid, void **aPpv);
STDMETHODIMP LockServer (BOOL aLock);
nsMapiFactory();
~nsMapiFactory();
private :
PRInt32 m_cRef;
};
#endif // MSG_MAPI_FACTORY_H

View File

@@ -1,842 +0,0 @@
/* ***** BEGIN LICENSE BLOCK *****
* Version: MPL 1.1/GPL 2.0/LGPL 2.1
*
* The contents of this file are subject to the Mozilla Public License Version
* 1.1 (the "License"); you may not use this file except in compliance with
* the License. You may obtain a copy of the License at
* http://www.mozilla.org/MPL/
*
* Software distributed under the License is distributed on an "AS IS" basis,
* WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
* for the specific language governing rights and limitations under the
* License.
*
* The Original Code is Mozilla
*
* The Initial Developer of the Original Code is
* Netscape Communications Corp.
* Portions created by the Initial Developer are Copyright (C) 2001
* the Initial Developer. All Rights Reserved.
*
* Contributor(s): Krishna Mohan Khandrika (kkhandrika@netscape.com)
* Contributor(s): Srilatha Moturi (srilatha@netscape.com)
* Contributor(s): Rajiv Dayal (rdayal@netscape.com)
*
* Alternatively, the contents of this file may be used under the terms of
* either the GNU General Public License Version 2 or later (the "GPL"), or
* the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
* in which case the provisions of the GPL or the LGPL are applicable instead
* of those above. If you wish to allow use of your version of this file only
* under the terms of either the GPL or the LGPL, and not to allow others to
* use your version of this file under the terms of the MPL, indicate your
* decision by deleting the provisions above and replace them with the notice
* and other provisions required by the GPL or the LGPL. If you do not delete
* the provisions above, a recipient may use your version of this file under
* the terms of any one of the MPL, the GPL or the LGPL.
*
* ***** END LICENSE BLOCK ***** */
#define MAPI_STARTUP_ARG "/MAPIStartUp"
#define MAPI_STARTUP_ARG "/MAPIStartUp"
#include <mapidefs.h>
#include <mapi.h>
#include "nsCOMPtr.h"
#include "nsIComponentManager.h"
#include "nsIServiceManager.h"
#include "nsISupports.h"
#include "nsIPromptService.h"
#include "nsAppShellCIDs.h"
#include "nsIDOMWindowInternal.h"
#include "nsIAppShellService.h"
#include "nsINativeAppSupport.h"
#include "nsICmdLineService.h"
#include "nsIProfileInternal.h"
#include "nsIMsgAccountManager.h"
#include "nsIDOMWindowInternal.h"
#include "nsXPIDLString.h"
#include "nsReadableUtils.h"
#include "nsMsgBaseCID.h"
#include "nsIStringBundle.h"
#include "nsIPref.h"
#include "nsString.h"
#include "nsIMsgCompFields.h"
#include "nsIMsgComposeParams.h"
#include "nsIMsgCompose.h"
#include "nsMsgCompCID.h"
#include "nsIMsgSend.h"
#include "nsIProxyObjectManager.h"
#include "nsIMsgComposeService.h"
#include "nsProxiedService.h"
#include "nsSpecialSystemDirectory.h"
#include "nsMsgI18N.h"
#include "msgMapi.h"
#include "msgMapiHook.h"
#include "msgMapiSupport.h"
#include "msgMapiMain.h"
static NS_DEFINE_CID(kCmdLineServiceCID, NS_COMMANDLINE_SERVICE_CID);
#define MAPI_PROPERTIES_CHROME "chrome://messenger/locale/mapi.properties"
#define PREF_MAPI_WARN_PRIOR_TO_BLIND_SEND "mapi.blind-send.warn"
#define PREF_MAPI_BLIND_SEND_ENABLED "mapi.blind-send.enabled"
class nsMAPISendListener : public nsIMsgSendListener
{
public:
virtual ~nsMAPISendListener() { }
// nsISupports interface
NS_DECL_ISUPPORTS
/* void OnStartSending (in string aMsgID, in PRUint32 aMsgSize); */
NS_IMETHOD OnStartSending(const char *aMsgID, PRUint32 aMsgSize) { return NS_OK; }
/* void OnProgress (in string aMsgID, in PRUint32 aProgress, in PRUint32 aProgressMax); */
NS_IMETHOD OnProgress(const char *aMsgID, PRUint32 aProgress, PRUint32 aProgressMax) { return NS_OK;}
/* void OnStatus (in string aMsgID, in wstring aMsg); */
NS_IMETHOD OnStatus(const char *aMsgID, const PRUnichar *aMsg) { return NS_OK;}
/* void OnStopSending (in string aMsgID, in nsresult aStatus, in wstring aMsg, in nsIFileSpec returnFileSpec); */
NS_IMETHOD OnStopSending(const char *aMsgID, nsresult aStatus, const PRUnichar *aMsg,
nsIFileSpec *returnFileSpec) {
#ifdef RAJIV_DEBUG
printf("Sending Done - OnStopSending \n");
#endif
m_done = PR_TRUE;
return NS_OK ;
}
/* void OnGetDraftFolderURI (); */
NS_IMETHOD OnGetDraftFolderURI(const char *aFolderURI) {return NS_OK;}
static nsresult CreateMAPISendListener( nsIMsgSendListener **ppListener);
PRBool IsDone() { return m_done ; }
protected :
nsMAPISendListener() {
NS_INIT_REFCNT();
m_done = PR_FALSE;
}
PRBool m_done;
};
NS_IMPL_THREADSAFE_ISUPPORTS1(nsMAPISendListener, nsIMsgSendListener)
nsresult nsMAPISendListener::CreateMAPISendListener( nsIMsgSendListener **ppListener)
{
NS_ENSURE_ARG_POINTER(ppListener) ;
*ppListener = new nsMAPISendListener();
if (! *ppListener)
return NS_ERROR_OUT_OF_MEMORY;
NS_ADDREF(*ppListener);
return NS_OK;
}
PRBool nsMapiHook::isMapiService = PR_FALSE;
PRBool nsMapiHook::Initialize()
{
nsresult rv;
nsCOMPtr<nsINativeAppSupport> native;
nsCOMPtr<nsICmdLineService> cmdLineArgs(do_GetService(kCmdLineServiceCID, &rv));
if (NS_FAILED(rv)) return PR_FALSE;
nsCOMPtr<nsIAppShellService> appShell (do_GetService( "@mozilla.org/appshell/appShellService;1", &rv));
if (NS_FAILED(rv)) return PR_FALSE;
rv = appShell->GetNativeAppSupport( getter_AddRefs( native ));
if (NS_FAILED(rv)) return PR_FALSE;
rv = native->EnsureProfile(cmdLineArgs);
if (NS_FAILED(rv)) return PR_FALSE;
return PR_TRUE;
}
void nsMapiHook::CleanUp()
{
// This routine will be fully implemented in future
// to cleanup mapi related stuff inside mozilla code.
}
PRBool nsMapiHook::DisplayLoginDialog(PRBool aLogin, PRUnichar **aUsername, \
PRUnichar **aPassword)
{
nsresult rv;
PRBool btnResult = PR_FALSE;
nsCOMPtr<nsIAppShellService> appShell(do_GetService( "@mozilla.org/appshell/appShellService;1", &rv));
if (NS_FAILED(rv) || !appShell) return PR_FALSE;
nsCOMPtr<nsIPromptService> dlgService(do_GetService("@mozilla.org/embedcomp/prompt-service;1", &rv));
if (NS_SUCCEEDED(rv) && dlgService)
{
nsCOMPtr<nsIStringBundleService> bundleService(do_GetService(NS_STRINGBUNDLE_CONTRACTID, &rv));
if (NS_FAILED(rv) || !bundleService) return PR_FALSE;
nsCOMPtr<nsIStringBundle> bundle;
rv = bundleService->CreateBundle(MAPI_PROPERTIES_CHROME, getter_AddRefs(bundle));
if (NS_FAILED(rv) || !bundle) return PR_FALSE;
nsCOMPtr<nsIStringBundle> brandBundle;
rv = bundleService->CreateBundle(
"chrome://global/locale/brand.properties",
getter_AddRefs(brandBundle));
if (NS_FAILED(rv)) return PR_FALSE;
nsXPIDLString brandName;
rv = brandBundle->GetStringFromName(
NS_LITERAL_STRING("brandShortName").get(),
getter_Copies(brandName));
if (NS_FAILED(rv)) return PR_FALSE;
nsXPIDLString loginTitle;
const PRUnichar *brandStrings[] = { brandName.get() };
NS_NAMED_LITERAL_STRING(loginTitlePropertyTag, "loginTitle");
const PRUnichar *dTitlePropertyTag = loginTitlePropertyTag.get();
rv = bundle->FormatStringFromName(dTitlePropertyTag, brandStrings, 1,
getter_Copies(loginTitle));
if (NS_FAILED(rv)) return PR_FALSE;
if (aLogin)
{
nsXPIDLString loginText;
rv = bundle->GetStringFromName(NS_LITERAL_STRING("loginTextwithName").get(),
getter_Copies(loginText));
if (NS_FAILED(rv) || !loginText) return PR_FALSE;
rv = dlgService->PromptUsernameAndPassword(nsnull, loginTitle,
loginText, aUsername, aPassword,
nsnull, PR_FALSE, &btnResult);
}
else
{
//nsString loginString;
nsXPIDLString loginText;
const PRUnichar *userNameStrings[] = { *aUsername };
NS_NAMED_LITERAL_STRING(loginTextPropertyTag, "loginText");
const PRUnichar *dpropertyTag = loginTextPropertyTag.get();
rv = bundle->FormatStringFromName(dpropertyTag, userNameStrings, 1,
getter_Copies(loginText));
if (NS_FAILED(rv)) return PR_FALSE;
rv = dlgService->PromptPassword(nsnull, loginTitle, loginText,
aPassword, nsnull, PR_FALSE, &btnResult);
}
}
return btnResult;
}
PRBool nsMapiHook::VerifyUserName(const PRUnichar *aUsername, char **aIdKey)
{
nsresult rv;
if (aUsername == nsnull)
return PR_FALSE;
nsCOMPtr<nsIMsgAccountManager> accountManager(do_GetService(NS_MSGACCOUNTMANAGER_CONTRACTID, &rv));
if (NS_FAILED(rv)) return PR_FALSE;
nsCOMPtr<nsISupportsArray> identities;
rv = accountManager->GetAllIdentities(getter_AddRefs(identities));
if (NS_FAILED(rv)) return PR_FALSE;
PRUint32 numIndentities;
identities->Count(&numIndentities);
for (PRUint32 i = 0; i < numIndentities; i++)
{
// convert supports->Identity
nsCOMPtr<nsISupports> thisSupports;
rv = identities->GetElementAt(i, getter_AddRefs(thisSupports));
if (NS_FAILED(rv)) continue;
nsCOMPtr<nsIMsgIdentity> thisIdentity(do_QueryInterface(thisSupports, &rv));
if (NS_SUCCEEDED(rv) && thisIdentity)
{
nsXPIDLCString email;
rv = thisIdentity->GetEmail(getter_Copies(email));
if (NS_FAILED(rv)) continue;
// get the username from the email and compare with the username
nsCAutoString aEmail(email.get());
PRInt32 index = aEmail.FindChar('@');
if (index != -1)
aEmail.Truncate(index);
if (nsDependentString(aUsername) == NS_ConvertASCIItoUCS2(aEmail)) // == overloaded
return NS_SUCCEEDED(thisIdentity->GetKey(aIdKey));
}
}
return PR_FALSE;
}
PRBool
nsMapiHook::IsBlindSendAllowed()
{
PRBool enabled = PR_FALSE;
PRBool warn = PR_TRUE;
nsCOMPtr<nsIPref> prefs = do_GetService(NS_PREF_CONTRACTID);
if (prefs) {
prefs->GetBoolPref(PREF_MAPI_WARN_PRIOR_TO_BLIND_SEND,&warn);
prefs->GetBoolPref(PREF_MAPI_BLIND_SEND_ENABLED,&enabled);
}
if (!enabled)
return PR_FALSE;
if (!warn)
return PR_TRUE; // Everything is okay.
nsresult rv;
nsCOMPtr<nsIStringBundleService> bundleService(do_GetService(NS_STRINGBUNDLE_CONTRACTID, &rv));
if (NS_FAILED(rv) || !bundleService) return PR_FALSE;
nsCOMPtr<nsIStringBundle> bundle;
rv = bundleService->CreateBundle(MAPI_PROPERTIES_CHROME, getter_AddRefs(bundle));
if (NS_FAILED(rv) || !bundle) return PR_FALSE;
nsXPIDLString warningMsg;
rv = bundle->GetStringFromName(NS_LITERAL_STRING("mapiBlindSendWarning").get(),
getter_Copies(warningMsg));
if (NS_FAILED(rv)) return PR_FALSE;
nsXPIDLString dontShowAgainMessage;
rv = bundle->GetStringFromName(NS_LITERAL_STRING("mapiBlindSendDontShowAgain").get(),
getter_Copies(dontShowAgainMessage));
if (NS_FAILED(rv)) return PR_FALSE;
nsCOMPtr<nsIPromptService> dlgService(do_GetService("@mozilla.org/embedcomp/prompt-service;1", &rv));
if (NS_FAILED(rv) || !dlgService) return PR_FALSE;
PRBool continueToWarn = PR_TRUE;
PRBool okayToContinue = PR_FALSE;
dlgService->ConfirmCheck(nsnull, nsnull, warningMsg, dontShowAgainMessage, &continueToWarn, &okayToContinue);
if (!continueToWarn && okayToContinue && prefs)
prefs->SetBoolPref(PREF_MAPI_WARN_PRIOR_TO_BLIND_SEND,PR_FALSE);
return okayToContinue;
}
// this is used for Send without UI
nsresult nsMapiHook::BlindSendMail (unsigned long aSession, nsIMsgCompFields * aCompFields)
{
nsresult rv = NS_OK ;
if (!IsBlindSendAllowed())
return NS_ERROR_FAILURE;
/** create nsIMsgComposeParams obj and other fields to populate it **/
// get parent window
nsCOMPtr<nsIAppShellService> appService = do_GetService( "@mozilla.org/appshell/appShellService;1", &rv);
if (NS_FAILED(rv)|| (!appService) ) return rv ;
nsCOMPtr<nsIDOMWindowInternal> hiddenWindow;
rv = appService->GetHiddenDOMWindow(getter_AddRefs(hiddenWindow));
if ( NS_FAILED(rv) ) return rv ;
// smtp password and Logged in used IdKey from MapiConfig (session obj)
nsMAPIConfiguration * pMapiConfig = nsMAPIConfiguration::GetMAPIConfiguration() ;
if (!pMapiConfig) return NS_ERROR_FAILURE ; // get the singelton obj
PRUnichar * password = pMapiConfig->GetPassWord(aSession) ;
// password
nsCAutoString smtpPassword ;
smtpPassword.AssignWithConversion (password) ;
// Id key
char * MsgIdKey = pMapiConfig->GetIdKey(aSession) ;
// get the MsgIdentity for the above key using AccountManager
nsCOMPtr <nsIMsgAccountManager> accountManager = do_GetService (NS_MSGACCOUNTMANAGER_CONTRACTID) ;
if (NS_FAILED(rv) || (!accountManager) ) return rv ;
nsCOMPtr <nsIMsgIdentity> pMsgId ;
rv = accountManager->GetIdentity (MsgIdKey, getter_AddRefs(pMsgId)) ;
if (NS_FAILED(rv) ) return rv ;
// create a send listener to get back the send status
nsCOMPtr <nsIMsgSendListener> sendListener ;
rv = nsMAPISendListener::CreateMAPISendListener(getter_AddRefs(sendListener)) ;
if (NS_FAILED(rv) || (!sendListener) ) return rv;
// create the compose params object
nsCOMPtr<nsIMsgComposeParams> pMsgComposeParams (do_CreateInstance(NS_MSGCOMPOSEPARAMS_CONTRACTID, &rv));
if (NS_FAILED(rv) || (!pMsgComposeParams) ) return rv ;
// populate the compose params
pMsgComposeParams->SetType(nsIMsgCompType::New);
pMsgComposeParams->SetFormat(nsIMsgCompFormat::Default);
pMsgComposeParams->SetIdentity(pMsgId);
pMsgComposeParams->SetComposeFields(aCompFields);
pMsgComposeParams->SetSendListener(sendListener) ;
pMsgComposeParams->SetSmtpPassword(smtpPassword);
// create the nsIMsgCompose object to send the object
nsCOMPtr<nsIMsgCompose> pMsgCompose (do_CreateInstance(NS_MSGCOMPOSE_CONTRACTID, &rv));
if (NS_FAILED(rv) || (!pMsgCompose) ) return rv ;
/** initialize nsIMsgCompose, Send the message, wait for send completion response **/
rv = pMsgCompose->Initialize(hiddenWindow, pMsgComposeParams) ;
if (NS_FAILED(rv)) return rv ;
pMsgCompose->SendMsg(nsIMsgSend::nsMsgDeliverNow, pMsgId, nsnull) ;
if (NS_FAILED(rv)) return rv ;
// assign to interface pointer from nsCOMPtr to facilitate typecast below
nsIMsgSendListener * pSendListener = sendListener ;
// we need to wait here to make sure that we return only after send is completed
// so we will have a event loop here which will process the events till the Send IsDone.
nsCOMPtr<nsIEventQueueService> pEventQService = do_GetService(NS_EVENTQUEUESERVICE_CONTRACTID, &rv);
nsCOMPtr<nsIEventQueue> eventQueue;
pEventQService->GetThreadEventQueue(NS_CURRENT_THREAD,getter_AddRefs(eventQueue));
while ( !((nsMAPISendListener *) pSendListener)->IsDone() )
eventQueue->ProcessPendingEvents();
return rv ;
}
// this is used to populate comp fields with Unicode data
nsresult nsMapiHook::PopulateCompFields(lpnsMapiMessage aMessage,
nsIMsgCompFields * aCompFields)
{
nsresult rv = NS_OK ;
if (aMessage->lpOriginator)
{
PRUnichar * From = aMessage->lpOriginator->lpszAddress ;
aCompFields->SetFrom (From) ;
}
nsAutoString To ;
nsAutoString Cc ;
nsAutoString Bcc ;
nsAutoString Comma ;
Comma.AssignWithConversion(",");
if (aMessage->lpRecips)
{
for (int i=0 ; i < (int) aMessage->nRecipCount ; i++)
{
if (aMessage->lpRecips[i].lpszAddress)
{
switch (aMessage->lpRecips[i].ulRecipClass)
{
case MAPI_TO :
if (To.Length() > 0)
To += Comma ;
To += (PRUnichar *) aMessage->lpRecips[i].lpszAddress ;
break ;
case MAPI_CC :
if (Cc.Length() > 0)
Cc += Comma ;
Cc += (PRUnichar *) aMessage->lpRecips[i].lpszAddress ;
break ;
case MAPI_BCC :
if (Bcc.Length() > 0)
Bcc += Comma ;
Bcc += (PRUnichar *) aMessage->lpRecips[i].lpszAddress ;
break ;
}
}
}
}
// set To, Cc, Bcc
aCompFields->SetTo (To.get()) ;
aCompFields->SetCc (Cc.get()) ;
aCompFields->SetBcc (Bcc.get()) ;
// set subject
if (aMessage->lpszSubject)
{
PRUnichar * Subject = aMessage->lpszSubject ;
aCompFields->SetSubject(Subject) ;
}
// handle attachments as File URL
rv = HandleAttachments (aCompFields, aMessage->nFileCount, aMessage->lpFiles, PR_TRUE) ;
if (NS_FAILED(rv)) return rv ;
// set body
if (aMessage->lpszNoteText)
{
PRUnichar * Body = aMessage->lpszNoteText ;
rv = aCompFields->SetBody(Body) ;
}
#ifdef RAJIV_DEBUG
// testing what all was set in CompFields
printf ("To : %S \n", To.get()) ;
printf ("CC : %S \n", Cc.get() ) ;
printf ("BCC : %S \n", Bcc.get() ) ;
#endif
return rv ;
}
nsresult nsMapiHook::HandleAttachments (nsIMsgCompFields * aCompFields, PRInt32 aFileCount,
lpnsMapiFileDesc aFiles, BOOL aIsUnicode)
{
nsresult rv = NS_OK ;
nsCAutoString Attachments ;
nsCAutoString TempFiles ;
nsCOMPtr <nsILocalFile> pFile = do_CreateInstance (NS_LOCAL_FILE_CONTRACTID, &rv) ;
if (NS_FAILED(rv) || (!pFile) ) return rv ;
nsCOMPtr <nsILocalFile> pTempDir = do_CreateInstance (NS_LOCAL_FILE_CONTRACTID, &rv) ;
if (NS_FAILED(rv) || (!pTempDir) ) return rv ;
for (int i=0 ; i < aFileCount ; i++)
{
PRBool bTempFile = PR_FALSE ;
if (aFiles[i].lpszPathName)
{
if (aIsUnicode)
pFile->InitWithUnicodePath (aFiles[i].lpszPathName) ;
else
pFile->InitWithPath ((char *) aFiles[i].lpszPathName) ;
PRBool bExist ;
rv = pFile->Exists(&bExist) ;
if (NS_FAILED(rv) || (!bExist) ) return NS_ERROR_FILE_TARGET_DOES_NOT_EXIST ;
// we do this since MS Office apps create a temp file when sending
// the currently open document in that app
if (aFiles[i].lpszFileName)
{
// Win temp Path
nsAutoString tempPath ;
nsSpecialSystemDirectory tmpDir(nsSpecialSystemDirectory::OS_TemporaryDirectory);
((nsFileSpec*)&tmpDir)->GetNativePathString(tempPath);
tempPath.ToLowerCase() ;
// filename of the file attachment
nsXPIDLString pLeafName ;
pFile->GetUnicodeLeafName (getter_Copies(pLeafName)) ;
// dir path of the file attachment
nsXPIDLString pPath ;
pFile->GetUnicodePath (getter_Copies(pPath)) ;
nsAutoString Path ;
Path.Assign(pPath.get()) ;
nsAutoString LeafName ;
LeafName.Assign (pLeafName.get());
PRInt32 offset = Path.RFind (LeafName) ;
Path.SetLength(offset) ;
Path.ToLowerCase() ;
if (tempPath == Path)
{
// create another temp dir for mapi within Win temp dir
nsAutoString strTempDir ;
strTempDir += tempPath.get() ;
strTempDir.AppendWithConversion("moz_mapi") ;
pTempDir->InitWithUnicodePath (strTempDir.get()) ;
pTempDir->Exists (&bExist) ;
if (!bExist)
{
rv = pTempDir->Create(nsIFile::DIRECTORY_TYPE, 777) ;
if (NS_FAILED(rv)) return rv ;
}
// filename passed for the file attachment
if (aIsUnicode)
{
nsAutoString RealFileName ;
RealFileName.Assign (aFiles[i].lpszFileName) ;
// copy to our mapi temp dir with real name
rv = pFile->CopyToUnicode(pTempDir, RealFileName.get()) ;
if (NS_FAILED(rv)) return rv ;
pFile->InitWithUnicodePath(strTempDir.get()) ;
pFile->AppendUnicode (RealFileName.get()) ;
}
else
{
nsCAutoString asciiRealFileName ;
asciiRealFileName.Assign((char *) aFiles[i].lpszFileName) ;
nsCAutoString asciiLeafName ;
asciiLeafName.AssignWithConversion (pLeafName.get());
// copy to our mapi temp dir with real name
rv = pFile->CopyTo(pTempDir, asciiRealFileName.get()) ;
if (NS_FAILED(rv)) return rv ;
pFile->InitWithUnicodePath(strTempDir.get()) ;
pFile->Append (asciiRealFileName.get()) ;
}
// this one is a temp file
bTempFile = PR_TRUE ;
}
}
// get url
nsXPIDLCString pURL ;
pFile->GetURL (getter_Copies(pURL)) ;
if (pURL)
{
if (Attachments.Length() > 0)
Attachments.Append(",") ;
Attachments.Append(pURL) ;
if (bTempFile)
{
if (TempFiles.Length() > 0)
TempFiles.Append(",") ;
TempFiles.Append(pURL) ;
}
}
}
}
// set attachment
if (Attachments.Length() > 0)
rv = aCompFields->SetAttachments (Attachments.get());
// set temp file
if (TempFiles.Length() > 0)
rv = aCompFields->SetTemporaryFiles(TempFiles.get());
#ifdef RAJIV_DEBUG
printf ("Attachments : %s \n", Attachments.get()) ;
printf ("TempFiles : %s \n", TempFiles.get()) ;
#endif
return rv ;
}
// this is used to convert non Unicode data and then populate comp fields
nsresult nsMapiHook::PopulateCompFieldsWithConversion(lpnsMapiMessage aMessage,
nsIMsgCompFields * aCompFields)
{
nsresult rv = NS_OK ;
if (aMessage->lpOriginator)
{
nsAutoString From ;
From.AssignWithConversion((char *) aMessage->lpOriginator->lpszAddress);
aCompFields->SetFrom (From.get()) ;
}
nsAutoString To ;
nsAutoString Cc ;
nsAutoString Bcc ;
nsAutoString Comma ;
Comma.AssignWithConversion(",");
if (aMessage->lpRecips)
{
for (int i=0 ; i < (int) aMessage->nRecipCount ; i++)
{
if (aMessage->lpRecips[i].lpszAddress)
{
switch (aMessage->lpRecips[i].ulRecipClass)
{
case MAPI_TO :
if (To.Length() > 0)
To += Comma ;
To.AppendWithConversion ((char *) aMessage->lpRecips[i].lpszAddress);
break ;
case MAPI_CC :
if (Cc.Length() > 0)
Cc += Comma ;
Cc.AppendWithConversion ((char *) aMessage->lpRecips[i].lpszAddress);
break ;
case MAPI_BCC :
if (Bcc.Length() > 0)
Bcc += Comma ;
Bcc.AppendWithConversion ((char *) aMessage->lpRecips[i].lpszAddress) ;
break ;
}
}
}
}
// set To, Cc, Bcc
aCompFields->SetTo (To.get()) ;
aCompFields->SetCc (Cc.get()) ;
aCompFields->SetBcc (Bcc.get()) ;
nsAutoString platformCharSet;
// set subject
if (aMessage->lpszSubject)
{
nsAutoString Subject ;
if (platformCharSet.IsEmpty())
platformCharSet.Assign(nsMsgI18NFileSystemCharset());
rv = ConvertToUnicode(platformCharSet, (char *) aMessage->lpszSubject, Subject);
if (NS_FAILED(rv)) return rv ;
aCompFields->SetSubject(Subject.get()) ;
}
// handle attachments as File URL
rv = HandleAttachments (aCompFields, aMessage->nFileCount, aMessage->lpFiles, PR_FALSE) ;
if (NS_FAILED(rv)) return rv ;
// set body
if (aMessage->lpszNoteText)
{
nsAutoString Body ;
if (platformCharSet.IsEmpty())
platformCharSet.Assign(nsMsgI18NFileSystemCharset());
rv = ConvertToUnicode(platformCharSet, (char *) aMessage->lpszNoteText, Body);
if (NS_FAILED(rv)) return rv ;
rv = aCompFields->SetBody(Body.get()) ;
}
#ifdef RAJIV_DEBUG
// testing what all was set in CompFields
printf ("To : %S \n", To.get()) ;
printf ("CC : %S \n", Cc.get() ) ;
printf ("BCC : %S \n", Bcc.get() ) ;
#endif
return rv ;
}
// this is used to populate the docs as attachments in the Comp fields for Send Documents
nsresult nsMapiHook::PopulateCompFieldsForSendDocs(nsIMsgCompFields * aCompFields, ULONG aFlags,
PRUnichar * aDelimChar, PRUnichar * aFilePaths)
{
nsAutoString strDelimChars ;
nsString strFilePaths;
nsresult rv = NS_OK ;
if (aFlags & MAPI_UNICODE)
{
if (aDelimChar)
strDelimChars.Assign (aDelimChar) ;
if (aFilePaths)
strFilePaths.Assign (aFilePaths) ;
}
else
{
if (aDelimChar)
strDelimChars.AssignWithConversion ((char*) aDelimChar) ;
if (aFilePaths)
strFilePaths.AssignWithConversion ((char *) aFilePaths) ;
}
// check for comma in filename
if (strDelimChars.Find (",") == kNotFound) // if comma is not in the delimiter specified by user
{
if (strFilePaths.Find(",") != kNotFound) // if comma found in filenames return error
return NS_ERROR_FILE_INVALID_PATH ;
}
nsCString Attachments ;
// only 1 file is to be sent, no delim specified
if ((!strDelimChars.Length()) && (strFilePaths.Length()>0))
{
nsCOMPtr <nsILocalFile> pFile = do_CreateInstance (NS_LOCAL_FILE_CONTRACTID, &rv) ;
if (NS_FAILED(rv) || (!pFile) ) return rv ;
pFile->InitWithUnicodePath (strFilePaths.get()) ;
PRBool bExist ;
rv = pFile->Exists(&bExist) ;
if (NS_FAILED(rv) || (!bExist) ) return NS_ERROR_FILE_TARGET_DOES_NOT_EXIST ;
nsXPIDLCString pURL ;
pFile->GetURL (getter_Copies(pURL)) ;
if (pURL)
Attachments.Assign(pURL) ;
// set attachments for comp field and return
rv = aCompFields->SetAttachments (Attachments.get());
return rv ;
}
// multiple files to be sent, delim specified
nsCOMPtr <nsILocalFile> pFile = do_CreateInstance (NS_LOCAL_FILE_CONTRACTID, &rv) ;
if (NS_FAILED(rv) || (!pFile) ) return rv ;
PRInt32 offset = 0 ;
PRInt32 FilePathsLen = strFilePaths.Length() ;
if (FilePathsLen)
{
PRUnichar * newFilePaths = (PRUnichar *) strFilePaths.get() ;
while (offset != kNotFound)
{
nsString RemainingPaths ;
RemainingPaths.Assign(newFilePaths) ;
offset = RemainingPaths.Find (strDelimChars) ;
if (offset != kNotFound)
{
RemainingPaths.SetLength (offset) ;
if ((offset + strDelimChars.Length()) < FilePathsLen)
newFilePaths += offset + strDelimChars.Length() ;
}
pFile->InitWithUnicodePath (RemainingPaths.get()) ;
#ifdef RAJIV_DEBUG
printf ("File : %S \n", RemainingPaths.get()) ;
#endif
PRBool bExist ;
rv = pFile->Exists(&bExist) ;
if (NS_FAILED(rv) || (!bExist) ) return NS_ERROR_FILE_TARGET_DOES_NOT_EXIST ;
nsXPIDLCString pURL ;
pFile->GetURL (getter_Copies(pURL)) ;
if (pURL)
{
if (Attachments.Length() > 0)
Attachments.Append(",") ;
Attachments.Append(pURL) ;
}
}
rv = aCompFields->SetAttachments (Attachments.get());
}
return rv ;
}
// this used for Send with UI
nsresult nsMapiHook::ShowComposerWindow (unsigned long aSession, nsIMsgCompFields * aCompFields)
{
nsresult rv = NS_OK ;
// create a send listener to get back the send status
nsCOMPtr <nsIMsgSendListener> sendListener ;
rv = nsMAPISendListener::CreateMAPISendListener(getter_AddRefs(sendListener)) ;
if (NS_FAILED(rv) || (!sendListener) ) return rv ;
// create the compose params object
nsCOMPtr<nsIMsgComposeParams> pMsgComposeParams (do_CreateInstance(NS_MSGCOMPOSEPARAMS_CONTRACTID, &rv));
if (NS_FAILED(rv) || (!pMsgComposeParams) ) return rv ;
// populate the compose params
pMsgComposeParams->SetType(nsIMsgCompType::New);
pMsgComposeParams->SetFormat(nsIMsgCompFormat::Default);
pMsgComposeParams->SetComposeFields(aCompFields);
pMsgComposeParams->SetSendListener(sendListener) ;
/** get the nsIMsgComposeService object to open the compose window **/
nsCOMPtr <nsIMsgComposeService> compService = do_GetService (NS_MSGCOMPOSESERVICE_CONTRACTID) ;
if (NS_FAILED(rv)|| (!compService) ) return rv ;
rv = compService->OpenComposeWindowWithParams(nsnull, pMsgComposeParams) ;
if (NS_FAILED(rv)) return rv ;
return rv ;
}

View File

@@ -1,66 +0,0 @@
/* ***** BEGIN LICENSE BLOCK *****
* Version: MPL 1.1/GPL 2.0/LGPL 2.1
*
* The contents of this file are subject to the Mozilla Public License Version
* 1.1 (the "License"); you may not use this file except in compliance with
* the License. You may obtain a copy of the License at
* http://www.mozilla.org/MPL/
*
* Software distributed under the License is distributed on an "AS IS" basis,
* WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
* for the specific language governing rights and limitations under the
* License.
*
* The Original Code is Mozilla
*
* The Initial Developer of the Original Code is
* Netscape Communications Corp.
* Portions created by the Initial Developer are Copyright (C) 2001
* the Initial Developer. All Rights Reserved.
*
* Contributor(s): Krishna Mohan Khandrika (kkhandrika@netscape.com)
*
* Alternatively, the contents of this file may be used under the terms of
* either the GNU General Public License Version 2 or later (the "GPL"), or
* the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
* in which case the provisions of the GPL or the LGPL are applicable instead
* of those above. If you wish to allow use of your version of this file only
* under the terms of either the GPL or the LGPL, and not to allow others to
* use your version of this file under the terms of the MPL, indicate your
* decision by deleting the provisions above and replace them with the notice
* and other provisions required by the GPL or the LGPL. If you do not delete
* the provisions above, a recipient may use your version of this file under
* the terms of any one of the MPL, the GPL or the LGPL.
*
* ***** END LICENSE BLOCK ***** */
#ifndef MSG_MAPI_HOOK_H_
#define MSG_MAPI_HOOK_H_
#include "prtypes.h"
class nsMapiHook
{
public :
static PRBool Initialize();
static PRBool DisplayLoginDialog(PRBool aLogin, PRUnichar **aUsername,
PRUnichar **aPassword);
static PRBool VerifyUserName(const PRUnichar *aUsername, char **aIdKey);
static PRBool IsBlindSendAllowed () ;
static nsresult BlindSendMail (unsigned long aSession, nsIMsgCompFields * aCompFields) ;
static nsresult ShowComposerWindow (unsigned long aSession, nsIMsgCompFields * aCompFields) ;
static nsresult PopulateCompFields(lpnsMapiMessage aMessage, nsIMsgCompFields * aCompFields) ;
static nsresult PopulateCompFieldsWithConversion(lpnsMapiMessage aMessage,
nsIMsgCompFields * aCompFields) ;
static nsresult PopulateCompFieldsForSendDocs(nsIMsgCompFields * aCompFields,
ULONG aFlags, LPTSTR aDelimChar, LPTSTR aFilePaths) ;
static nsresult HandleAttachments (nsIMsgCompFields * aCompFields, PRInt32 aFileCount,
lpnsMapiFileDesc aFiles, BOOL aIsUnicode) ;
static void CleanUp();
static PRBool isMapiService;
};
#endif // MSG_MAPI_HOOK_H_

View File

@@ -1,335 +0,0 @@
/* ***** BEGIN LICENSE BLOCK *****
* Version: MPL 1.1/GPL 2.0/LGPL 2.1
*
* The contents of this file are subject to the Mozilla Public License Version
* 1.1 (the "License"); you may not use this file except in compliance with
* the License. You may obtain a copy of the License at
* http://www.mozilla.org/MPL/
*
* Software distributed under the License is distributed on an "AS IS" basis,
* WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
* for the specific language governing rights and limitations under the
* License.
*
* The Original Code is Mozilla
*
* The Initial Developer of the Original Code is
* Netscape Communications Corp.
* Portions created by the Initial Developer are Copyright (C) 2001
* the Initial Developer. All Rights Reserved.
*
* Contributor(s): Krishna Mohan Khandrika (kkhandrika@netscape.com)
* Contributor(s): Rajiv Dayal (rdayal@netscape.com)
*
* Alternatively, the contents of this file may be used under the terms of
* either the GNU General Public License Version 2 or later (the "GPL"), or
* the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
* in which case the provisions of the GPL or the LGPL are applicable instead
* of those above. If you wish to allow use of your version of this file only
* under the terms of either the GPL or the LGPL, and not to allow others to
* use your version of this file under the terms of the MPL, indicate your
* decision by deleting the provisions above and replace them with the notice
* and other provisions required by the GPL or the LGPL. If you do not delete
* the provisions above, a recipient may use your version of this file under
* the terms of any one of the MPL, the GPL or the LGPL.
*
* ***** END LICENSE BLOCK ***** */
#include <mapidefs.h>
#include <mapi.h>
#include "msgMapi.h"
#include "msgMapiImp.h"
#include "msgMapiFactory.h"
#include "msgMapiMain.h"
#include "nsMsgCompFields.h"
#include "msgMapiHook.h"
#include "nsString.h"
#include "nsCOMPtr.h"
#include "nsISupports.h"
#include "nsMsgCompCID.h"
#include "nsMsgComposeStringBundle.h"
const CLSID CLSID_nsMapiImp = {0x29f458be, 0x8866, 0x11d5, {0xa3, 0xdd, 0x0, 0xb0, 0xd0, 0xf3, 0xba, 0xa7}};
nsMapiImp::nsMapiImp()
: m_cRef(1)
{
m_Lock = PR_NewLock();
}
nsMapiImp::~nsMapiImp()
{
if (m_Lock)
PR_DestroyLock(m_Lock);
}
STDMETHODIMP nsMapiImp::QueryInterface(const IID& aIid, void** aPpv)
{
if (aIid == IID_IUnknown)
{
*aPpv = static_cast<nsIMapi*>(this);
}
else if (aIid == IID_nsIMapi)
{
*aPpv = static_cast<nsIMapi*>(this);
}
else
{
*aPpv = nsnull;
return E_NOINTERFACE;
}
reinterpret_cast<IUnknown*>(*aPpv)->AddRef();
return S_OK;
}
STDMETHODIMP_(ULONG) nsMapiImp::AddRef()
{
return PR_AtomicIncrement(&m_cRef);
}
STDMETHODIMP_(ULONG) nsMapiImp::Release()
{
PRInt32 temp;
temp = PR_AtomicDecrement(&m_cRef);
if (m_cRef == 0)
{
delete this;
return 0;
}
return temp;
}
STDMETHODIMP nsMapiImp::IsValid()
{
return S_OK;
}
STDMETHODIMP nsMapiImp::IsValidSession(unsigned long aSession)
{
nsMAPIConfiguration *pConfig = nsMAPIConfiguration::GetMAPIConfiguration();
if (pConfig && pConfig->IsSessionValid(aSession))
return S_OK;
return E_FAIL;
}
STDMETHODIMP nsMapiImp::Initialize()
{
HRESULT hr = E_FAIL;
if (!m_Lock)
return E_FAIL;
PR_Lock(m_Lock);
// Initialize MAPI Configuration
nsMAPIConfiguration *pConfig = nsMAPIConfiguration::GetMAPIConfiguration();
if (pConfig != nsnull)
if (nsMapiHook::Initialize())
hr = S_OK;
PR_Unlock(m_Lock);
return hr;
}
STDMETHODIMP nsMapiImp::Login(unsigned long aUIArg, LOGIN_PW_TYPE aLogin, LOGIN_PW_TYPE aPassWord,
unsigned long aFlags, unsigned long *aSessionId)
{
HRESULT hr = E_FAIL;
PRBool bNewSession = PR_FALSE;
char *id_key = nsnull;
if (aFlags & MAPI_NEW_SESSION)
bNewSession = PR_TRUE;
// Check For Profile Name
if (aLogin != nsnull && aLogin[0] != '\0')
{
if (nsMapiHook::VerifyUserName(aLogin, &id_key) == PR_FALSE)
{
*aSessionId = MAPI_E_LOGIN_FAILURE;
return hr;
}
}
// finally register(create) the session.
PRUint32 nSession_Id;
PRInt16 nResult = 0;
nsMAPIConfiguration *pConfig = nsMAPIConfiguration::GetMAPIConfiguration();
if (pConfig != nsnull)
nResult = pConfig->RegisterSession(aUIArg, aLogin, aPassWord,
(aFlags & MAPI_FORCE_DOWNLOAD), bNewSession,
&nSession_Id, id_key);
switch (nResult)
{
case -1 :
{
*aSessionId = MAPI_E_TOO_MANY_SESSIONS;
return hr;
}
case 0 :
{
*aSessionId = MAPI_E_INSUFFICIENT_MEMORY;
return hr;
}
default :
{
*aSessionId = nSession_Id;
break;
}
}
return S_OK;
}
STDMETHODIMP nsMapiImp::SendMail( unsigned long aSession, lpnsMapiMessage aMessage,
short aRecipCount, lpnsMapiRecipDesc aRecips , short aFileCount, lpnsMapiFileDesc aFiles ,
unsigned long aFlags, unsigned long aReserved)
{
HRESULT hr = SUCCESS_SUCCESS ;
// Assign the pointers in the aMessage struct to the array of Recips and Files
// recieved here from MS COM. These are used in BlindSendMail and ShowCompWin fns
aMessage->lpRecips = aRecips ;
aMessage->lpFiles = aFiles ;
nsresult rv ;
/** create nsIMsgCompFields obj and populate it **/
nsCOMPtr<nsIMsgCompFields> pCompFields = do_CreateInstance(NS_MSGCOMPFIELDS_CONTRACTID, &rv) ;
if (NS_FAILED(rv) || (!pCompFields) ) return MAPI_E_INSUFFICIENT_MEMORY ;
if (aFlags & MAPI_UNICODE)
rv = nsMapiHook::PopulateCompFields(aMessage, pCompFields) ;
else
rv = nsMapiHook::PopulateCompFieldsWithConversion(aMessage, pCompFields) ;
if (NS_SUCCEEDED (rv))
{
// see flag to see if UI needs to be brought up
if (!(aFlags & MAPI_DIALOG))
{
rv = nsMapiHook::BlindSendMail(aSession, pCompFields);
}
else
{
rv = nsMapiHook::ShowComposerWindow(aSession, pCompFields);
}
}
// return success
if (NS_SUCCEEDED (rv)) return hr ;
// if failure return the related MAPI failure code
switch (rv)
{
case NS_MSG_NO_RECIPIENTS :
hr = MAPI_E_BAD_RECIPTYPE ;
break ;
case NS_ERROR_COULD_NOT_GET_USERS_MAIL_ADDRESS :
hr = MAPI_E_INVALID_RECIPS ;
break ;
case NS_ERROR_COULD_NOT_LOGIN_TO_SMTP_SERVER :
hr = MAPI_E_LOGIN_FAILURE ;
break ;
case NS_MSG_UNABLE_TO_OPEN_FILE :
case NS_MSG_UNABLE_TO_OPEN_TMP_FILE :
case NS_MSG_COULDNT_OPEN_FCC_FOLDER :
case NS_ERROR_FILE_INVALID_PATH :
hr = MAPI_E_ATTACHMENT_OPEN_FAILURE ;
break ;
case NS_ERROR_FILE_TARGET_DOES_NOT_EXIST :
hr = MAPI_E_ATTACHMENT_NOT_FOUND ;
break ;
case NS_MSG_CANCELLING :
hr = MAPI_E_USER_ABORT ;
break ;
case NS_MSG_ERROR_WRITING_FILE :
case NS_MSG_UNABLE_TO_SAVE_TEMPLATE :
case NS_MSG_UNABLE_TO_SAVE_DRAFT :
hr = MAPI_E_ATTACHMENT_WRITE_FAILURE ;
break ;
default :
hr = MAPI_E_FAILURE ;
break ;
}
return hr ;
}
STDMETHODIMP nsMapiImp::SendDocuments( unsigned long aSession, LPTSTR aDelimChar,
LPTSTR aFilePaths, LPTSTR aFileNames, ULONG aFlags)
{
HRESULT hr = SUCCESS_SUCCESS ;
nsresult rv = NS_OK ;
/** create nsIMsgCompFields obj and populate it **/
nsCOMPtr<nsIMsgCompFields> pCompFields = do_CreateInstance(NS_MSGCOMPFIELDS_CONTRACTID, &rv) ;
if (NS_FAILED(rv) || (!pCompFields) ) return MAPI_E_INSUFFICIENT_MEMORY ;
if (aFilePaths)
{
rv = nsMapiHook::PopulateCompFieldsForSendDocs(pCompFields, aFlags, aDelimChar, aFilePaths) ;
}
if (NS_SUCCEEDED (rv))
rv = nsMapiHook::ShowComposerWindow(aSession, pCompFields);
// return success
if (NS_SUCCEEDED (rv)) return hr ;
// if failure return the related MAPI failure code
switch (rv)
{
case NS_ERROR_COULD_NOT_LOGIN_TO_SMTP_SERVER :
hr = MAPI_E_LOGIN_FAILURE ;
break ;
case NS_MSG_UNABLE_TO_OPEN_FILE :
case NS_MSG_UNABLE_TO_OPEN_TMP_FILE :
case NS_MSG_COULDNT_OPEN_FCC_FOLDER :
case NS_ERROR_FILE_INVALID_PATH :
hr = MAPI_E_ATTACHMENT_OPEN_FAILURE ;
break ;
case NS_ERROR_FILE_TARGET_DOES_NOT_EXIST :
hr = MAPI_E_ATTACHMENT_NOT_FOUND ;
break ;
case NS_MSG_CANCELLING :
hr = MAPI_E_USER_ABORT ;
break ;
case NS_MSG_ERROR_WRITING_FILE :
case NS_MSG_UNABLE_TO_SAVE_TEMPLATE :
case NS_MSG_UNABLE_TO_SAVE_DRAFT :
hr = MAPI_E_ATTACHMENT_WRITE_FAILURE ;
break ;
default :
hr = MAPI_E_FAILURE ;
break ;
}
return hr ;
}
STDMETHODIMP nsMapiImp::Logoff (unsigned long aSession)
{
nsMAPIConfiguration *pConfig = nsMAPIConfiguration::GetMAPIConfiguration();
if (pConfig->UnRegisterSession((PRUint32)aSession))
return S_OK;
return E_FAIL;
}
STDMETHODIMP nsMapiImp::CleanUp()
{
nsMapiHook::CleanUp();
return S_OK;
}

View File

@@ -1,87 +0,0 @@
/* ***** BEGIN LICENSE BLOCK *****
* Version: MPL 1.1/GPL 2.0/LGPL 2.1
*
* The contents of this file are subject to the Mozilla Public License Version
* 1.1 (the "License"); you may not use this file except in compliance with
* the License. You may obtain a copy of the License at
* http://www.mozilla.org/MPL/
*
* Software distributed under the License is distributed on an "AS IS" basis,
* WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
* for the specific language governing rights and limitations under the
* License.
*
* The Original Code is Mozilla
*
* The Initial Developer of the Original Code is
* Netscape Communications Corp.
* Portions created by the Initial Developer are Copyright (C) 2001
* the Initial Developer. All Rights Reserved.
*
* Contributor(s): Krishna Mohan Khandrika (kkhandrika@netscape.com)
*
* Alternatively, the contents of this file may be used under the terms of
* either the GNU General Public License Version 2 or later (the "GPL"), or
* the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
* in which case the provisions of the GPL or the LGPL are applicable instead
* of those above. If you wish to allow use of your version of this file only
* under the terms of either the GPL or the LGPL, and not to allow others to
* use your version of this file under the terms of the MPL, indicate your
* decision by deleting the provisions above and replace them with the notice
* and other provisions required by the GPL or the LGPL. If you do not delete
* the provisions above, a recipient may use your version of this file under
* the terms of any one of the MPL, the GPL or the LGPL.
*
* ***** END LICENSE BLOCK ***** */
#ifndef MSG_MAPI_IMP_H
#define MSG_MAPI_IMP_H
#include <windows.h>
#include <mapi.h>
#include "msgMapi.h"
#include "nsXPIDLString.h"
#include "nspr.h"
class nsMapiImp : public nsIMapi
{
public :
// IUnknown
STDMETHODIMP QueryInterface(const IID& aIid, void** aPpv);
STDMETHODIMP_(ULONG) AddRef();
STDMETHODIMP_(ULONG) Release();
// Interface INsMapi
STDMETHODIMP Login(unsigned long aUIArg, LOGIN_PW_TYPE aLogin,
LOGIN_PW_TYPE aPassWord, unsigned long aFlags,
unsigned long *aSessionId);
STDMETHODIMP SendMail( unsigned long aSession, lpnsMapiMessage aMessage,
short aRecipCount, lpnsMapiRecipDesc aRecips ,
short aFileCount, lpnsMapiFileDesc aFiles ,
unsigned long aFlags, unsigned long aReserved) ;
STDMETHODIMP SendDocuments( unsigned long aSession, LPTSTR aDelimChar,
LPTSTR aFilePaths, LPTSTR aFileNames, ULONG aFlags);
STDMETHODIMP Initialize();
STDMETHODIMP IsValid();
STDMETHODIMP IsValidSession(unsigned long aSession);
STDMETHODIMP Logoff (unsigned long aSession);
STDMETHODIMP CleanUp();
nsMapiImp();
~nsMapiImp();
private :
PRLock *m_Lock;
PRInt32 m_cRef;
};
#endif // MSG_MAPI_IMP_H

View File

@@ -1,340 +0,0 @@
/* ***** BEGIN LICENSE BLOCK *****
* Version: MPL 1.1/GPL 2.0/LGPL 2.1
*
* The contents of this file are subject to the Mozilla Public License Version
* 1.1 (the "License"); you may not use this file except in compliance with
* the License. You may obtain a copy of the License at
* http://www.mozilla.org/MPL/
*
* Software distributed under the License is distributed on an "AS IS" basis,
* WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
* for the specific language governing rights and limitations under the
* License.
*
* The Original Code is Mozilla
*
* The Initial Developer of the Original Code is
* Netscape Communications Corp.
* Portions created by the Initial Developer are Copyright (C) 2001
* the Initial Developer. All Rights Reserved.
*
* Contributor(s): Krishna Mohan Khandrika (kkhandrika@netscape.com)
*
* Alternatively, the contents of this file may be used under the terms of
* either the GNU General Public License Version 2 or later (the "GPL"), or
* the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
* in which case the provisions of the GPL or the LGPL are applicable instead
* of those above. If you wish to allow use of your version of this file only
* under the terms of either the GPL or the LGPL, and not to allow others to
* use your version of this file under the terms of the MPL, indicate your
* decision by deleting the provisions above and replace them with the notice
* and other provisions required by the GPL or the LGPL. If you do not delete
* the provisions above, a recipient may use your version of this file under
* the terms of any one of the MPL, the GPL or the LGPL.
*
* ***** END LICENSE BLOCK ***** */
#include "msgMapiMain.h"
#include "nsIServiceManager.h"
#include "nsCOMPtr.h"
// move to xpcom bug 81956.
class nsPRUintKey : public nsHashKey {
protected:
PRUint32 mKey;
public:
nsPRUintKey(PRUint32 key) : mKey(key) {}
PRUint32 HashCode(void) const {
return mKey;
}
PRBool Equals(const nsHashKey *aKey) const {
return mKey == ((const nsPRUintKey *) aKey)->mKey;
}
nsHashKey *Clone() const {
return new nsPRUintKey(mKey);
}
PRUint32 GetValue() { return mKey; }
};
//
nsMAPIConfiguration *nsMAPIConfiguration::m_pSelfRef = nsnull;
PRUint32 nsMAPIConfiguration::session_generator = 0;
PRUint32 nsMAPIConfiguration::sessionCount = 0;
nsMAPIConfiguration *nsMAPIConfiguration::GetMAPIConfiguration()
{
if (m_pSelfRef == nsnull)
m_pSelfRef = new nsMAPIConfiguration();
return m_pSelfRef;
}
nsMAPIConfiguration::nsMAPIConfiguration()
: m_nMaxSessions(MAX_SESSIONS),
m_ProfileMap(nsnull),
m_SessionMap(nsnull)
{
m_Lock = PR_NewLock();
m_ProfileMap = new nsHashtable();
m_SessionMap = new nsHashtable();
NS_ASSERTION(m_SessionMap && m_ProfileMap, "hashtables not created");
}
static PRBool
FreeSessionMapEntries(nsHashKey *aKey, void *aData, void* aClosure)
{
nsMAPISession *pTemp = (nsMAPISession*) aData;
delete pTemp;
pTemp = nsnull;
return PR_TRUE;
}
static PRBool
FreeProfileMapEntries(nsHashKey *aKey, void *aData, void* aClosure)
{
return PR_TRUE;
}
nsMAPIConfiguration::~nsMAPIConfiguration()
{
if (m_Lock)
PR_DestroyLock(m_Lock);
if (m_SessionMap)
{
m_SessionMap->Reset(FreeSessionMapEntries);
delete m_SessionMap;
m_SessionMap = nsnull;
}
if (m_ProfileMap)
{
m_ProfileMap->Reset(FreeProfileMapEntries);
delete m_ProfileMap;
m_ProfileMap = nsnull;
}
}
void nsMAPIConfiguration::OpenConfiguration()
{
// No. of max. sessions is set to MAX_SESSIONS. In future
// if it is decided to have configuration (registry)
// parameter, this function can be used to set the
// max sessions;
return;
}
PRInt16 nsMAPIConfiguration::RegisterSession(PRUint32 aHwnd,
const PRUnichar *aUserName, const PRUnichar *aPassword,
PRBool aForceDownLoad, PRBool aNewSession,
PRUint32 *aSession, char *aIdKey)
{
PRInt16 nResult = 0;
PRUint32 n_SessionId = 0;
PR_Lock(m_Lock);
// Check whether max sessions is exceeded
if (sessionCount >= m_nMaxSessions)
{
PR_Unlock(m_Lock);
return -1;
}
if (aUserName != nsnull && aUserName[0] != '\0')
{
nsStringKey usernameKey(aUserName);
n_SessionId = (PRUint32) m_ProfileMap->Get(&usernameKey);
}
// try to share a session; if not create a session
if (n_SessionId > 0)
{
nsPRUintKey sessionKey(n_SessionId);
nsMAPISession *pTemp = (nsMAPISession *)m_SessionMap->Get(&sessionKey);
if (pTemp != nsnull)
{
pTemp->IncrementSession();
*aSession = n_SessionId;
nResult = 1;
}
}
else if (aNewSession || n_SessionId == 0) // checking for n_SessionId is a concession
{
// create a new session ; if new session is specified OR there is no session
nsMAPISession *pTemp = nsnull;
pTemp = new nsMAPISession(aHwnd, aUserName,
aPassword, aForceDownLoad, aIdKey);
if (pTemp != nsnull)
{
session_generator++;
// I don't think there will be (2 power 32) sessions alive
// in a cycle. This is an assumption
if (session_generator == 0)
session_generator++;
nsPRUintKey sessionKey(session_generator);
m_SessionMap->Put(&sessionKey, pTemp);
if (aUserName != nsnull && aUserName[0] != '\0')
{
nsStringKey usernameKey(aUserName);
m_ProfileMap->Put(&usernameKey, (void*)session_generator);
}
*aSession = session_generator;
sessionCount++;
nResult = 1;
}
}
PR_Unlock(m_Lock);
return nResult;
}
PRBool nsMAPIConfiguration::UnRegisterSession(PRUint32 aSessionID)
{
PRBool bResult = PR_FALSE;
PR_Lock(m_Lock);
if (aSessionID != 0)
{
nsPRUintKey sessionKey(aSessionID);
nsMAPISession *pTemp = (nsMAPISession *)m_SessionMap->Get(&sessionKey);
if (pTemp != nsnull)
{
if (pTemp->DecrementSession() == 0)
{
if (pTemp->m_pProfileName.get() != nsnull)
{
nsStringKey stringKey(pTemp->m_pProfileName.get());
m_ProfileMap->Remove(&stringKey);
}
m_SessionMap->Remove(&sessionKey);
sessionCount--;
bResult = PR_TRUE;
}
}
}
PR_Unlock(m_Lock);
return bResult;
}
PRBool nsMAPIConfiguration::IsSessionValid(PRUint32 aSessionID)
{
if (aSessionID == 0)
return PR_FALSE;
PRBool retValue = PR_FALSE;
nsPRUintKey sessionKey(aSessionID);
PR_Lock(m_Lock);
retValue = m_SessionMap->Exists(&sessionKey);
PR_Unlock(m_Lock);
return retValue;
}
PRUnichar *nsMAPIConfiguration::GetPassWord(PRUint32 aSessionID)
{
PRUnichar *pResult = nsnull;
PR_Lock(m_Lock);
if (aSessionID != 0)
{
nsPRUintKey sessionKey(aSessionID);
nsMAPISession *pTemp = (nsMAPISession *)m_SessionMap->Get(&sessionKey);
if (pTemp)
{
pResult = pTemp->GetPassWord();
}
}
PR_Unlock(m_Lock);
return pResult;
}
char *nsMAPIConfiguration::GetIdKey(PRUint32 aSessionID)
{
char *pResult = nsnull;
PR_Lock(m_Lock);
if (aSessionID != 0)
{
nsPRUintKey sessionKey(aSessionID);
nsMAPISession *pTemp = (nsMAPISession *)m_SessionMap->Get(&sessionKey);
if (pTemp)
{
pResult = pTemp->GetIdKey();
}
}
PR_Unlock(m_Lock);
return pResult;
}
nsMAPISession::nsMAPISession(PRUint32 aHwnd, const PRUnichar *aUserName,\
const PRUnichar *aPassword, \
PRBool aForceDownLoad, char *aKey)
: m_bIsForcedDownLoad(aForceDownLoad),
m_hAppHandle(aHwnd),
m_nShared(1),
m_pIdKey(aKey)
{
m_pProfileName.Assign(aUserName);
m_pPassword.Assign(aPassword);
}
nsMAPISession::~nsMAPISession()
{
if (m_pIdKey != nsnull)
{
delete [] m_pIdKey;
m_pIdKey = nsnull;
}
}
PRUint32 nsMAPISession::IncrementSession()
{
return ++m_nShared;
}
PRUint32 nsMAPISession::DecrementSession()
{
return --m_nShared;
}
PRUint32 nsMAPISession::GetSessionCount()
{
return m_nShared;
}
PRUnichar *nsMAPISession::GetPassWord()
{
return (PRUnichar *)m_pPassword.get();
}
char *nsMAPISession::GetIdKey()
{
return m_pIdKey;
}

View File

@@ -1,104 +0,0 @@
/* ***** BEGIN LICENSE BLOCK *****
* Version: MPL 1.1/GPL 2.0/LGPL 2.1
*
* The contents of this file are subject to the Mozilla Public License Version
* 1.1 (the "License"); you may not use this file except in compliance with
* the License. You may obtain a copy of the License at
* http://www.mozilla.org/MPL/
*
* Software distributed under the License is distributed on an "AS IS" basis,
* WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
* for the specific language governing rights and limitations under the
* License.
*
* The Original Code is Mozilla
*
* The Initial Developer of the Original Code is
* Netscape Communications Corp.
* Portions created by the Initial Developer are Copyright (C) 2001
* the Initial Developer. All Rights Reserved.
*
* Contributor(s): Krishna Mohan Khandrika (kkhandrika@netscape.com)
*
* Alternatively, the contents of this file may be used under the terms of
* either the GNU General Public License Version 2 or later (the "GPL"), or
* the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
* in which case the provisions of the GPL or the LGPL are applicable instead
* of those above. If you wish to allow use of your version of this file only
* under the terms of either the GPL or the LGPL, and not to allow others to
* use your version of this file under the terms of the MPL, indicate your
* decision by deleting the provisions above and replace them with the notice
* and other provisions required by the GPL or the LGPL. If you do not delete
* the provisions above, a recipient may use your version of this file under
* the terms of any one of the MPL, the GPL or the LGPL.
*
* ***** END LICENSE BLOCK ***** */
#ifndef MSG_MAPI_MAIN_H_
#define NSG_MAPI_MAIN_H_
#define MAX_NAME_LEN 256
#define MAX_PW_LEN 256
#define MAX_SESSIONS 50
#include "nsXPIDLString.h"
#include "nspr.h"
#include "nsString.h"
#include "nsHashtable.h"
class nsMAPIConfiguration
{
private :
static PRUint32 session_generator;
static PRUint32 sessionCount;
static nsMAPIConfiguration *m_pSelfRef;
PRLock *m_Lock;
PRUint32 m_nMaxSessions;
nsHashtable *m_ProfileMap;
nsHashtable *m_SessionMap;
nsMAPIConfiguration();
public :
static nsMAPIConfiguration *GetMAPIConfiguration();
void OpenConfiguration();
PRInt16 RegisterSession(PRUint32 aHwnd, const PRUnichar *aUserName, \
const PRUnichar *aPassword, PRBool aForceDownLoad, \
PRBool aNewSession, PRUint32 *aSession, char *aIdKey);
PRBool IsSessionValid(PRUint32 aSessionID);
PRBool UnRegisterSession(PRUint32 aSessionID);
PRUnichar *GetPassWord(PRUint32 aSessionID);
char *GetIdKey(PRUint32 aSessionID);
~nsMAPIConfiguration();
};
class nsMAPISession
{
friend class nsMAPIConfiguration;
private :
PRBool m_bIsForcedDownLoad;
PRBool m_bApp_or_Service;
PRUint32 m_hAppHandle;
PRUint32 m_nShared;
char *m_pIdKey;
nsString m_pProfileName;
nsString m_pPassword;
public :
nsMAPISession(PRUint32 aHwnd, const PRUnichar *aUserName, \
const PRUnichar *aPassword, \
PRBool aForceDownLoad, char *aKey);
PRUint32 IncrementSession();
PRUint32 DecrementSession();
PRUint32 GetSessionCount();
PRUnichar *nsMAPISession::GetPassWord();
char *nsMAPISession::GetIdKey();
~nsMAPISession();
};
#endif // MSG_MAPI_MAIN_H_

View File

@@ -1,48 +0,0 @@
# ***** BEGIN LICENSE BLOCK *****
# Version: MPL 1.1/GPL 2.0/LGPL 2.1
#
# The contents of this file are subject to the Mozilla Public License Version
# 1.1 (the "License"); you may not use this file except in compliance with
# the License. You may obtain a copy of the License at
# http://www.mozilla.org/MPL/
#
# Software distributed under the License is distributed on an "AS IS" basis,
# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
# for the specific language governing rights and limitations under the
# License.
#
# The Original Code is mozilla.org code.
#
# The Initial Developer of the Original Code is
# Netscape Communications Corporation.
# Portions created by the Initial Developer are Copyright (C) 2001
# the Initial Developer. All Rights Reserved.
#
# Contributor(s):
# Srilatha Moturi <srilatha@netscape.com>
#
# Alternatively, the contents of this file may be used under the terms of
# either the GNU General Public License Version 2 or later (the "GPL"), or
# the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
# in which case the provisions of the GPL or the LGPL are applicable instead
# of those above. If you wish to allow use of your version of this file only
# under the terms of either the GPL or the LGPL, and not to allow others to
# use your version of this file under the terms of the MPL, indicate your
# decision by deleting the provisions above and replace them with the notice
# and other provisions required by the GPL or the LGPL. If you do not delete
# the provisions above, a recipient may use your version of this file under
# the terms of any one of the MPL, the GPL or the LGPL.
#
# ***** END LICENSE BLOCK *****
DEPTH=..\..\..\..
MODULE=nsMapiRegistry
XPIDL_MODULE=mapiregistry
XPIDLSRCS = \
.\nsIMapiRegistry.idl \
$(NULL)
include <$(DEPTH)\config\rules.mak>

View File

@@ -1,78 +0,0 @@
/* ***** BEGIN LICENSE BLOCK *****
* Version: MPL 1.1/GPL 2.0/LGPL 2.1
*
* The contents of this file are subject to the Mozilla Public License Version
* 1.1 (the "License"); you may not use this file except in compliance with
* the License. You may obtain a copy of the License at
* http://www.mozilla.org/MPL/
*
* Software distributed under the License is distributed on an "AS IS" basis,
* WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
* for the specific language governing rights and limitations under the
* License.
*
* The Original Code is mozilla.org code.
*
* The Initial Developer of the Original Code is
* Netscape Communications Corporation.
* Portions created by the Initial Developer are Copyright (C) 2001
* the Initial Developer. All Rights Reserved.
*
* Contributor(s):
* Srilatha Moturi <srilatha@netscape.com>
*
* Alternatively, the contents of this file may be used under the terms of
* either the GNU General Public License Version 2 or later (the "GPL"), or
* the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
* in which case the provisions of the GPL or the LGPL are applicable instead
* of those above. If you wish to allow use of your version of this file only
* under the terms of either the GPL or the LGPL, and not to allow others to
* use your version of this file under the terms of the MPL, indicate your
* decision by deleting the provisions above and replace them with the notice
* and other provisions required by the GPL or the LGPL. If you do not delete
* the provisions above, a recipient may use your version of this file under
* the terms of any one of the MPL, the GPL or the LGPL.
*
* ***** END LICENSE BLOCK ***** */
#include "nsISupports.idl"
interface nsIDOMWindow;
/**
* This interface provides support for registering Mozilla as the default
* Mail Client. This interface can also be used to get/set the user preference
* for the default Mail Client.
*
*/
[scriptable, uuid(c5be14ba-4e0a-4eec-a1b8-04363761d63c)]
interface nsIMapiRegistry: nsISupports {
/** This is set to TRUE if Mozilla is the default Application
*/
readonly attribute boolean isDefaultMailClient;
/** This is set TRUE only once per session.
*/
readonly attribute boolean showDialog;
/** This will update the registry keys to set Mozilla as default Mail Client.
*/
void setDefaultMailClient();
/** This will reset the registry keys for the default Mail Client.
*/
void unsetDefaultMailClient();
/** This will bring the dialog asking the user if he/she wants to set
* Mozilla as default Mail Client.
* Call this only if Mozilla is not the default Mail client
*/
void showMailIntegrationDialog(in nsIDOMWindow parentWindow);
};
%{C++
#define NS_IMAPIWINHOOK_CONTRACTID "@mozilla.org/mapiregistry;1"
#define NS_IMAPIWINHOOK_CLASSNAME "Mozilla MAPI Registry"
%}

View File

@@ -35,23 +35,30 @@
*
* ***** END LICENSE BLOCK ***** */
#ifndef _REGISTRY_H_
#define _REGISTRY_H_
#include "nsISupports.idl"
#include <objbase.h>
#include <assert.h>
/**
* This interface provides support for registering Mozilla as a COM component
* for extending the use of Mail/News through Simple MAPI.
*
*/
// This function will register a component in the Registry.
[noscript, uuid(8967fed2-c8bb-11d5-a3e9-00b0d0f3baa7)]
interface nsIMapiSupport : nsISupports {
HRESULT RegisterServer(const CLSID& clsid,
const char* szFriendlyName,
const char* szVerIndProgID,
const char* szProgID) ;
/** Initiates MAPI support
*/
// This function will unregister a component.
void initializeMAPISupport();
HRESULT UnregisterServer(const CLSID& clsid,
const char* szVerIndProgID,
const char* szProgID) ;
/** Shuts down the MAPI support
*/
void shutdownMAPISupport();
};
%{C++
#define NS_IMAPISUPPORT_CONTRACTID "@mozilla.org/mapisupport;1"
#define NS_IMAPISUPPORT_CLASSNAME "Mozilla MAPI Support"
%}
#endif

View File

@@ -1,321 +0,0 @@
/* ***** BEGIN LICENSE BLOCK *****
* Version: MPL 1.1/GPL 2.0/LGPL 2.1
*
* The contents of this file are subject to the Mozilla Public License Version
* 1.1 (the "License"); you may not use this file except in compliance with
* the License. You may obtain a copy of the License at
* http://www.mozilla.org/MPL/
*
* Software distributed under the License is distributed on an "AS IS" basis,
* WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
* for the specific language governing rights and limitations under the
* License.
*
* The Original Code is Mozilla
*
* The Initial Developer of the Original Code is
* Netscape Communications Corp.
* Portions created by the Initial Developer are Copyright (C) 2001
* the Initial Developer. All Rights Reserved.
*
* Contributor(s): Krishna Mohan Khandrika <kkhandrika@netscape.com>
*
* Alternatively, the contents of this file may be used under the terms of
* either the GNU General Public License Version 2 or later (the "GPL"), or
* the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
* in which case the provisions of the GPL or the LGPL are applicable instead
* of those above. If you wish to allow use of your version of this file only
* under the terms of either the GPL or the LGPL, and not to allow others to
* use your version of this file under the terms of the MPL, indicate your
* decision by deleting the provisions above and replace them with the notice
* and other provisions required by the GPL or the LGPL. If you do not delete
* the provisions above, a recipient may use your version of this file under
* the terms of any one of the MPL, the GPL or the LGPL.
*
* ***** END LICENSE BLOCK ***** */
#include <objbase.h>
#include <assert.h>
#include "nsString.h"
#include "Registry.h"
#define MAPI_PROXY_DLL_NAME "MapiProxy.dll"
#define MAPI_STARTUP_ARG " /MAPIStartUp"
#define MAX_SIZE 2048
// Size of a CLSID as a string
const int CLSID_STRING_SIZE = 39;
// Proxy/Stub Dll Routines
typedef HRESULT (__stdcall ProxyServer)();
// Convert a CLSID to a char string.
BOOL CLSIDtochar(const CLSID& clsid, char* szCLSID,
int length)
{
LPOLESTR wszCLSID = NULL;
// Get CLSID
HRESULT hr = StringFromCLSID(clsid, &wszCLSID);
if (FAILED(hr))
return FALSE;
// Covert from wide characters to non-wide.
wcstombs(szCLSID, wszCLSID, length);
// Free memory.
CoTaskMemFree(wszCLSID);
return TRUE;
}
// Create a key and set its value.
BOOL setKeyAndValue(nsCAutoString keyName, const char* subKey,
const char* theValue)
{
HKEY hKey;
BOOL retValue = TRUE;
nsCAutoString theKey(keyName);
if (subKey != NULL)
{
theKey += "\\";
theKey += subKey;
}
// Create and open key and subkey.
long lResult = RegCreateKeyEx(HKEY_CLASSES_ROOT, theKey.get(),
0, NULL, REG_OPTION_NON_VOLATILE,
KEY_ALL_ACCESS, NULL, &hKey, NULL);
if (lResult != ERROR_SUCCESS)
return FALSE ;
// Set the Value.
if (theValue != NULL)
{
lResult = RegSetValueEx(hKey, NULL, 0, REG_SZ, (BYTE *)theValue,
strlen(theValue)+1);
if (lResult != ERROR_SUCCESS)
retValue = FALSE;
}
RegCloseKey(hKey);
return TRUE;
}
// Delete a key and all of its descendents.
LONG recursiveDeleteKey(HKEY hKeyParent, // Parent of key to delete
const char* lpszKeyChild) // Key to delete
{
// Open the child.
HKEY hKeyChild ;
LONG lRes = RegOpenKeyEx(hKeyParent, lpszKeyChild, 0,
KEY_ALL_ACCESS, &hKeyChild) ;
if (lRes != ERROR_SUCCESS)
{
return lRes ;
}
// Enumerate all of the decendents of this child.
FILETIME time ;
char szBuffer[MAX_SIZE] ;
DWORD dwSize = MAX_SIZE ;
while (RegEnumKeyEx(hKeyChild, 0, szBuffer, &dwSize, NULL,
NULL, NULL, &time) == S_OK)
{
// Delete the decendents of this child.
lRes = recursiveDeleteKey(hKeyChild, szBuffer) ;
if (lRes != ERROR_SUCCESS)
{
// Cleanup before exiting.
RegCloseKey(hKeyChild) ;
return lRes;
}
dwSize = MAX_SIZE;
}
// Close the child.
RegCloseKey(hKeyChild) ;
// Delete this child.
return RegDeleteKey(hKeyParent, lpszKeyChild) ;
}
void RegisterProxy()
{
HINSTANCE h = NULL;
ProxyServer *RegisterFunc = NULL;
char szModule[MAX_SIZE];
char *pTemp = NULL;
HMODULE hModule = GetModuleHandle(NULL);
DWORD dwResult = ::GetModuleFileName(hModule, szModule,
sizeof(szModule)/sizeof(char));
if (dwResult == 0)
return;
pTemp = strrchr(szModule, '\\');
if (pTemp == NULL)
return;
*pTemp = '\0';
nsCAutoString proxyPath(szModule);
proxyPath += "\\";
proxyPath += MAPI_PROXY_DLL_NAME;
h = LoadLibrary(proxyPath.get());
if (h == NULL)
return;
RegisterFunc = (ProxyServer *) GetProcAddress(h, "DllRegisterServer");
if (RegisterFunc)
RegisterFunc();
FreeLibrary(h);
}
void UnRegisterProxy()
{
HINSTANCE h = NULL;
ProxyServer *UnRegisterFunc = NULL;
char szModule[MAX_SIZE];
char *pTemp = NULL;
HMODULE hModule = GetModuleHandle(NULL);
DWORD dwResult = ::GetModuleFileName(hModule, szModule,
sizeof(szModule)/sizeof(char));
if (dwResult == 0)
return;
pTemp = strrchr(szModule, '\\');
if (pTemp == NULL)
return;
*pTemp = '\0';
nsCAutoString proxyPath(szModule);
proxyPath += "\\";
proxyPath += MAPI_PROXY_DLL_NAME;
h = LoadLibrary(proxyPath.get());
if (h == NULL)
return;
UnRegisterFunc = (ProxyServer *) GetProcAddress(h, "DllUnregisterServer");
if (UnRegisterFunc)
UnRegisterFunc();
FreeLibrary(h);
}
// Register the component in the registry.
HRESULT RegisterServer(const CLSID& clsid, // Class ID
const char* szFriendlyName, // Friendly Name
const char* szVerIndProgID, // Programmatic
const char* szProgID) // IDs
{
HMODULE hModule = GetModuleHandle(NULL);
char szModuleName[MAX_SIZE];
char szCLSID[CLSID_STRING_SIZE];
nsCAutoString independentProgId(szVerIndProgID);
nsCAutoString progId(szProgID);
DWORD dwResult = ::GetModuleFileName(hModule, szModuleName,
sizeof(szModuleName)/sizeof(char));
if (dwResult == 0)
return S_FALSE;
nsCAutoString moduleName(szModuleName);
nsCAutoString registryKey("CLSID\\");
moduleName += MAPI_STARTUP_ARG;
// Convert the CLSID into a char.
if (!CLSIDtochar(clsid, szCLSID, sizeof(szCLSID)))
return S_FALSE;
registryKey += szCLSID;
// Add the CLSID to the registry.
if (!setKeyAndValue(registryKey, NULL, szFriendlyName))
return S_FALSE;
if (!setKeyAndValue(registryKey, "LocalServer32", moduleName.get()))
return S_FALSE;
// Add the ProgID subkey under the CLSID key.
if (!setKeyAndValue(registryKey, "ProgID", szProgID))
return S_FALSE;
// Add the version-independent ProgID subkey under CLSID key.
if (!setKeyAndValue(registryKey, "VersionIndependentProgID", szVerIndProgID))
return S_FALSE;
// Add the version-independent ProgID subkey under HKEY_CLASSES_ROOT.
if (!setKeyAndValue(independentProgId, NULL, szFriendlyName))
return S_FALSE;
if (!setKeyAndValue(independentProgId, "CLSID", szCLSID))
return S_FALSE;
if (!setKeyAndValue(independentProgId, "CurVer", szProgID))
return S_FALSE;
// Add the versioned ProgID subkey under HKEY_CLASSES_ROOT.
if (!setKeyAndValue(progId, NULL, szFriendlyName))
return S_FALSE;
if (!setKeyAndValue(progId, "CLSID", szCLSID))
return S_FALSE;
RegisterProxy();
return S_OK;
}
LONG UnregisterServer(const CLSID& clsid, // Class ID
const char* szVerIndProgID, // Programmatic
const char* szProgID) // IDs
{
LONG lResult = S_OK;
// Convert the CLSID into a char.
char szCLSID[CLSID_STRING_SIZE];
if (!CLSIDtochar(clsid, szCLSID, sizeof(szCLSID)))
return S_FALSE;
UnRegisterProxy();
nsCAutoString registryKey("CLSID\\");
registryKey += szCLSID;
lResult = recursiveDeleteKey(HKEY_CLASSES_ROOT, registryKey.get());
if (lResult == ERROR_SUCCESS || lResult == ERROR_FILE_NOT_FOUND)
return lResult;
registryKey += "\\LocalServer32";
// Delete only the path for this server.
lResult = recursiveDeleteKey(HKEY_CLASSES_ROOT, registryKey.get());
if (lResult != ERROR_SUCCESS && lResult != ERROR_FILE_NOT_FOUND)
return lResult;
// Delete the version-independent ProgID Key.
lResult = recursiveDeleteKey(HKEY_CLASSES_ROOT, szVerIndProgID);
if (lResult != ERROR_SUCCESS && lResult != ERROR_FILE_NOT_FOUND)
return lResult;
lResult = recursiveDeleteKey(HKEY_CLASSES_ROOT, szProgID);
return lResult;
}

View File

@@ -1,72 +0,0 @@
# ***** BEGIN LICENSE BLOCK *****
# Version: MPL 1.1/GPL 2.0/LGPL 2.1
#
# The contents of this file are subject to the Mozilla Public License Version
# 1.1 (the "License"); you may not use this file except in compliance with
# the License. You may obtain a copy of the License at
# http://www.mozilla.org/MPL/
#
# Software distributed under the License is distributed on an "AS IS" basis,
# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
# for the specific language governing rights and limitations under the
# License.
#
# The Original Code is mozilla.org code.
#
# The Initial Developer of the Original Code is
# Netscape Communications Corporation.
# Portions created by the Initial Developer are Copyright (C) 2001
# the Initial Developer. All Rights Reserved.
#
# Contributor(s):
# Srilatha Moturi <srilatha@netscape.com>
#
# Alternatively, the contents of this file may be used under the terms of
# either the GNU General Public License Version 2 or later (the "GPL"), or
# the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
# in which case the provisions of the GPL or the LGPL are applicable instead
# of those above. If you wish to allow use of your version of this file only
# under the terms of either the GPL or the LGPL, and not to allow others to
# use your version of this file under the terms of the MPL, indicate your
# decision by deleting the provisions above and replace them with the notice
# and other provisions required by the GPL or the LGPL. If you do not delete
# the provisions above, a recipient may use your version of this file under
# the terms of any one of the MPL, the GPL or the LGPL.
#
# ***** END LICENSE BLOCK *****
DEPTH=..\..\..\..
MODULE=nsMapiRegistry
MAKE_OBJ_TYPE = DLL
LIBRARY_NAME=$(MODULE)
MODULE_NAME=nsMapiRegistry
CPPSRCS= \
nsMapiRegistry.cpp \
Registry.cpp \
nsMapiRegistryUtils.cpp \
$(NULL)
CPP_OBJS= \
.\$(OBJDIR)\nsMapiRegistry.obj \
.\$(OBJDIR)\Registry.obj \
.\$(OBJDIR)\nsMapiRegistryUtils.obj \
$(NULL)
LLIBS= \
$(DIST)\lib\xpcom.lib \
$(LIBNSPR) \
$(NULL)
WIN_LIBS= \
ole32.lib \
$(NULL)
EXPORTS= \
nsMapiRegistry.h \
Registry.h \
nsMapiRegistryUtils.h \
$(NULL)
include <$(DEPTH)\config\rules.mak>

View File

@@ -1,121 +0,0 @@
/* ***** BEGIN LICENSE BLOCK *****
* Version: MPL 1.1/GPL 2.0/LGPL 2.1
*
* The contents of this file are subject to the Mozilla Public License Version
* 1.1 (the "License"); you may not use this file except in compliance with
* the License. You may obtain a copy of the License at
* http://www.mozilla.org/MPL/
*
* Software distributed under the License is distributed on an "AS IS" basis,
* WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
* for the specific language governing rights and limitations under the
* License.
*
* The Original Code is Mozilla
*
* The Initial Developer of the Original Code is
* Netscape Communications Corp.
* Portions created by the Initial Developer are Copyright (C) 2001
* the Initial Developer. All Rights Reserved.
*
* Contributor(s): Krishna Mohan Khandrika (kkhandrika@netscape.com)
*
* Alternatively, the contents of this file may be used under the terms of
* either the GNU General Public License Version 2 or later (the "GPL"), or
* the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
* in which case the provisions of the GPL or the LGPL are applicable instead
* of those above. If you wish to allow use of your version of this file only
* under the terms of either the GPL or the LGPL, and not to allow others to
* use your version of this file under the terms of the MPL, indicate your
* decision by deleting the provisions above and replace them with the notice
* and other provisions required by the GPL or the LGPL. If you do not delete
* the provisions above, a recipient may use your version of this file under
* the terms of any one of the MPL, the GPL or the LGPL.
*
* ***** END LICENSE BLOCK ***** */
#undef UNICODE
#undef _UNICODE
#include "msgMapiFactory.h"
#include "msgMapiImp.h"
#include "msgMapi.h"
const CLSID CLSID_nsMapiImp = {0x29f458be, 0x8866, 0x11d5, {0xa3, 0xdd, 0x0, 0xb0, 0xd0, 0xf3, 0xba, 0xa7}};
nsMapiFactory::nsMapiFactory()
: m_cRef(1)
{
}
nsMapiFactory::~nsMapiFactory()
{
}
STDMETHODIMP nsMapiFactory::QueryInterface(const IID& aIid, void** aPpv)
{
if ((aIid == IID_IUnknown) || (aIid == IID_IClassFactory))
{
*aPpv = static_cast<IClassFactory*>(this);
}
else
{
*aPpv = nsnull;
return E_NOINTERFACE;
}
reinterpret_cast<IUnknown*>(*aPpv)->AddRef();
return S_OK;
}
STDMETHODIMP_(ULONG) nsMapiFactory::AddRef()
{
return (PR_AtomicIncrement(&m_cRef));
}
STDMETHODIMP_(ULONG) nsMapiFactory::Release()
{
PRInt32 temp;
temp = PR_AtomicDecrement(&m_cRef);
if (m_cRef == 0)
{
delete this;
return 0;
}
return temp;
}
STDMETHODIMP nsMapiFactory::CreateInstance(IUnknown* aUnknownOuter,
const IID& aIid,
void** aPpv)
{
// Cannot aggregate.
if (aUnknownOuter != nsnull)
{
return CLASS_E_NOAGGREGATION ;
}
// Create component.
nsMapiImp* pImp = new nsMapiImp();
if (pImp == nsnull)
{
return E_OUTOFMEMORY ;
}
// Get the requested interface.
HRESULT hr = pImp->QueryInterface(aIid, aPpv);
// Release the IUnknown pointer.
// (If QueryInterface failed, component will delete itself.)
pImp->Release();
return hr;
}
STDMETHODIMP nsMapiFactory::LockServer(PRBool aLock)
{
return S_OK ;
}

View File

@@ -1,69 +0,0 @@
/* ***** BEGIN LICENSE BLOCK *****
* Version: MPL 1.1/GPL 2.0/LGPL 2.1
*
* The contents of this file are subject to the Mozilla Public License Version
* 1.1 (the "License"); you may not use this file except in compliance with
* the License. You may obtain a copy of the License at
* http://www.mozilla.org/MPL/
*
* Software distributed under the License is distributed on an "AS IS" basis,
* WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
* for the specific language governing rights and limitations under the
* License.
*
* The Original Code is Mozilla
*
* The Initial Developer of the Original Code is
* Netscape Communications Corp.
* Portions created by the Initial Developer are Copyright (C) 2001
* the Initial Developer. All Rights Reserved.
*
* Contributor(s): Krishna Mohan Khandrika (kkhandrika@netscape.com)
*
* Alternatively, the contents of this file may be used under the terms of
* either the GNU General Public License Version 2 or later (the "GPL"), or
* the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
* in which case the provisions of the GPL or the LGPL are applicable instead
* of those above. If you wish to allow use of your version of this file only
* under the terms of either the GPL or the LGPL, and not to allow others to
* use your version of this file under the terms of the MPL, indicate your
* decision by deleting the provisions above and replace them with the notice
* and other provisions required by the GPL or the LGPL. If you do not delete
* the provisions above, a recipient may use your version of this file under
* the terms of any one of the MPL, the GPL or the LGPL.
*
* ***** END LICENSE BLOCK ***** */
#ifndef MSG_MAPI_FACTORY_H
#define MSG_MAPI_FACTORY_H
#include <windows.h>
#include <objbase.h>
#include "nspr.h"
class nsMapiFactory : public IClassFactory
{
public :
// IUnknown
STDMETHODIMP QueryInterface (REFIID aIid, void** aPpv);
STDMETHODIMP_(ULONG) AddRef(void);
STDMETHODIMP_(ULONG) Release(void);
// IClassFactory
STDMETHODIMP CreateInstance (LPUNKNOWN aUnkOuter, REFIID aIid, void **aPpv);
STDMETHODIMP LockServer (BOOL aLock);
nsMapiFactory();
~nsMapiFactory();
private :
PRInt32 m_cRef;
};
#endif // MSG_MAPI_FACTORY_H

View File

@@ -1,842 +0,0 @@
/* ***** BEGIN LICENSE BLOCK *****
* Version: MPL 1.1/GPL 2.0/LGPL 2.1
*
* The contents of this file are subject to the Mozilla Public License Version
* 1.1 (the "License"); you may not use this file except in compliance with
* the License. You may obtain a copy of the License at
* http://www.mozilla.org/MPL/
*
* Software distributed under the License is distributed on an "AS IS" basis,
* WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
* for the specific language governing rights and limitations under the
* License.
*
* The Original Code is Mozilla
*
* The Initial Developer of the Original Code is
* Netscape Communications Corp.
* Portions created by the Initial Developer are Copyright (C) 2001
* the Initial Developer. All Rights Reserved.
*
* Contributor(s): Krishna Mohan Khandrika (kkhandrika@netscape.com)
* Contributor(s): Srilatha Moturi (srilatha@netscape.com)
* Contributor(s): Rajiv Dayal (rdayal@netscape.com)
*
* Alternatively, the contents of this file may be used under the terms of
* either the GNU General Public License Version 2 or later (the "GPL"), or
* the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
* in which case the provisions of the GPL or the LGPL are applicable instead
* of those above. If you wish to allow use of your version of this file only
* under the terms of either the GPL or the LGPL, and not to allow others to
* use your version of this file under the terms of the MPL, indicate your
* decision by deleting the provisions above and replace them with the notice
* and other provisions required by the GPL or the LGPL. If you do not delete
* the provisions above, a recipient may use your version of this file under
* the terms of any one of the MPL, the GPL or the LGPL.
*
* ***** END LICENSE BLOCK ***** */
#define MAPI_STARTUP_ARG "/MAPIStartUp"
#define MAPI_STARTUP_ARG "/MAPIStartUp"
#include <mapidefs.h>
#include <mapi.h>
#include "nsCOMPtr.h"
#include "nsIComponentManager.h"
#include "nsIServiceManager.h"
#include "nsISupports.h"
#include "nsIPromptService.h"
#include "nsAppShellCIDs.h"
#include "nsIDOMWindowInternal.h"
#include "nsIAppShellService.h"
#include "nsINativeAppSupport.h"
#include "nsICmdLineService.h"
#include "nsIProfileInternal.h"
#include "nsIMsgAccountManager.h"
#include "nsIDOMWindowInternal.h"
#include "nsXPIDLString.h"
#include "nsReadableUtils.h"
#include "nsMsgBaseCID.h"
#include "nsIStringBundle.h"
#include "nsIPref.h"
#include "nsString.h"
#include "nsIMsgCompFields.h"
#include "nsIMsgComposeParams.h"
#include "nsIMsgCompose.h"
#include "nsMsgCompCID.h"
#include "nsIMsgSend.h"
#include "nsIProxyObjectManager.h"
#include "nsIMsgComposeService.h"
#include "nsProxiedService.h"
#include "nsSpecialSystemDirectory.h"
#include "nsMsgI18N.h"
#include "msgMapi.h"
#include "msgMapiHook.h"
#include "msgMapiSupport.h"
#include "msgMapiMain.h"
static NS_DEFINE_CID(kCmdLineServiceCID, NS_COMMANDLINE_SERVICE_CID);
#define MAPI_PROPERTIES_CHROME "chrome://messenger/locale/mapi.properties"
#define PREF_MAPI_WARN_PRIOR_TO_BLIND_SEND "mapi.blind-send.warn"
#define PREF_MAPI_BLIND_SEND_ENABLED "mapi.blind-send.enabled"
class nsMAPISendListener : public nsIMsgSendListener
{
public:
virtual ~nsMAPISendListener() { }
// nsISupports interface
NS_DECL_ISUPPORTS
/* void OnStartSending (in string aMsgID, in PRUint32 aMsgSize); */
NS_IMETHOD OnStartSending(const char *aMsgID, PRUint32 aMsgSize) { return NS_OK; }
/* void OnProgress (in string aMsgID, in PRUint32 aProgress, in PRUint32 aProgressMax); */
NS_IMETHOD OnProgress(const char *aMsgID, PRUint32 aProgress, PRUint32 aProgressMax) { return NS_OK;}
/* void OnStatus (in string aMsgID, in wstring aMsg); */
NS_IMETHOD OnStatus(const char *aMsgID, const PRUnichar *aMsg) { return NS_OK;}
/* void OnStopSending (in string aMsgID, in nsresult aStatus, in wstring aMsg, in nsIFileSpec returnFileSpec); */
NS_IMETHOD OnStopSending(const char *aMsgID, nsresult aStatus, const PRUnichar *aMsg,
nsIFileSpec *returnFileSpec) {
#ifdef RAJIV_DEBUG
printf("Sending Done - OnStopSending \n");
#endif
m_done = PR_TRUE;
return NS_OK ;
}
/* void OnGetDraftFolderURI (); */
NS_IMETHOD OnGetDraftFolderURI(const char *aFolderURI) {return NS_OK;}
static nsresult CreateMAPISendListener( nsIMsgSendListener **ppListener);
PRBool IsDone() { return m_done ; }
protected :
nsMAPISendListener() {
NS_INIT_REFCNT();
m_done = PR_FALSE;
}
PRBool m_done;
};
NS_IMPL_THREADSAFE_ISUPPORTS1(nsMAPISendListener, nsIMsgSendListener)
nsresult nsMAPISendListener::CreateMAPISendListener( nsIMsgSendListener **ppListener)
{
NS_ENSURE_ARG_POINTER(ppListener) ;
*ppListener = new nsMAPISendListener();
if (! *ppListener)
return NS_ERROR_OUT_OF_MEMORY;
NS_ADDREF(*ppListener);
return NS_OK;
}
PRBool nsMapiHook::isMapiService = PR_FALSE;
PRBool nsMapiHook::Initialize()
{
nsresult rv;
nsCOMPtr<nsINativeAppSupport> native;
nsCOMPtr<nsICmdLineService> cmdLineArgs(do_GetService(kCmdLineServiceCID, &rv));
if (NS_FAILED(rv)) return PR_FALSE;
nsCOMPtr<nsIAppShellService> appShell (do_GetService( "@mozilla.org/appshell/appShellService;1", &rv));
if (NS_FAILED(rv)) return PR_FALSE;
rv = appShell->GetNativeAppSupport( getter_AddRefs( native ));
if (NS_FAILED(rv)) return PR_FALSE;
rv = native->EnsureProfile(cmdLineArgs);
if (NS_FAILED(rv)) return PR_FALSE;
return PR_TRUE;
}
void nsMapiHook::CleanUp()
{
// This routine will be fully implemented in future
// to cleanup mapi related stuff inside mozilla code.
}
PRBool nsMapiHook::DisplayLoginDialog(PRBool aLogin, PRUnichar **aUsername, \
PRUnichar **aPassword)
{
nsresult rv;
PRBool btnResult = PR_FALSE;
nsCOMPtr<nsIAppShellService> appShell(do_GetService( "@mozilla.org/appshell/appShellService;1", &rv));
if (NS_FAILED(rv) || !appShell) return PR_FALSE;
nsCOMPtr<nsIPromptService> dlgService(do_GetService("@mozilla.org/embedcomp/prompt-service;1", &rv));
if (NS_SUCCEEDED(rv) && dlgService)
{
nsCOMPtr<nsIStringBundleService> bundleService(do_GetService(NS_STRINGBUNDLE_CONTRACTID, &rv));
if (NS_FAILED(rv) || !bundleService) return PR_FALSE;
nsCOMPtr<nsIStringBundle> bundle;
rv = bundleService->CreateBundle(MAPI_PROPERTIES_CHROME, getter_AddRefs(bundle));
if (NS_FAILED(rv) || !bundle) return PR_FALSE;
nsCOMPtr<nsIStringBundle> brandBundle;
rv = bundleService->CreateBundle(
"chrome://global/locale/brand.properties",
getter_AddRefs(brandBundle));
if (NS_FAILED(rv)) return PR_FALSE;
nsXPIDLString brandName;
rv = brandBundle->GetStringFromName(
NS_LITERAL_STRING("brandShortName").get(),
getter_Copies(brandName));
if (NS_FAILED(rv)) return PR_FALSE;
nsXPIDLString loginTitle;
const PRUnichar *brandStrings[] = { brandName.get() };
NS_NAMED_LITERAL_STRING(loginTitlePropertyTag, "loginTitle");
const PRUnichar *dTitlePropertyTag = loginTitlePropertyTag.get();
rv = bundle->FormatStringFromName(dTitlePropertyTag, brandStrings, 1,
getter_Copies(loginTitle));
if (NS_FAILED(rv)) return PR_FALSE;
if (aLogin)
{
nsXPIDLString loginText;
rv = bundle->GetStringFromName(NS_LITERAL_STRING("loginTextwithName").get(),
getter_Copies(loginText));
if (NS_FAILED(rv) || !loginText) return PR_FALSE;
rv = dlgService->PromptUsernameAndPassword(nsnull, loginTitle,
loginText, aUsername, aPassword,
nsnull, PR_FALSE, &btnResult);
}
else
{
//nsString loginString;
nsXPIDLString loginText;
const PRUnichar *userNameStrings[] = { *aUsername };
NS_NAMED_LITERAL_STRING(loginTextPropertyTag, "loginText");
const PRUnichar *dpropertyTag = loginTextPropertyTag.get();
rv = bundle->FormatStringFromName(dpropertyTag, userNameStrings, 1,
getter_Copies(loginText));
if (NS_FAILED(rv)) return PR_FALSE;
rv = dlgService->PromptPassword(nsnull, loginTitle, loginText,
aPassword, nsnull, PR_FALSE, &btnResult);
}
}
return btnResult;
}
PRBool nsMapiHook::VerifyUserName(const PRUnichar *aUsername, char **aIdKey)
{
nsresult rv;
if (aUsername == nsnull)
return PR_FALSE;
nsCOMPtr<nsIMsgAccountManager> accountManager(do_GetService(NS_MSGACCOUNTMANAGER_CONTRACTID, &rv));
if (NS_FAILED(rv)) return PR_FALSE;
nsCOMPtr<nsISupportsArray> identities;
rv = accountManager->GetAllIdentities(getter_AddRefs(identities));
if (NS_FAILED(rv)) return PR_FALSE;
PRUint32 numIndentities;
identities->Count(&numIndentities);
for (PRUint32 i = 0; i < numIndentities; i++)
{
// convert supports->Identity
nsCOMPtr<nsISupports> thisSupports;
rv = identities->GetElementAt(i, getter_AddRefs(thisSupports));
if (NS_FAILED(rv)) continue;
nsCOMPtr<nsIMsgIdentity> thisIdentity(do_QueryInterface(thisSupports, &rv));
if (NS_SUCCEEDED(rv) && thisIdentity)
{
nsXPIDLCString email;
rv = thisIdentity->GetEmail(getter_Copies(email));
if (NS_FAILED(rv)) continue;
// get the username from the email and compare with the username
nsCAutoString aEmail(email.get());
PRInt32 index = aEmail.FindChar('@');
if (index != -1)
aEmail.Truncate(index);
if (nsDependentString(aUsername) == NS_ConvertASCIItoUCS2(aEmail)) // == overloaded
return NS_SUCCEEDED(thisIdentity->GetKey(aIdKey));
}
}
return PR_FALSE;
}
PRBool
nsMapiHook::IsBlindSendAllowed()
{
PRBool enabled = PR_FALSE;
PRBool warn = PR_TRUE;
nsCOMPtr<nsIPref> prefs = do_GetService(NS_PREF_CONTRACTID);
if (prefs) {
prefs->GetBoolPref(PREF_MAPI_WARN_PRIOR_TO_BLIND_SEND,&warn);
prefs->GetBoolPref(PREF_MAPI_BLIND_SEND_ENABLED,&enabled);
}
if (!enabled)
return PR_FALSE;
if (!warn)
return PR_TRUE; // Everything is okay.
nsresult rv;
nsCOMPtr<nsIStringBundleService> bundleService(do_GetService(NS_STRINGBUNDLE_CONTRACTID, &rv));
if (NS_FAILED(rv) || !bundleService) return PR_FALSE;
nsCOMPtr<nsIStringBundle> bundle;
rv = bundleService->CreateBundle(MAPI_PROPERTIES_CHROME, getter_AddRefs(bundle));
if (NS_FAILED(rv) || !bundle) return PR_FALSE;
nsXPIDLString warningMsg;
rv = bundle->GetStringFromName(NS_LITERAL_STRING("mapiBlindSendWarning").get(),
getter_Copies(warningMsg));
if (NS_FAILED(rv)) return PR_FALSE;
nsXPIDLString dontShowAgainMessage;
rv = bundle->GetStringFromName(NS_LITERAL_STRING("mapiBlindSendDontShowAgain").get(),
getter_Copies(dontShowAgainMessage));
if (NS_FAILED(rv)) return PR_FALSE;
nsCOMPtr<nsIPromptService> dlgService(do_GetService("@mozilla.org/embedcomp/prompt-service;1", &rv));
if (NS_FAILED(rv) || !dlgService) return PR_FALSE;
PRBool continueToWarn = PR_TRUE;
PRBool okayToContinue = PR_FALSE;
dlgService->ConfirmCheck(nsnull, nsnull, warningMsg, dontShowAgainMessage, &continueToWarn, &okayToContinue);
if (!continueToWarn && okayToContinue && prefs)
prefs->SetBoolPref(PREF_MAPI_WARN_PRIOR_TO_BLIND_SEND,PR_FALSE);
return okayToContinue;
}
// this is used for Send without UI
nsresult nsMapiHook::BlindSendMail (unsigned long aSession, nsIMsgCompFields * aCompFields)
{
nsresult rv = NS_OK ;
if (!IsBlindSendAllowed())
return NS_ERROR_FAILURE;
/** create nsIMsgComposeParams obj and other fields to populate it **/
// get parent window
nsCOMPtr<nsIAppShellService> appService = do_GetService( "@mozilla.org/appshell/appShellService;1", &rv);
if (NS_FAILED(rv)|| (!appService) ) return rv ;
nsCOMPtr<nsIDOMWindowInternal> hiddenWindow;
rv = appService->GetHiddenDOMWindow(getter_AddRefs(hiddenWindow));
if ( NS_FAILED(rv) ) return rv ;
// smtp password and Logged in used IdKey from MapiConfig (session obj)
nsMAPIConfiguration * pMapiConfig = nsMAPIConfiguration::GetMAPIConfiguration() ;
if (!pMapiConfig) return NS_ERROR_FAILURE ; // get the singelton obj
PRUnichar * password = pMapiConfig->GetPassWord(aSession) ;
// password
nsCAutoString smtpPassword ;
smtpPassword.AssignWithConversion (password) ;
// Id key
char * MsgIdKey = pMapiConfig->GetIdKey(aSession) ;
// get the MsgIdentity for the above key using AccountManager
nsCOMPtr <nsIMsgAccountManager> accountManager = do_GetService (NS_MSGACCOUNTMANAGER_CONTRACTID) ;
if (NS_FAILED(rv) || (!accountManager) ) return rv ;
nsCOMPtr <nsIMsgIdentity> pMsgId ;
rv = accountManager->GetIdentity (MsgIdKey, getter_AddRefs(pMsgId)) ;
if (NS_FAILED(rv) ) return rv ;
// create a send listener to get back the send status
nsCOMPtr <nsIMsgSendListener> sendListener ;
rv = nsMAPISendListener::CreateMAPISendListener(getter_AddRefs(sendListener)) ;
if (NS_FAILED(rv) || (!sendListener) ) return rv;
// create the compose params object
nsCOMPtr<nsIMsgComposeParams> pMsgComposeParams (do_CreateInstance(NS_MSGCOMPOSEPARAMS_CONTRACTID, &rv));
if (NS_FAILED(rv) || (!pMsgComposeParams) ) return rv ;
// populate the compose params
pMsgComposeParams->SetType(nsIMsgCompType::New);
pMsgComposeParams->SetFormat(nsIMsgCompFormat::Default);
pMsgComposeParams->SetIdentity(pMsgId);
pMsgComposeParams->SetComposeFields(aCompFields);
pMsgComposeParams->SetSendListener(sendListener) ;
pMsgComposeParams->SetSmtpPassword(smtpPassword);
// create the nsIMsgCompose object to send the object
nsCOMPtr<nsIMsgCompose> pMsgCompose (do_CreateInstance(NS_MSGCOMPOSE_CONTRACTID, &rv));
if (NS_FAILED(rv) || (!pMsgCompose) ) return rv ;
/** initialize nsIMsgCompose, Send the message, wait for send completion response **/
rv = pMsgCompose->Initialize(hiddenWindow, pMsgComposeParams) ;
if (NS_FAILED(rv)) return rv ;
pMsgCompose->SendMsg(nsIMsgSend::nsMsgDeliverNow, pMsgId, nsnull) ;
if (NS_FAILED(rv)) return rv ;
// assign to interface pointer from nsCOMPtr to facilitate typecast below
nsIMsgSendListener * pSendListener = sendListener ;
// we need to wait here to make sure that we return only after send is completed
// so we will have a event loop here which will process the events till the Send IsDone.
nsCOMPtr<nsIEventQueueService> pEventQService = do_GetService(NS_EVENTQUEUESERVICE_CONTRACTID, &rv);
nsCOMPtr<nsIEventQueue> eventQueue;
pEventQService->GetThreadEventQueue(NS_CURRENT_THREAD,getter_AddRefs(eventQueue));
while ( !((nsMAPISendListener *) pSendListener)->IsDone() )
eventQueue->ProcessPendingEvents();
return rv ;
}
// this is used to populate comp fields with Unicode data
nsresult nsMapiHook::PopulateCompFields(lpnsMapiMessage aMessage,
nsIMsgCompFields * aCompFields)
{
nsresult rv = NS_OK ;
if (aMessage->lpOriginator)
{
PRUnichar * From = aMessage->lpOriginator->lpszAddress ;
aCompFields->SetFrom (From) ;
}
nsAutoString To ;
nsAutoString Cc ;
nsAutoString Bcc ;
nsAutoString Comma ;
Comma.AssignWithConversion(",");
if (aMessage->lpRecips)
{
for (int i=0 ; i < (int) aMessage->nRecipCount ; i++)
{
if (aMessage->lpRecips[i].lpszAddress)
{
switch (aMessage->lpRecips[i].ulRecipClass)
{
case MAPI_TO :
if (To.Length() > 0)
To += Comma ;
To += (PRUnichar *) aMessage->lpRecips[i].lpszAddress ;
break ;
case MAPI_CC :
if (Cc.Length() > 0)
Cc += Comma ;
Cc += (PRUnichar *) aMessage->lpRecips[i].lpszAddress ;
break ;
case MAPI_BCC :
if (Bcc.Length() > 0)
Bcc += Comma ;
Bcc += (PRUnichar *) aMessage->lpRecips[i].lpszAddress ;
break ;
}
}
}
}
// set To, Cc, Bcc
aCompFields->SetTo (To.get()) ;
aCompFields->SetCc (Cc.get()) ;
aCompFields->SetBcc (Bcc.get()) ;
// set subject
if (aMessage->lpszSubject)
{
PRUnichar * Subject = aMessage->lpszSubject ;
aCompFields->SetSubject(Subject) ;
}
// handle attachments as File URL
rv = HandleAttachments (aCompFields, aMessage->nFileCount, aMessage->lpFiles, PR_TRUE) ;
if (NS_FAILED(rv)) return rv ;
// set body
if (aMessage->lpszNoteText)
{
PRUnichar * Body = aMessage->lpszNoteText ;
rv = aCompFields->SetBody(Body) ;
}
#ifdef RAJIV_DEBUG
// testing what all was set in CompFields
printf ("To : %S \n", To.get()) ;
printf ("CC : %S \n", Cc.get() ) ;
printf ("BCC : %S \n", Bcc.get() ) ;
#endif
return rv ;
}
nsresult nsMapiHook::HandleAttachments (nsIMsgCompFields * aCompFields, PRInt32 aFileCount,
lpnsMapiFileDesc aFiles, BOOL aIsUnicode)
{
nsresult rv = NS_OK ;
nsCAutoString Attachments ;
nsCAutoString TempFiles ;
nsCOMPtr <nsILocalFile> pFile = do_CreateInstance (NS_LOCAL_FILE_CONTRACTID, &rv) ;
if (NS_FAILED(rv) || (!pFile) ) return rv ;
nsCOMPtr <nsILocalFile> pTempDir = do_CreateInstance (NS_LOCAL_FILE_CONTRACTID, &rv) ;
if (NS_FAILED(rv) || (!pTempDir) ) return rv ;
for (int i=0 ; i < aFileCount ; i++)
{
PRBool bTempFile = PR_FALSE ;
if (aFiles[i].lpszPathName)
{
if (aIsUnicode)
pFile->InitWithUnicodePath (aFiles[i].lpszPathName) ;
else
pFile->InitWithPath ((char *) aFiles[i].lpszPathName) ;
PRBool bExist ;
rv = pFile->Exists(&bExist) ;
if (NS_FAILED(rv) || (!bExist) ) return NS_ERROR_FILE_TARGET_DOES_NOT_EXIST ;
// we do this since MS Office apps create a temp file when sending
// the currently open document in that app
if (aFiles[i].lpszFileName)
{
// Win temp Path
nsAutoString tempPath ;
nsSpecialSystemDirectory tmpDir(nsSpecialSystemDirectory::OS_TemporaryDirectory);
((nsFileSpec*)&tmpDir)->GetNativePathString(tempPath);
tempPath.ToLowerCase() ;
// filename of the file attachment
nsXPIDLString pLeafName ;
pFile->GetUnicodeLeafName (getter_Copies(pLeafName)) ;
// dir path of the file attachment
nsXPIDLString pPath ;
pFile->GetUnicodePath (getter_Copies(pPath)) ;
nsAutoString Path ;
Path.Assign(pPath.get()) ;
nsAutoString LeafName ;
LeafName.Assign (pLeafName.get());
PRInt32 offset = Path.RFind (LeafName) ;
Path.SetLength(offset) ;
Path.ToLowerCase() ;
if (tempPath == Path)
{
// create another temp dir for mapi within Win temp dir
nsAutoString strTempDir ;
strTempDir += tempPath.get() ;
strTempDir.AppendWithConversion("moz_mapi") ;
pTempDir->InitWithUnicodePath (strTempDir.get()) ;
pTempDir->Exists (&bExist) ;
if (!bExist)
{
rv = pTempDir->Create(nsIFile::DIRECTORY_TYPE, 777) ;
if (NS_FAILED(rv)) return rv ;
}
// filename passed for the file attachment
if (aIsUnicode)
{
nsAutoString RealFileName ;
RealFileName.Assign (aFiles[i].lpszFileName) ;
// copy to our mapi temp dir with real name
rv = pFile->CopyToUnicode(pTempDir, RealFileName.get()) ;
if (NS_FAILED(rv)) return rv ;
pFile->InitWithUnicodePath(strTempDir.get()) ;
pFile->AppendUnicode (RealFileName.get()) ;
}
else
{
nsCAutoString asciiRealFileName ;
asciiRealFileName.Assign((char *) aFiles[i].lpszFileName) ;
nsCAutoString asciiLeafName ;
asciiLeafName.AssignWithConversion (pLeafName.get());
// copy to our mapi temp dir with real name
rv = pFile->CopyTo(pTempDir, asciiRealFileName.get()) ;
if (NS_FAILED(rv)) return rv ;
pFile->InitWithUnicodePath(strTempDir.get()) ;
pFile->Append (asciiRealFileName.get()) ;
}
// this one is a temp file
bTempFile = PR_TRUE ;
}
}
// get url
nsXPIDLCString pURL ;
pFile->GetURL (getter_Copies(pURL)) ;
if (pURL)
{
if (Attachments.Length() > 0)
Attachments.Append(",") ;
Attachments.Append(pURL) ;
if (bTempFile)
{
if (TempFiles.Length() > 0)
TempFiles.Append(",") ;
TempFiles.Append(pURL) ;
}
}
}
}
// set attachment
if (Attachments.Length() > 0)
rv = aCompFields->SetAttachments (Attachments.get());
// set temp file
if (TempFiles.Length() > 0)
rv = aCompFields->SetTemporaryFiles(TempFiles.get());
#ifdef RAJIV_DEBUG
printf ("Attachments : %s \n", Attachments.get()) ;
printf ("TempFiles : %s \n", TempFiles.get()) ;
#endif
return rv ;
}
// this is used to convert non Unicode data and then populate comp fields
nsresult nsMapiHook::PopulateCompFieldsWithConversion(lpnsMapiMessage aMessage,
nsIMsgCompFields * aCompFields)
{
nsresult rv = NS_OK ;
if (aMessage->lpOriginator)
{
nsAutoString From ;
From.AssignWithConversion((char *) aMessage->lpOriginator->lpszAddress);
aCompFields->SetFrom (From.get()) ;
}
nsAutoString To ;
nsAutoString Cc ;
nsAutoString Bcc ;
nsAutoString Comma ;
Comma.AssignWithConversion(",");
if (aMessage->lpRecips)
{
for (int i=0 ; i < (int) aMessage->nRecipCount ; i++)
{
if (aMessage->lpRecips[i].lpszAddress)
{
switch (aMessage->lpRecips[i].ulRecipClass)
{
case MAPI_TO :
if (To.Length() > 0)
To += Comma ;
To.AppendWithConversion ((char *) aMessage->lpRecips[i].lpszAddress);
break ;
case MAPI_CC :
if (Cc.Length() > 0)
Cc += Comma ;
Cc.AppendWithConversion ((char *) aMessage->lpRecips[i].lpszAddress);
break ;
case MAPI_BCC :
if (Bcc.Length() > 0)
Bcc += Comma ;
Bcc.AppendWithConversion ((char *) aMessage->lpRecips[i].lpszAddress) ;
break ;
}
}
}
}
// set To, Cc, Bcc
aCompFields->SetTo (To.get()) ;
aCompFields->SetCc (Cc.get()) ;
aCompFields->SetBcc (Bcc.get()) ;
nsAutoString platformCharSet;
// set subject
if (aMessage->lpszSubject)
{
nsAutoString Subject ;
if (platformCharSet.IsEmpty())
platformCharSet.Assign(nsMsgI18NFileSystemCharset());
rv = ConvertToUnicode(platformCharSet, (char *) aMessage->lpszSubject, Subject);
if (NS_FAILED(rv)) return rv ;
aCompFields->SetSubject(Subject.get()) ;
}
// handle attachments as File URL
rv = HandleAttachments (aCompFields, aMessage->nFileCount, aMessage->lpFiles, PR_FALSE) ;
if (NS_FAILED(rv)) return rv ;
// set body
if (aMessage->lpszNoteText)
{
nsAutoString Body ;
if (platformCharSet.IsEmpty())
platformCharSet.Assign(nsMsgI18NFileSystemCharset());
rv = ConvertToUnicode(platformCharSet, (char *) aMessage->lpszNoteText, Body);
if (NS_FAILED(rv)) return rv ;
rv = aCompFields->SetBody(Body.get()) ;
}
#ifdef RAJIV_DEBUG
// testing what all was set in CompFields
printf ("To : %S \n", To.get()) ;
printf ("CC : %S \n", Cc.get() ) ;
printf ("BCC : %S \n", Bcc.get() ) ;
#endif
return rv ;
}
// this is used to populate the docs as attachments in the Comp fields for Send Documents
nsresult nsMapiHook::PopulateCompFieldsForSendDocs(nsIMsgCompFields * aCompFields, ULONG aFlags,
PRUnichar * aDelimChar, PRUnichar * aFilePaths)
{
nsAutoString strDelimChars ;
nsString strFilePaths;
nsresult rv = NS_OK ;
if (aFlags & MAPI_UNICODE)
{
if (aDelimChar)
strDelimChars.Assign (aDelimChar) ;
if (aFilePaths)
strFilePaths.Assign (aFilePaths) ;
}
else
{
if (aDelimChar)
strDelimChars.AssignWithConversion ((char*) aDelimChar) ;
if (aFilePaths)
strFilePaths.AssignWithConversion ((char *) aFilePaths) ;
}
// check for comma in filename
if (strDelimChars.Find (",") == kNotFound) // if comma is not in the delimiter specified by user
{
if (strFilePaths.Find(",") != kNotFound) // if comma found in filenames return error
return NS_ERROR_FILE_INVALID_PATH ;
}
nsCString Attachments ;
// only 1 file is to be sent, no delim specified
if ((!strDelimChars.Length()) && (strFilePaths.Length()>0))
{
nsCOMPtr <nsILocalFile> pFile = do_CreateInstance (NS_LOCAL_FILE_CONTRACTID, &rv) ;
if (NS_FAILED(rv) || (!pFile) ) return rv ;
pFile->InitWithUnicodePath (strFilePaths.get()) ;
PRBool bExist ;
rv = pFile->Exists(&bExist) ;
if (NS_FAILED(rv) || (!bExist) ) return NS_ERROR_FILE_TARGET_DOES_NOT_EXIST ;
nsXPIDLCString pURL ;
pFile->GetURL (getter_Copies(pURL)) ;
if (pURL)
Attachments.Assign(pURL) ;
// set attachments for comp field and return
rv = aCompFields->SetAttachments (Attachments.get());
return rv ;
}
// multiple files to be sent, delim specified
nsCOMPtr <nsILocalFile> pFile = do_CreateInstance (NS_LOCAL_FILE_CONTRACTID, &rv) ;
if (NS_FAILED(rv) || (!pFile) ) return rv ;
PRInt32 offset = 0 ;
PRInt32 FilePathsLen = strFilePaths.Length() ;
if (FilePathsLen)
{
PRUnichar * newFilePaths = (PRUnichar *) strFilePaths.get() ;
while (offset != kNotFound)
{
nsString RemainingPaths ;
RemainingPaths.Assign(newFilePaths) ;
offset = RemainingPaths.Find (strDelimChars) ;
if (offset != kNotFound)
{
RemainingPaths.SetLength (offset) ;
if ((offset + strDelimChars.Length()) < FilePathsLen)
newFilePaths += offset + strDelimChars.Length() ;
}
pFile->InitWithUnicodePath (RemainingPaths.get()) ;
#ifdef RAJIV_DEBUG
printf ("File : %S \n", RemainingPaths.get()) ;
#endif
PRBool bExist ;
rv = pFile->Exists(&bExist) ;
if (NS_FAILED(rv) || (!bExist) ) return NS_ERROR_FILE_TARGET_DOES_NOT_EXIST ;
nsXPIDLCString pURL ;
pFile->GetURL (getter_Copies(pURL)) ;
if (pURL)
{
if (Attachments.Length() > 0)
Attachments.Append(",") ;
Attachments.Append(pURL) ;
}
}
rv = aCompFields->SetAttachments (Attachments.get());
}
return rv ;
}
// this used for Send with UI
nsresult nsMapiHook::ShowComposerWindow (unsigned long aSession, nsIMsgCompFields * aCompFields)
{
nsresult rv = NS_OK ;
// create a send listener to get back the send status
nsCOMPtr <nsIMsgSendListener> sendListener ;
rv = nsMAPISendListener::CreateMAPISendListener(getter_AddRefs(sendListener)) ;
if (NS_FAILED(rv) || (!sendListener) ) return rv ;
// create the compose params object
nsCOMPtr<nsIMsgComposeParams> pMsgComposeParams (do_CreateInstance(NS_MSGCOMPOSEPARAMS_CONTRACTID, &rv));
if (NS_FAILED(rv) || (!pMsgComposeParams) ) return rv ;
// populate the compose params
pMsgComposeParams->SetType(nsIMsgCompType::New);
pMsgComposeParams->SetFormat(nsIMsgCompFormat::Default);
pMsgComposeParams->SetComposeFields(aCompFields);
pMsgComposeParams->SetSendListener(sendListener) ;
/** get the nsIMsgComposeService object to open the compose window **/
nsCOMPtr <nsIMsgComposeService> compService = do_GetService (NS_MSGCOMPOSESERVICE_CONTRACTID) ;
if (NS_FAILED(rv)|| (!compService) ) return rv ;
rv = compService->OpenComposeWindowWithParams(nsnull, pMsgComposeParams) ;
if (NS_FAILED(rv)) return rv ;
return rv ;
}

View File

@@ -1,66 +0,0 @@
/* ***** BEGIN LICENSE BLOCK *****
* Version: MPL 1.1/GPL 2.0/LGPL 2.1
*
* The contents of this file are subject to the Mozilla Public License Version
* 1.1 (the "License"); you may not use this file except in compliance with
* the License. You may obtain a copy of the License at
* http://www.mozilla.org/MPL/
*
* Software distributed under the License is distributed on an "AS IS" basis,
* WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
* for the specific language governing rights and limitations under the
* License.
*
* The Original Code is Mozilla
*
* The Initial Developer of the Original Code is
* Netscape Communications Corp.
* Portions created by the Initial Developer are Copyright (C) 2001
* the Initial Developer. All Rights Reserved.
*
* Contributor(s): Krishna Mohan Khandrika (kkhandrika@netscape.com)
*
* Alternatively, the contents of this file may be used under the terms of
* either the GNU General Public License Version 2 or later (the "GPL"), or
* the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
* in which case the provisions of the GPL or the LGPL are applicable instead
* of those above. If you wish to allow use of your version of this file only
* under the terms of either the GPL or the LGPL, and not to allow others to
* use your version of this file under the terms of the MPL, indicate your
* decision by deleting the provisions above and replace them with the notice
* and other provisions required by the GPL or the LGPL. If you do not delete
* the provisions above, a recipient may use your version of this file under
* the terms of any one of the MPL, the GPL or the LGPL.
*
* ***** END LICENSE BLOCK ***** */
#ifndef MSG_MAPI_HOOK_H_
#define MSG_MAPI_HOOK_H_
#include "prtypes.h"
class nsMapiHook
{
public :
static PRBool Initialize();
static PRBool DisplayLoginDialog(PRBool aLogin, PRUnichar **aUsername,
PRUnichar **aPassword);
static PRBool VerifyUserName(const PRUnichar *aUsername, char **aIdKey);
static PRBool IsBlindSendAllowed () ;
static nsresult BlindSendMail (unsigned long aSession, nsIMsgCompFields * aCompFields) ;
static nsresult ShowComposerWindow (unsigned long aSession, nsIMsgCompFields * aCompFields) ;
static nsresult PopulateCompFields(lpnsMapiMessage aMessage, nsIMsgCompFields * aCompFields) ;
static nsresult PopulateCompFieldsWithConversion(lpnsMapiMessage aMessage,
nsIMsgCompFields * aCompFields) ;
static nsresult PopulateCompFieldsForSendDocs(nsIMsgCompFields * aCompFields,
ULONG aFlags, LPTSTR aDelimChar, LPTSTR aFilePaths) ;
static nsresult HandleAttachments (nsIMsgCompFields * aCompFields, PRInt32 aFileCount,
lpnsMapiFileDesc aFiles, BOOL aIsUnicode) ;
static void CleanUp();
static PRBool isMapiService;
};
#endif // MSG_MAPI_HOOK_H_

View File

@@ -1,335 +0,0 @@
/* ***** BEGIN LICENSE BLOCK *****
* Version: MPL 1.1/GPL 2.0/LGPL 2.1
*
* The contents of this file are subject to the Mozilla Public License Version
* 1.1 (the "License"); you may not use this file except in compliance with
* the License. You may obtain a copy of the License at
* http://www.mozilla.org/MPL/
*
* Software distributed under the License is distributed on an "AS IS" basis,
* WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
* for the specific language governing rights and limitations under the
* License.
*
* The Original Code is Mozilla
*
* The Initial Developer of the Original Code is
* Netscape Communications Corp.
* Portions created by the Initial Developer are Copyright (C) 2001
* the Initial Developer. All Rights Reserved.
*
* Contributor(s): Krishna Mohan Khandrika (kkhandrika@netscape.com)
* Contributor(s): Rajiv Dayal (rdayal@netscape.com)
*
* Alternatively, the contents of this file may be used under the terms of
* either the GNU General Public License Version 2 or later (the "GPL"), or
* the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
* in which case the provisions of the GPL or the LGPL are applicable instead
* of those above. If you wish to allow use of your version of this file only
* under the terms of either the GPL or the LGPL, and not to allow others to
* use your version of this file under the terms of the MPL, indicate your
* decision by deleting the provisions above and replace them with the notice
* and other provisions required by the GPL or the LGPL. If you do not delete
* the provisions above, a recipient may use your version of this file under
* the terms of any one of the MPL, the GPL or the LGPL.
*
* ***** END LICENSE BLOCK ***** */
#include <mapidefs.h>
#include <mapi.h>
#include "msgMapi.h"
#include "msgMapiImp.h"
#include "msgMapiFactory.h"
#include "msgMapiMain.h"
#include "nsMsgCompFields.h"
#include "msgMapiHook.h"
#include "nsString.h"
#include "nsCOMPtr.h"
#include "nsISupports.h"
#include "nsMsgCompCID.h"
#include "nsMsgComposeStringBundle.h"
const CLSID CLSID_nsMapiImp = {0x29f458be, 0x8866, 0x11d5, {0xa3, 0xdd, 0x0, 0xb0, 0xd0, 0xf3, 0xba, 0xa7}};
nsMapiImp::nsMapiImp()
: m_cRef(1)
{
m_Lock = PR_NewLock();
}
nsMapiImp::~nsMapiImp()
{
if (m_Lock)
PR_DestroyLock(m_Lock);
}
STDMETHODIMP nsMapiImp::QueryInterface(const IID& aIid, void** aPpv)
{
if (aIid == IID_IUnknown)
{
*aPpv = static_cast<nsIMapi*>(this);
}
else if (aIid == IID_nsIMapi)
{
*aPpv = static_cast<nsIMapi*>(this);
}
else
{
*aPpv = nsnull;
return E_NOINTERFACE;
}
reinterpret_cast<IUnknown*>(*aPpv)->AddRef();
return S_OK;
}
STDMETHODIMP_(ULONG) nsMapiImp::AddRef()
{
return PR_AtomicIncrement(&m_cRef);
}
STDMETHODIMP_(ULONG) nsMapiImp::Release()
{
PRInt32 temp;
temp = PR_AtomicDecrement(&m_cRef);
if (m_cRef == 0)
{
delete this;
return 0;
}
return temp;
}
STDMETHODIMP nsMapiImp::IsValid()
{
return S_OK;
}
STDMETHODIMP nsMapiImp::IsValidSession(unsigned long aSession)
{
nsMAPIConfiguration *pConfig = nsMAPIConfiguration::GetMAPIConfiguration();
if (pConfig && pConfig->IsSessionValid(aSession))
return S_OK;
return E_FAIL;
}
STDMETHODIMP nsMapiImp::Initialize()
{
HRESULT hr = E_FAIL;
if (!m_Lock)
return E_FAIL;
PR_Lock(m_Lock);
// Initialize MAPI Configuration
nsMAPIConfiguration *pConfig = nsMAPIConfiguration::GetMAPIConfiguration();
if (pConfig != nsnull)
if (nsMapiHook::Initialize())
hr = S_OK;
PR_Unlock(m_Lock);
return hr;
}
STDMETHODIMP nsMapiImp::Login(unsigned long aUIArg, LOGIN_PW_TYPE aLogin, LOGIN_PW_TYPE aPassWord,
unsigned long aFlags, unsigned long *aSessionId)
{
HRESULT hr = E_FAIL;
PRBool bNewSession = PR_FALSE;
char *id_key = nsnull;
if (aFlags & MAPI_NEW_SESSION)
bNewSession = PR_TRUE;
// Check For Profile Name
if (aLogin != nsnull && aLogin[0] != '\0')
{
if (nsMapiHook::VerifyUserName(aLogin, &id_key) == PR_FALSE)
{
*aSessionId = MAPI_E_LOGIN_FAILURE;
return hr;
}
}
// finally register(create) the session.
PRUint32 nSession_Id;
PRInt16 nResult = 0;
nsMAPIConfiguration *pConfig = nsMAPIConfiguration::GetMAPIConfiguration();
if (pConfig != nsnull)
nResult = pConfig->RegisterSession(aUIArg, aLogin, aPassWord,
(aFlags & MAPI_FORCE_DOWNLOAD), bNewSession,
&nSession_Id, id_key);
switch (nResult)
{
case -1 :
{
*aSessionId = MAPI_E_TOO_MANY_SESSIONS;
return hr;
}
case 0 :
{
*aSessionId = MAPI_E_INSUFFICIENT_MEMORY;
return hr;
}
default :
{
*aSessionId = nSession_Id;
break;
}
}
return S_OK;
}
STDMETHODIMP nsMapiImp::SendMail( unsigned long aSession, lpnsMapiMessage aMessage,
short aRecipCount, lpnsMapiRecipDesc aRecips , short aFileCount, lpnsMapiFileDesc aFiles ,
unsigned long aFlags, unsigned long aReserved)
{
HRESULT hr = SUCCESS_SUCCESS ;
// Assign the pointers in the aMessage struct to the array of Recips and Files
// recieved here from MS COM. These are used in BlindSendMail and ShowCompWin fns
aMessage->lpRecips = aRecips ;
aMessage->lpFiles = aFiles ;
nsresult rv ;
/** create nsIMsgCompFields obj and populate it **/
nsCOMPtr<nsIMsgCompFields> pCompFields = do_CreateInstance(NS_MSGCOMPFIELDS_CONTRACTID, &rv) ;
if (NS_FAILED(rv) || (!pCompFields) ) return MAPI_E_INSUFFICIENT_MEMORY ;
if (aFlags & MAPI_UNICODE)
rv = nsMapiHook::PopulateCompFields(aMessage, pCompFields) ;
else
rv = nsMapiHook::PopulateCompFieldsWithConversion(aMessage, pCompFields) ;
if (NS_SUCCEEDED (rv))
{
// see flag to see if UI needs to be brought up
if (!(aFlags & MAPI_DIALOG))
{
rv = nsMapiHook::BlindSendMail(aSession, pCompFields);
}
else
{
rv = nsMapiHook::ShowComposerWindow(aSession, pCompFields);
}
}
// return success
if (NS_SUCCEEDED (rv)) return hr ;
// if failure return the related MAPI failure code
switch (rv)
{
case NS_MSG_NO_RECIPIENTS :
hr = MAPI_E_BAD_RECIPTYPE ;
break ;
case NS_ERROR_COULD_NOT_GET_USERS_MAIL_ADDRESS :
hr = MAPI_E_INVALID_RECIPS ;
break ;
case NS_ERROR_COULD_NOT_LOGIN_TO_SMTP_SERVER :
hr = MAPI_E_LOGIN_FAILURE ;
break ;
case NS_MSG_UNABLE_TO_OPEN_FILE :
case NS_MSG_UNABLE_TO_OPEN_TMP_FILE :
case NS_MSG_COULDNT_OPEN_FCC_FOLDER :
case NS_ERROR_FILE_INVALID_PATH :
hr = MAPI_E_ATTACHMENT_OPEN_FAILURE ;
break ;
case NS_ERROR_FILE_TARGET_DOES_NOT_EXIST :
hr = MAPI_E_ATTACHMENT_NOT_FOUND ;
break ;
case NS_MSG_CANCELLING :
hr = MAPI_E_USER_ABORT ;
break ;
case NS_MSG_ERROR_WRITING_FILE :
case NS_MSG_UNABLE_TO_SAVE_TEMPLATE :
case NS_MSG_UNABLE_TO_SAVE_DRAFT :
hr = MAPI_E_ATTACHMENT_WRITE_FAILURE ;
break ;
default :
hr = MAPI_E_FAILURE ;
break ;
}
return hr ;
}
STDMETHODIMP nsMapiImp::SendDocuments( unsigned long aSession, LPTSTR aDelimChar,
LPTSTR aFilePaths, LPTSTR aFileNames, ULONG aFlags)
{
HRESULT hr = SUCCESS_SUCCESS ;
nsresult rv = NS_OK ;
/** create nsIMsgCompFields obj and populate it **/
nsCOMPtr<nsIMsgCompFields> pCompFields = do_CreateInstance(NS_MSGCOMPFIELDS_CONTRACTID, &rv) ;
if (NS_FAILED(rv) || (!pCompFields) ) return MAPI_E_INSUFFICIENT_MEMORY ;
if (aFilePaths)
{
rv = nsMapiHook::PopulateCompFieldsForSendDocs(pCompFields, aFlags, aDelimChar, aFilePaths) ;
}
if (NS_SUCCEEDED (rv))
rv = nsMapiHook::ShowComposerWindow(aSession, pCompFields);
// return success
if (NS_SUCCEEDED (rv)) return hr ;
// if failure return the related MAPI failure code
switch (rv)
{
case NS_ERROR_COULD_NOT_LOGIN_TO_SMTP_SERVER :
hr = MAPI_E_LOGIN_FAILURE ;
break ;
case NS_MSG_UNABLE_TO_OPEN_FILE :
case NS_MSG_UNABLE_TO_OPEN_TMP_FILE :
case NS_MSG_COULDNT_OPEN_FCC_FOLDER :
case NS_ERROR_FILE_INVALID_PATH :
hr = MAPI_E_ATTACHMENT_OPEN_FAILURE ;
break ;
case NS_ERROR_FILE_TARGET_DOES_NOT_EXIST :
hr = MAPI_E_ATTACHMENT_NOT_FOUND ;
break ;
case NS_MSG_CANCELLING :
hr = MAPI_E_USER_ABORT ;
break ;
case NS_MSG_ERROR_WRITING_FILE :
case NS_MSG_UNABLE_TO_SAVE_TEMPLATE :
case NS_MSG_UNABLE_TO_SAVE_DRAFT :
hr = MAPI_E_ATTACHMENT_WRITE_FAILURE ;
break ;
default :
hr = MAPI_E_FAILURE ;
break ;
}
return hr ;
}
STDMETHODIMP nsMapiImp::Logoff (unsigned long aSession)
{
nsMAPIConfiguration *pConfig = nsMAPIConfiguration::GetMAPIConfiguration();
if (pConfig->UnRegisterSession((PRUint32)aSession))
return S_OK;
return E_FAIL;
}
STDMETHODIMP nsMapiImp::CleanUp()
{
nsMapiHook::CleanUp();
return S_OK;
}

View File

@@ -1,87 +0,0 @@
/* ***** BEGIN LICENSE BLOCK *****
* Version: MPL 1.1/GPL 2.0/LGPL 2.1
*
* The contents of this file are subject to the Mozilla Public License Version
* 1.1 (the "License"); you may not use this file except in compliance with
* the License. You may obtain a copy of the License at
* http://www.mozilla.org/MPL/
*
* Software distributed under the License is distributed on an "AS IS" basis,
* WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
* for the specific language governing rights and limitations under the
* License.
*
* The Original Code is Mozilla
*
* The Initial Developer of the Original Code is
* Netscape Communications Corp.
* Portions created by the Initial Developer are Copyright (C) 2001
* the Initial Developer. All Rights Reserved.
*
* Contributor(s): Krishna Mohan Khandrika (kkhandrika@netscape.com)
*
* Alternatively, the contents of this file may be used under the terms of
* either the GNU General Public License Version 2 or later (the "GPL"), or
* the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
* in which case the provisions of the GPL or the LGPL are applicable instead
* of those above. If you wish to allow use of your version of this file only
* under the terms of either the GPL or the LGPL, and not to allow others to
* use your version of this file under the terms of the MPL, indicate your
* decision by deleting the provisions above and replace them with the notice
* and other provisions required by the GPL or the LGPL. If you do not delete
* the provisions above, a recipient may use your version of this file under
* the terms of any one of the MPL, the GPL or the LGPL.
*
* ***** END LICENSE BLOCK ***** */
#ifndef MSG_MAPI_IMP_H
#define MSG_MAPI_IMP_H
#include <windows.h>
#include <mapi.h>
#include "msgMapi.h"
#include "nsXPIDLString.h"
#include "nspr.h"
class nsMapiImp : public nsIMapi
{
public :
// IUnknown
STDMETHODIMP QueryInterface(const IID& aIid, void** aPpv);
STDMETHODIMP_(ULONG) AddRef();
STDMETHODIMP_(ULONG) Release();
// Interface INsMapi
STDMETHODIMP Login(unsigned long aUIArg, LOGIN_PW_TYPE aLogin,
LOGIN_PW_TYPE aPassWord, unsigned long aFlags,
unsigned long *aSessionId);
STDMETHODIMP SendMail( unsigned long aSession, lpnsMapiMessage aMessage,
short aRecipCount, lpnsMapiRecipDesc aRecips ,
short aFileCount, lpnsMapiFileDesc aFiles ,
unsigned long aFlags, unsigned long aReserved) ;
STDMETHODIMP SendDocuments( unsigned long aSession, LPTSTR aDelimChar,
LPTSTR aFilePaths, LPTSTR aFileNames, ULONG aFlags);
STDMETHODIMP Initialize();
STDMETHODIMP IsValid();
STDMETHODIMP IsValidSession(unsigned long aSession);
STDMETHODIMP Logoff (unsigned long aSession);
STDMETHODIMP CleanUp();
nsMapiImp();
~nsMapiImp();
private :
PRLock *m_Lock;
PRInt32 m_cRef;
};
#endif // MSG_MAPI_IMP_H

View File

@@ -1,340 +0,0 @@
/* ***** BEGIN LICENSE BLOCK *****
* Version: MPL 1.1/GPL 2.0/LGPL 2.1
*
* The contents of this file are subject to the Mozilla Public License Version
* 1.1 (the "License"); you may not use this file except in compliance with
* the License. You may obtain a copy of the License at
* http://www.mozilla.org/MPL/
*
* Software distributed under the License is distributed on an "AS IS" basis,
* WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
* for the specific language governing rights and limitations under the
* License.
*
* The Original Code is Mozilla
*
* The Initial Developer of the Original Code is
* Netscape Communications Corp.
* Portions created by the Initial Developer are Copyright (C) 2001
* the Initial Developer. All Rights Reserved.
*
* Contributor(s): Krishna Mohan Khandrika (kkhandrika@netscape.com)
*
* Alternatively, the contents of this file may be used under the terms of
* either the GNU General Public License Version 2 or later (the "GPL"), or
* the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
* in which case the provisions of the GPL or the LGPL are applicable instead
* of those above. If you wish to allow use of your version of this file only
* under the terms of either the GPL or the LGPL, and not to allow others to
* use your version of this file under the terms of the MPL, indicate your
* decision by deleting the provisions above and replace them with the notice
* and other provisions required by the GPL or the LGPL. If you do not delete
* the provisions above, a recipient may use your version of this file under
* the terms of any one of the MPL, the GPL or the LGPL.
*
* ***** END LICENSE BLOCK ***** */
#include "msgMapiMain.h"
#include "nsIServiceManager.h"
#include "nsCOMPtr.h"
// move to xpcom bug 81956.
class nsPRUintKey : public nsHashKey {
protected:
PRUint32 mKey;
public:
nsPRUintKey(PRUint32 key) : mKey(key) {}
PRUint32 HashCode(void) const {
return mKey;
}
PRBool Equals(const nsHashKey *aKey) const {
return mKey == ((const nsPRUintKey *) aKey)->mKey;
}
nsHashKey *Clone() const {
return new nsPRUintKey(mKey);
}
PRUint32 GetValue() { return mKey; }
};
//
nsMAPIConfiguration *nsMAPIConfiguration::m_pSelfRef = nsnull;
PRUint32 nsMAPIConfiguration::session_generator = 0;
PRUint32 nsMAPIConfiguration::sessionCount = 0;
nsMAPIConfiguration *nsMAPIConfiguration::GetMAPIConfiguration()
{
if (m_pSelfRef == nsnull)
m_pSelfRef = new nsMAPIConfiguration();
return m_pSelfRef;
}
nsMAPIConfiguration::nsMAPIConfiguration()
: m_nMaxSessions(MAX_SESSIONS),
m_ProfileMap(nsnull),
m_SessionMap(nsnull)
{
m_Lock = PR_NewLock();
m_ProfileMap = new nsHashtable();
m_SessionMap = new nsHashtable();
NS_ASSERTION(m_SessionMap && m_ProfileMap, "hashtables not created");
}
static PRBool
FreeSessionMapEntries(nsHashKey *aKey, void *aData, void* aClosure)
{
nsMAPISession *pTemp = (nsMAPISession*) aData;
delete pTemp;
pTemp = nsnull;
return PR_TRUE;
}
static PRBool
FreeProfileMapEntries(nsHashKey *aKey, void *aData, void* aClosure)
{
return PR_TRUE;
}
nsMAPIConfiguration::~nsMAPIConfiguration()
{
if (m_Lock)
PR_DestroyLock(m_Lock);
if (m_SessionMap)
{
m_SessionMap->Reset(FreeSessionMapEntries);
delete m_SessionMap;
m_SessionMap = nsnull;
}
if (m_ProfileMap)
{
m_ProfileMap->Reset(FreeProfileMapEntries);
delete m_ProfileMap;
m_ProfileMap = nsnull;
}
}
void nsMAPIConfiguration::OpenConfiguration()
{
// No. of max. sessions is set to MAX_SESSIONS. In future
// if it is decided to have configuration (registry)
// parameter, this function can be used to set the
// max sessions;
return;
}
PRInt16 nsMAPIConfiguration::RegisterSession(PRUint32 aHwnd,
const PRUnichar *aUserName, const PRUnichar *aPassword,
PRBool aForceDownLoad, PRBool aNewSession,
PRUint32 *aSession, char *aIdKey)
{
PRInt16 nResult = 0;
PRUint32 n_SessionId = 0;
PR_Lock(m_Lock);
// Check whether max sessions is exceeded
if (sessionCount >= m_nMaxSessions)
{
PR_Unlock(m_Lock);
return -1;
}
if (aUserName != nsnull && aUserName[0] != '\0')
{
nsStringKey usernameKey(aUserName);
n_SessionId = (PRUint32) m_ProfileMap->Get(&usernameKey);
}
// try to share a session; if not create a session
if (n_SessionId > 0)
{
nsPRUintKey sessionKey(n_SessionId);
nsMAPISession *pTemp = (nsMAPISession *)m_SessionMap->Get(&sessionKey);
if (pTemp != nsnull)
{
pTemp->IncrementSession();
*aSession = n_SessionId;
nResult = 1;
}
}
else if (aNewSession || n_SessionId == 0) // checking for n_SessionId is a concession
{
// create a new session ; if new session is specified OR there is no session
nsMAPISession *pTemp = nsnull;
pTemp = new nsMAPISession(aHwnd, aUserName,
aPassword, aForceDownLoad, aIdKey);
if (pTemp != nsnull)
{
session_generator++;
// I don't think there will be (2 power 32) sessions alive
// in a cycle. This is an assumption
if (session_generator == 0)
session_generator++;
nsPRUintKey sessionKey(session_generator);
m_SessionMap->Put(&sessionKey, pTemp);
if (aUserName != nsnull && aUserName[0] != '\0')
{
nsStringKey usernameKey(aUserName);
m_ProfileMap->Put(&usernameKey, (void*)session_generator);
}
*aSession = session_generator;
sessionCount++;
nResult = 1;
}
}
PR_Unlock(m_Lock);
return nResult;
}
PRBool nsMAPIConfiguration::UnRegisterSession(PRUint32 aSessionID)
{
PRBool bResult = PR_FALSE;
PR_Lock(m_Lock);
if (aSessionID != 0)
{
nsPRUintKey sessionKey(aSessionID);
nsMAPISession *pTemp = (nsMAPISession *)m_SessionMap->Get(&sessionKey);
if (pTemp != nsnull)
{
if (pTemp->DecrementSession() == 0)
{
if (pTemp->m_pProfileName.get() != nsnull)
{
nsStringKey stringKey(pTemp->m_pProfileName.get());
m_ProfileMap->Remove(&stringKey);
}
m_SessionMap->Remove(&sessionKey);
sessionCount--;
bResult = PR_TRUE;
}
}
}
PR_Unlock(m_Lock);
return bResult;
}
PRBool nsMAPIConfiguration::IsSessionValid(PRUint32 aSessionID)
{
if (aSessionID == 0)
return PR_FALSE;
PRBool retValue = PR_FALSE;
nsPRUintKey sessionKey(aSessionID);
PR_Lock(m_Lock);
retValue = m_SessionMap->Exists(&sessionKey);
PR_Unlock(m_Lock);
return retValue;
}
PRUnichar *nsMAPIConfiguration::GetPassWord(PRUint32 aSessionID)
{
PRUnichar *pResult = nsnull;
PR_Lock(m_Lock);
if (aSessionID != 0)
{
nsPRUintKey sessionKey(aSessionID);
nsMAPISession *pTemp = (nsMAPISession *)m_SessionMap->Get(&sessionKey);
if (pTemp)
{
pResult = pTemp->GetPassWord();
}
}
PR_Unlock(m_Lock);
return pResult;
}
char *nsMAPIConfiguration::GetIdKey(PRUint32 aSessionID)
{
char *pResult = nsnull;
PR_Lock(m_Lock);
if (aSessionID != 0)
{
nsPRUintKey sessionKey(aSessionID);
nsMAPISession *pTemp = (nsMAPISession *)m_SessionMap->Get(&sessionKey);
if (pTemp)
{
pResult = pTemp->GetIdKey();
}
}
PR_Unlock(m_Lock);
return pResult;
}
nsMAPISession::nsMAPISession(PRUint32 aHwnd, const PRUnichar *aUserName,\
const PRUnichar *aPassword, \
PRBool aForceDownLoad, char *aKey)
: m_bIsForcedDownLoad(aForceDownLoad),
m_hAppHandle(aHwnd),
m_nShared(1),
m_pIdKey(aKey)
{
m_pProfileName.Assign(aUserName);
m_pPassword.Assign(aPassword);
}
nsMAPISession::~nsMAPISession()
{
if (m_pIdKey != nsnull)
{
delete [] m_pIdKey;
m_pIdKey = nsnull;
}
}
PRUint32 nsMAPISession::IncrementSession()
{
return ++m_nShared;
}
PRUint32 nsMAPISession::DecrementSession()
{
return --m_nShared;
}
PRUint32 nsMAPISession::GetSessionCount()
{
return m_nShared;
}
PRUnichar *nsMAPISession::GetPassWord()
{
return (PRUnichar *)m_pPassword.get();
}
char *nsMAPISession::GetIdKey()
{
return m_pIdKey;
}

View File

@@ -1,104 +0,0 @@
/* ***** BEGIN LICENSE BLOCK *****
* Version: MPL 1.1/GPL 2.0/LGPL 2.1
*
* The contents of this file are subject to the Mozilla Public License Version
* 1.1 (the "License"); you may not use this file except in compliance with
* the License. You may obtain a copy of the License at
* http://www.mozilla.org/MPL/
*
* Software distributed under the License is distributed on an "AS IS" basis,
* WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
* for the specific language governing rights and limitations under the
* License.
*
* The Original Code is Mozilla
*
* The Initial Developer of the Original Code is
* Netscape Communications Corp.
* Portions created by the Initial Developer are Copyright (C) 2001
* the Initial Developer. All Rights Reserved.
*
* Contributor(s): Krishna Mohan Khandrika (kkhandrika@netscape.com)
*
* Alternatively, the contents of this file may be used under the terms of
* either the GNU General Public License Version 2 or later (the "GPL"), or
* the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
* in which case the provisions of the GPL or the LGPL are applicable instead
* of those above. If you wish to allow use of your version of this file only
* under the terms of either the GPL or the LGPL, and not to allow others to
* use your version of this file under the terms of the MPL, indicate your
* decision by deleting the provisions above and replace them with the notice
* and other provisions required by the GPL or the LGPL. If you do not delete
* the provisions above, a recipient may use your version of this file under
* the terms of any one of the MPL, the GPL or the LGPL.
*
* ***** END LICENSE BLOCK ***** */
#ifndef MSG_MAPI_MAIN_H_
#define NSG_MAPI_MAIN_H_
#define MAX_NAME_LEN 256
#define MAX_PW_LEN 256
#define MAX_SESSIONS 50
#include "nsXPIDLString.h"
#include "nspr.h"
#include "nsString.h"
#include "nsHashtable.h"
class nsMAPIConfiguration
{
private :
static PRUint32 session_generator;
static PRUint32 sessionCount;
static nsMAPIConfiguration *m_pSelfRef;
PRLock *m_Lock;
PRUint32 m_nMaxSessions;
nsHashtable *m_ProfileMap;
nsHashtable *m_SessionMap;
nsMAPIConfiguration();
public :
static nsMAPIConfiguration *GetMAPIConfiguration();
void OpenConfiguration();
PRInt16 RegisterSession(PRUint32 aHwnd, const PRUnichar *aUserName, \
const PRUnichar *aPassword, PRBool aForceDownLoad, \
PRBool aNewSession, PRUint32 *aSession, char *aIdKey);
PRBool IsSessionValid(PRUint32 aSessionID);
PRBool UnRegisterSession(PRUint32 aSessionID);
PRUnichar *GetPassWord(PRUint32 aSessionID);
char *GetIdKey(PRUint32 aSessionID);
~nsMAPIConfiguration();
};
class nsMAPISession
{
friend class nsMAPIConfiguration;
private :
PRBool m_bIsForcedDownLoad;
PRBool m_bApp_or_Service;
PRUint32 m_hAppHandle;
PRUint32 m_nShared;
char *m_pIdKey;
nsString m_pProfileName;
nsString m_pPassword;
public :
nsMAPISession(PRUint32 aHwnd, const PRUnichar *aUserName, \
const PRUnichar *aPassword, \
PRBool aForceDownLoad, char *aKey);
PRUint32 IncrementSession();
PRUint32 DecrementSession();
PRUint32 GetSessionCount();
PRUnichar *nsMAPISession::GetPassWord();
char *nsMAPISession::GetIdKey();
~nsMAPISession();
};
#endif // MSG_MAPI_MAIN_H_

View File

@@ -1,146 +0,0 @@
/* ***** BEGIN LICENSE BLOCK *****
* Version: MPL 1.1/GPL 2.0/LGPL 2.1
*
* The contents of this file are subject to the Mozilla Public License Version
* 1.1 (the "License"); you may not use this file except in compliance with
* the License. You may obtain a copy of the License at
* http://www.mozilla.org/MPL/
*
* Software distributed under the License is distributed on an "AS IS" basis,
* WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
* for the specific language governing rights and limitations under the
* License.
*
* The Original Code is Mozilla
*
* The Initial Developer of the Original Code is
* Netscape Communications Corp.
* Portions created by the Initial Developer are Copyright (C) 2001
* the Initial Developer. All Rights Reserved.
*
* Contributor(s): Krishna Mohan Khandrika (kkhandrika@netscape.com)
*
* Alternatively, the contents of this file may be used under the terms of
* either the GNU General Public License Version 2 or later (the "GPL"), or
* the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
* in which case the provisions of the GPL or the LGPL are applicable instead
* of those above. If you wish to allow use of your version of this file only
* under the terms of either the GPL or the LGPL, and not to allow others to
* use your version of this file under the terms of the MPL, indicate your
* decision by deleting the provisions above and replace them with the notice
* and other provisions required by the GPL or the LGPL. If you do not delete
* the provisions above, a recipient may use your version of this file under
* the terms of any one of the MPL, the GPL or the LGPL.
*
* ***** END LICENSE BLOCK ***** */
#include "msgMapiSupport.h"
#include "nsISupports.h"
const CLSID CLSID_nsMapiImp = {0x29f458be, 0x8866, 0x11d5, \
{0xa3, 0xdd, 0x0, 0xb0, 0xd0, 0xf3, 0xba, 0xa7}};
PRBool WINAPI DllMain(HINSTANCE aInstance, DWORD aReason, LPVOID aReserved)
{
switch (aReason)
{
case DLL_PROCESS_ATTACH :
{
// Initialize MAPI Support
nsMapiSupport *pTemp = nsMapiSupport::GetNsMapiSupport();
break;
}
case DLL_PROCESS_DETACH :
{
nsMapiSupport *pTemp = nsMapiSupport::GetNsMapiSupport();
pTemp->UnInitMSCom();
delete pTemp;
pTemp = nsnull;
}
}
return PR_TRUE;
}
extern "C"
{
void __declspec(dllexport) Init()
{
nsMapiSupport *pTemp = nsMapiSupport::GetNsMapiSupport();
if (pTemp != nsnull)
pTemp->InitMSCom();
}
}
nsMapiSupport* nsMapiSupport::m_pSelfRef = nsnull;
nsMapiSupport *nsMapiSupport::GetNsMapiSupport()
{
if (m_pSelfRef == nsnull)
m_pSelfRef = new nsMapiSupport();
return m_pSelfRef;
}
nsMapiSupport::nsMapiSupport()
: m_dwRegister(0),
m_nsMapiFactory(nsnull)
{
}
nsMapiSupport::~nsMapiSupport()
{
}
PRBool nsMapiSupport::RegsiterComponents()
{
if (m_nsMapiFactory == nsnull) // No Registering if already done. Sanity Check!!
{
m_nsMapiFactory = new nsMapiFactory();
if (m_nsMapiFactory != nsnull)
{
HRESULT hr = ::CoRegisterClassObject(CLSID_nsMapiImp, \
m_nsMapiFactory, \
CLSCTX_LOCAL_SERVER, \
REGCLS_MULTIPLEUSE, \
&m_dwRegister);
if (FAILED(hr))
{
m_nsMapiFactory->Release() ;
m_nsMapiFactory = nsnull;
return PR_FALSE;
}
}
}
return PR_TRUE;
}
PRBool nsMapiSupport::UnRegisterComponents()
{
if (m_dwRegister != 0)
::CoRevokeClassObject(m_dwRegister);
if (m_nsMapiFactory != nsnull)
{
m_nsMapiFactory->Release();
m_nsMapiFactory = nsnull;
}
return PR_TRUE;
}
void nsMapiSupport::InitMSCom()
{
::CoInitialize(nsnull);
RegsiterComponents();
}
void nsMapiSupport::UnInitMSCom()
{
UnRegisterComponents();
::CoUninitialize();
}

View File

@@ -1,64 +0,0 @@
/* ***** BEGIN LICENSE BLOCK *****
* Version: MPL 1.1/GPL 2.0/LGPL 2.1
*
* The contents of this file are subject to the Mozilla Public License Version
* 1.1 (the "License"); you may not use this file except in compliance with
* the License. You may obtain a copy of the License at
* http://www.mozilla.org/MPL/
*
* Software distributed under the License is distributed on an "AS IS" basis,
* WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
* for the specific language governing rights and limitations under the
* License.
*
* The Original Code is Mozilla
*
* The Initial Developer of the Original Code is
# Netscape Communications Corp.
* Portions created by the Initial Developer are Copyright (C) 2001
* the Initial Developer. All Rights Reserved.
*
* Contributor(s): Krishna Mohan Khandrika (kkhandrika@netscape.com)
*
* Alternatively, the contents of this file may be used under the terms of
* either the GNU General Public License Version 2 or later (the "GPL"), or
* the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
* in which case the provisions of the GPL or the LGPL are applicable instead
* of those above. If you wish to allow use of your version of this file only
* under the terms of either the GPL or the LGPL, and not to allow others to
* use your version of this file under the terms of the MPL, indicate your
* decision by deleting the provisions above and replace them with the notice
* and other provisions required by the GPL or the LGPL. If you do not delete
* the provisions above, a recipient may use your version of this file under
* the terms of any one of the MPL, the GPL or the LGPL.
*
* ***** END LICENSE BLOCK ***** */
#ifndef MSG_MAPI_SUPPORT_H_
#define MSG_MAPI_SUPPORT_H_
#include "msgMapiFactory.h"
#include "prtypes.h"
class __declspec(dllexport) nsMapiSupport
{
private :
DWORD m_dwRegister;
static nsMapiSupport *m_pSelfRef;
nsMapiFactory *m_nsMapiFactory;
nsMapiSupport();
public :
static nsMapiSupport *GetNsMapiSupport();
~nsMapiSupport();
PRBool RegsiterComponents();
void UnInitMSCom();
void InitMSCom();
PRBool UnRegisterComponents();
};
#endif // MSG_MAPI_SUPPORT_H_

View File

@@ -1,252 +0,0 @@
/* ***** BEGIN LICENSE BLOCK *****
* Version: MPL 1.1/GPL 2.0/LGPL 2.1
*
* The contents of this file are subject to the Mozilla Public License Version
* 1.1 (the "License"); you may not use this file except in compliance with
* the License. You may obtain a copy of the License at
* http://www.mozilla.org/MPL/
*
* Software distributed under the License is distributed on an "AS IS" basis,
* WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
* for the specific language governing rights and limitations under the
* License.
*
* The Original Code is mozilla.org code.
*
* The Initial Developer of the Original Code is
* Netscape Communications Corporation.
* Portions created by the Initial Developer are Copyright (C) 2001
* the Initial Developer. All Rights Reserved.
*
* Contributor(s):
* Srilatha Moturi <srilatha@netscape.com>
*
* Alternatively, the contents of this file may be used under the terms of
* either the GNU General Public License Version 2 or later (the "GPL"), or
* the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
* in which case the provisions of the GPL or the LGPL are applicable instead
* of those above. If you wish to allow use of your version of this file only
* under the terms of either the GPL or the LGPL, and not to allow others to
* use your version of this file under the terms of the MPL, indicate your
* decision by deleting the provisions above and replace them with the notice
* and other provisions required by the GPL or the LGPL. If you do not delete
* the provisions above, a recipient may use your version of this file under
* the terms of any one of the MPL, the GPL or the LGPL.
*
* ***** END LICENSE BLOCK ***** */
#include "nsIServiceManager.h"
#include "nsMapiRegistry.h"
#include "nsIGenericFactory.h"
#include "nsXPIDLString.h"
#include "nsIPromptService.h"
#include "nsIStringBundle.h"
#include "nsIProxyObjectManager.h"
#include "nsProxiedService.h"
#include "nsMapiRegistryUtils.h"
#include "nsString.h"
static NS_DEFINE_CID(kStringBundleServiceCID, NS_STRINGBUNDLESERVICE_CID);
nsresult ShowMapiErrorDialog();
/** Implementation of the nsIMapiRegistry interface.
* Use standard implementation of nsISupports stuff.
*/
NS_IMPL_ISUPPORTS1(nsMapiRegistry, nsIMapiRegistry);
nsMapiRegistry::nsMapiRegistry() {
NS_INIT_ISUPPORTS();
m_ShowDialog = !verifyRestrictedAccess();
m_DefaultMailClient = IsDefaultMailClient();
}
nsMapiRegistry::~nsMapiRegistry() {
}
NS_IMETHODIMP
nsMapiRegistry::GetIsDefaultMailClient(PRBool * retval) {
// we need to get the value from registry everytime
// because the registry settings can be changed from
// other mail applications.
*retval = IsDefaultMailClient();
return NS_OK;
}
NS_IMETHODIMP
nsMapiRegistry::GetShowDialog(PRBool * retval) {
*retval = m_ShowDialog;
return NS_OK;
}
NS_IMETHODIMP
nsMapiRegistry::SetDefaultMailClient() {
nsresult rv = setDefaultMailClient();
if (NS_SUCCEEDED(rv))
m_DefaultMailClient = PR_TRUE;
else
rv = ShowMapiErrorDialog();
return NS_OK;
}
NS_IMETHODIMP
nsMapiRegistry::UnsetDefaultMailClient() {
nsresult rv = unsetDefaultMailClient();
if (NS_SUCCEEDED(rv))
m_DefaultMailClient = PR_FALSE;
else
ShowMapiErrorDialog();
return NS_OK;
}
/** This will bring up the dialog box only once per session and
* only if the current app is not default Mail Client.
* This also checks the registry if the registry key
* showMapiDialog is set
*/
NS_IMETHODIMP
nsMapiRegistry::ShowMailIntegrationDialog(nsIDOMWindow *aParentWindow) {
nsresult rv;
if (!m_ShowDialog || !getShowDialog()) return NS_OK;
nsCOMPtr<nsIPromptService> promptService(do_GetService(
"@mozilla.org/embedcomp/prompt-service;1", &rv));
if (NS_SUCCEEDED(rv) && promptService)
{
nsCOMPtr<nsIStringBundleService> bundleService(do_GetService(
kStringBundleServiceCID, &rv));
if (NS_FAILED(rv) || !bundleService) return NS_ERROR_FAILURE;
nsCOMPtr<nsIStringBundle> bundle;
rv = bundleService->CreateBundle(
"chrome://messenger/locale/mapi.properties",
getter_AddRefs(bundle));
if (NS_FAILED(rv)) return NS_ERROR_FAILURE;
nsCOMPtr<nsIStringBundle> brandBundle;
rv = bundleService->CreateBundle(
"chrome://global/locale/brand.properties",
getter_AddRefs(brandBundle));
if (NS_FAILED(rv)) return NS_ERROR_FAILURE;
nsXPIDLString brandName;
rv = brandBundle->GetStringFromName(
NS_LITERAL_STRING("brandShortName").get(),
getter_Copies(brandName));
if (NS_FAILED(rv)) return NS_ERROR_FAILURE;
nsXPIDLString dialogTitle;
const PRUnichar *brandStrings[] = { brandName.get() };
NS_NAMED_LITERAL_STRING(dialogTitlePropertyTag, "dialogTitle");
const PRUnichar *dTitlepropertyTag = dialogTitlePropertyTag.get();
rv = bundle->FormatStringFromName(dTitlepropertyTag,
brandStrings, 1,
getter_Copies(dialogTitle));
if (NS_FAILED(rv)) return NS_ERROR_FAILURE;
nsXPIDLString dialogText;
NS_NAMED_LITERAL_STRING(dialogTextPropertyTag, "dialogText");
const PRUnichar *dpropertyTag = dialogTextPropertyTag.get();
rv = bundle->FormatStringFromName(dpropertyTag,
brandStrings, 1,
getter_Copies(dialogText));
if (NS_FAILED(rv)) return NS_ERROR_FAILURE;
nsXPIDLString checkboxText;
rv = bundle->GetStringFromName(
NS_LITERAL_STRING("checkboxText").get(),
getter_Copies(checkboxText));
if (NS_FAILED(rv)) return NS_ERROR_FAILURE;
PRBool checkValue = PR_FALSE;
PRInt32 buttonPressed = 0;
rv = promptService->ConfirmEx(aParentWindow,
dialogTitle,
dialogText.get(),
(nsIPromptService::BUTTON_TITLE_YES *
nsIPromptService::BUTTON_POS_0) +
(nsIPromptService::BUTTON_TITLE_NO *
nsIPromptService::BUTTON_POS_1),
nsnull,
nsnull,
nsnull,
checkboxText,
&checkValue,
&buttonPressed);
if (NS_FAILED(rv)) return NS_ERROR_FAILURE;
rv = SetRegistryKey(HKEY_LOCAL_MACHINE, "Software\\Mozilla\\Desktop",
"showMapiDialog", (checkValue) ? "0" : "1");
if (NS_FAILED(rv)) return NS_ERROR_FAILURE;
m_ShowDialog = PR_FALSE;
if (!buttonPressed)
rv = SetDefaultMailClient();
}
return rv;
}
nsresult ShowMapiErrorDialog() {
nsresult rv;
nsCOMPtr<nsIPromptService> promptService(do_GetService(
"@mozilla.org/embedcomp/prompt-service;1", &rv));
if (NS_SUCCEEDED(rv) && promptService)
{
nsCOMPtr<nsIStringBundleService> bundleService(do_GetService(
kStringBundleServiceCID, &rv));
if (NS_FAILED(rv) || !bundleService) return NS_ERROR_FAILURE;
nsCOMPtr<nsIStringBundle> bundle;
rv = bundleService->CreateBundle(
"chrome://messenger/locale/mapi.properties",
getter_AddRefs(bundle));
if (NS_FAILED(rv)) return NS_ERROR_FAILURE;
nsCOMPtr<nsIStringBundle> brandBundle;
rv = bundleService->CreateBundle(
"chrome://global/locale/brand.properties",
getter_AddRefs(brandBundle));
if (NS_FAILED(rv)) return NS_ERROR_FAILURE;
nsXPIDLString brandName;
rv = brandBundle->GetStringFromName(
NS_LITERAL_STRING("brandShortName").get(),
getter_Copies(brandName));
if (NS_FAILED(rv)) return NS_ERROR_FAILURE;
nsXPIDLString dialogTitle;
const PRUnichar *brandStrings[] = { brandName.get() };
NS_NAMED_LITERAL_STRING(dialogTitlePropertyTag, "errorMessageTitle");
const PRUnichar *dTitlepropertyTag = dialogTitlePropertyTag.get();
rv = bundle->FormatStringFromName(dTitlepropertyTag,
brandStrings, 1,
getter_Copies(dialogTitle));
if (NS_FAILED(rv)) return NS_ERROR_FAILURE;
nsXPIDLString dialogText;
NS_NAMED_LITERAL_STRING(dialogTextPropertyTag, "errorMessage");
const PRUnichar *dpropertyTag = dialogTextPropertyTag.get();
rv = bundle->FormatStringFromName(dpropertyTag,
brandStrings, 1,
getter_Copies(dialogText));
if (NS_FAILED(rv)) return NS_ERROR_FAILURE;
rv = promptService->Alert(nsnull, dialogTitle,
dialogText);
}
return rv;
}
NS_GENERIC_FACTORY_CONSTRUCTOR(nsMapiRegistry);
// The list of components we register
static nsModuleComponentInfo components[] =
{
{
NS_IMAPIREGISTRY_CLASSNAME,
NS_IMAPIREGISTRY_CID,
NS_IMAPIWINHOOK_CONTRACTID,
nsMapiRegistryConstructor
}
};
NS_IMPL_NSGETMODULE(nsMapiRegistryModule, components);

View File

@@ -1,73 +0,0 @@
/* ***** BEGIN LICENSE BLOCK *****
* Version: MPL 1.1/GPL 2.0/LGPL 2.1
*
* The contents of this file are subject to the Mozilla Public License Version
* 1.1 (the "License"); you may not use this file except in compliance with
* the License. You may obtain a copy of the License at
* http://www.mozilla.org/MPL/
*
* Software distributed under the License is distributed on an "AS IS" basis,
* WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
* for the specific language governing rights and limitations under the
* License.
*
* The Original Code is mozilla.org code.
*
* The Initial Developer of the Original Code is
* Netscape Communications Corporation.
* Portions created by the Initial Developer are Copyright (C) 2001
* the Initial Developer. All Rights Reserved.
*
* Contributor(s):
* Srilatha Moturi <srilatha@netscape.com>
*
* Alternatively, the contents of this file may be used under the terms of
* either the GNU General Public License Version 2 or later (the "GPL"), or
* the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
* in which case the provisions of the GPL or the LGPL are applicable instead
* of those above. If you wish to allow use of your version of this file only
* under the terms of either the GPL or the LGPL, and not to allow others to
* use your version of this file under the terms of the MPL, indicate your
* decision by deleting the provisions above and replace them with the notice
* and other provisions required by the GPL or the LGPL. If you do not delete
* the provisions above, a recipient may use your version of this file under
* the terms of any one of the MPL, the GPL or the LGPL.
*
* ***** END LICENSE BLOCK ***** */
#ifndef nsmapiregistry_h____
#define nsmapiregistry_h____
#include "nsIMapiRegistry.h"
#ifndef MAX_BUF
#define MAX_BUF 4096
#endif
/* c5be14ba-4e0a-4eec-a1b8-04363761d63c */
#define NS_IMAPIREGISTRY_CID \
{ 0xc5be14ba, 0x4e0a, 0x4eec, {0xa1, 0xb8, 0x04, 0x36, 0x37, 0x61, 0xd6, 0x3c} }
#define NS_IMAPIREGISTRY_CONTRACTID "@mozilla.org/mapiregistry;1"
#define NS_IMAPIREGISTRY_CLASSNAME "Mozilla MAPI Registry"
class nsMapiRegistry : public nsIMapiRegistry {
public:
// ctor/dtor
nsMapiRegistry();
virtual ~nsMapiRegistry();
// Declare all interface methods we must implement.
NS_DECL_ISUPPORTS
NS_DECL_NSIMAPIREGISTRY
protected:
PRBool m_DefaultMailClient;
PRBool m_ShowDialog;
private:
// Special member to handle initialization.
PRBool mHaveBeenSet;
}; // nsMapiRegistry
#endif // nsmapiregistry_h____

View File

@@ -1,652 +0,0 @@
/* ***** BEGIN LICENSE BLOCK *****
* Version: MPL 1.1/GPL 2.0/LGPL 2.1
*
* The contents of this file are subject to the Mozilla Public License Version
* 1.1 (the "License"); you may not use this file except in compliance with
* the License. You may obtain a copy of the License at
* http://www.mozilla.org/MPL/
*
* Software distributed under the License is distributed on an "AS IS" basis,
* WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
* for the specific language governing rights and limitations under the
* License.
*
* The Original Code is mozilla.org code.
*
* The Initial Developer of the Original Code is
* Netscape Communications Corporation.
* Portions created by the Initial Developer are Copyright (C) 2001
* the Initial Developer. All Rights Reserved.
*
* Contributor(s):
* Srilatha Moturi <srilatha@netscape.com>
*
* Alternatively, the contents of this file may be used under the terms of
* either the GNU General Public License Version 2 or later (the "GPL"), or
* the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
* in which case the provisions of the GPL or the LGPL are applicable instead
* of those above. If you wish to allow use of your version of this file only
* under the terms of either the GPL or the LGPL, and not to allow others to
* use your version of this file under the terms of the MPL, indicate your
* decision by deleting the provisions above and replace them with the notice
* and other provisions required by the GPL or the LGPL. If you do not delete
* the provisions above, a recipient may use your version of this file under
* the terms of any one of the MPL, the GPL or the LGPL.
*
* ***** END LICENSE BLOCK ***** */
#undef UNICODE
#undef _UNICODE
#include "nsIServiceManager.h"
#include "nsMapiRegistryUtils.h"
#include "nsString.h"
#include "nsIStringBundle.h"
#include "nsXPIDLString.h"
#include "nsSpecialSystemDirectory.h"
#include "nsDirectoryService.h"
#include "nsDirectoryServiceDefs.h"
#include "nsAppDirectoryServiceDefs.h"
// returns TRUE if the Mapi32.dll is smart dll.
static PRBool isSmartDll();
// returns TRUE if the Mapi32.dll is a Mozilla dll.
static PRBool isMozDll();
static NS_DEFINE_CID(kStringBundleServiceCID, NS_STRINGBUNDLESERVICE_CID);
const CLSID CLSID_nsMapiImp = {0x29f458be, 0x8866, 0x11d5, {0xa3, 0xdd, 0x0, 0xb0, 0xd0, 0xf3, 0xba, 0xa7}};
// Returns the (fully-qualified) name of this executable.
static nsCString thisApplication() {
static nsCAutoString result;
if (result.IsEmpty()) {
char buffer[MAX_PATH] = {0};
DWORD len = ::GetModuleFileName(NULL, buffer, sizeof buffer);
len = ::GetShortPathName(buffer, buffer, sizeof buffer);
result = buffer;
result.ToUpperCase();
}
return result;
}
/** This returns the brand name for this application
*/
static nsCString brandName() {
static nsCAutoString brand;
nsresult rv;
if (brand.IsEmpty()) {
nsCOMPtr<nsIStringBundleService> bundleService(do_GetService(
kStringBundleServiceCID, &rv));
if (NS_SUCCEEDED(rv) && bundleService) {
nsCOMPtr<nsIStringBundle> brandBundle;
rv = bundleService->CreateBundle(
"chrome://global/locale/brand.properties",
getter_AddRefs(brandBundle));
if (NS_SUCCEEDED(rv)) {
nsXPIDLString brandName;
rv = brandBundle->GetStringFromName(
NS_LITERAL_STRING("brandShortName").get(),
getter_Copies(brandName));
if (NS_SUCCEEDED(rv)) {
brand.AssignWithConversion(brandName.get());
}
}
}
}
return brand;
}
// verifyRestrictedAccess - Returns PR_TRUE if this user only has restricted access
// to the registry keys we need to modify.
PRBool verifyRestrictedAccess() {
char subKey[] = "Software\\Mozilla - Test Key";
PRBool result = PR_FALSE;
DWORD dwDisp = 0;
HKEY key;
// Try to create/open a subkey under HKLM.
DWORD rc = ::RegCreateKeyEx(HKEY_LOCAL_MACHINE,
subKey,
0,
NULL,
REG_OPTION_NON_VOLATILE,
KEY_WRITE,
NULL,
&key,
&dwDisp);
if (rc == ERROR_SUCCESS) {
// Key was opened; first close it.
::RegCloseKey(key);
// Delete it if we just created it.
switch(dwDisp) {
case REG_CREATED_NEW_KEY:
::RegDeleteKey(HKEY_LOCAL_MACHINE, subKey);
break;
case REG_OPENED_EXISTING_KEY:
break;
}
} else {
// Can't create/open it; we don't have access.
result = PR_TRUE;
}
return result;
}
nsresult SetRegistryKey(HKEY baseKey, const char * keyName,
const char * valueName, char * value)
{
nsresult result = NS_ERROR_FAILURE;
HKEY key;
LONG rc = ::RegCreateKey(baseKey, keyName, &key);
if (rc == ERROR_SUCCESS) {
rc = ::RegSetValueEx(key, valueName, NULL, REG_SZ,
(LPBYTE)(const char*)value, strlen(value));
if (rc == ERROR_SUCCESS) {
result = NS_OK;
}
::RegCloseKey(key);
}
return result;
}
nsresult DeleteRegistryValue(HKEY baseKey, const char * keyName,
const char * valueName)
{
nsresult result = NS_ERROR_FAILURE;
HKEY key;
LONG rc = ::RegOpenKey(baseKey, keyName, &key);
if (rc == ERROR_SUCCESS) {
rc = ::RegDeleteValue(key, valueName);
if (rc == ERROR_SUCCESS)
result = NS_OK;
::RegCloseKey(key);
}
return result;
}
nsCString GetRegistryKey(HKEY baseKey, const char * keyName,
const char * valueName)
{
nsCAutoString value;
HKEY key;
LONG rc = ::RegOpenKey(baseKey, keyName, &key);
if (rc == ERROR_SUCCESS) {
char buffer[MAX_PATH] = {0};
DWORD len = sizeof buffer;
rc = ::RegQueryValueEx(key, valueName, NULL, NULL,
(LPBYTE)buffer, &len);
if (rc == ERROR_SUCCESS) {
if (len)
value = buffer;
}
::RegCloseKey(key);
}
return value;
}
#define EXE_EXTENSION ".exe"
/** Returns TRUE if the current application is default mail client.
*/
PRBool IsDefaultMailClient()
{
if (!isSmartDll() && !isMozDll())
return PR_FALSE;
nsCAutoString name(GetRegistryKey(HKEY_LOCAL_MACHINE,
"Software\\Clients\\Mail", ""));
if (!name.IsEmpty()) {
nsCString keyName("Software\\Clients\\Mail\\");
keyName += name.get();
keyName += "\\protocols\\mailto\\shell\\open\\command";
nsCAutoString result(GetRegistryKey(HKEY_LOCAL_MACHINE,
keyName.get(), ""));
if (!result.IsEmpty()) {
nsCAutoString strExtension;
strExtension.Assign(EXE_EXTENSION);
result.ToUpperCase();
strExtension.ToUpperCase();
PRInt32 index = result.RFind(strExtension.get());
if (index != kNotFound) {
result.Truncate(index + strExtension.Length());
}
return (result == thisApplication());
}
}
return PR_FALSE;
}
/** Saves the current setting of the default Mail Client in
* HKEY_LOCAL_MACHINE\\Software\\Mozilla\\Desktop
*/
nsresult saveDefaultMailClient()
{
nsresult rv;
nsCAutoString name(GetRegistryKey(HKEY_LOCAL_MACHINE,
"Software\\Clients\\Mail", ""));
if (!name.IsEmpty()) {
rv = SetRegistryKey(HKEY_LOCAL_MACHINE,
"Software\\Mozilla\\Desktop",
"HKEY_LOCAL_MACHINE\\Software\\Clients\\Mail",
(char *)name.get());
if (NS_SUCCEEDED(rv)) {
nsCString keyName("Software\\Clients\\Mail\\");
keyName += name.get();
keyName += "\\protocols\\mailto\\shell\\open\\command";
nsCAutoString appPath(GetRegistryKey(HKEY_LOCAL_MACHINE,
keyName.get(), ""));
if (!appPath.IsEmpty()) {
nsCString stringName("HKEY_LOCAL_MACHINE\\");
stringName += keyName.get();
rv = SetRegistryKey(HKEY_LOCAL_MACHINE,
"Software\\Mozilla\\Desktop",
stringName.get(), (char *)appPath.get());
}
}
}
else
rv = SetRegistryKey(HKEY_LOCAL_MACHINE,
"Software\\Mozilla\\Desktop",
"HKEY_LOCAL_MACHINE\\Software\\Clients\\Mail",
"");
return rv;
}
/** Saves the current user setting of the default Mail Client in
* HKEY_LOCAL_MACHINE\\Software\\Mozilla\\Desktop
*/
nsresult saveUserDefaultMailClient()
{
nsresult rv;
nsCAutoString name(GetRegistryKey(HKEY_CURRENT_USER,
"Software\\Clients\\Mail", ""));
if (!name.IsEmpty()) {
rv = SetRegistryKey(HKEY_LOCAL_MACHINE,
"Software\\Mozilla\\Desktop",
"HKEY_CURRENT_USER\\Software\\Clients\\Mail",
(char *)name.get());
}
else {
rv = SetRegistryKey(HKEY_LOCAL_MACHINE,
"Software\\Mozilla\\Desktop",
"HKEY_CURRENT_USER\\Software\\Clients\\Mail",
"");
}
return rv;
}
/**
* Check whether it is a smart dll or not. Smart dll is the one installed by
* IE5 or Outlook Express which forwards the MAPI calls to the dll based on the
* registry key setttings.
* Returns TRUE if is a smart dll.
*/
typedef HRESULT (FAR PASCAL GetOutlookVersionFunc)();
static PRBool isSmartDll()
{
char buffer[MAX_PATH] = {0};
if (GetSystemDirectory(buffer, sizeof(buffer)) == 0)
return PR_FALSE;
PL_strcatn(buffer, sizeof(buffer), "\\Mapi32.dll");
HINSTANCE hInst;
GetOutlookVersionFunc *doesExist = nsnull;
hInst = LoadLibrary(buffer);
if (hInst == nsnull)
return PR_FALSE;
doesExist = (GetOutlookVersionFunc *) GetProcAddress (hInst, "GetOutlookVersion");
FreeLibrary(hInst);
return (doesExist != nsnull);
}
typedef HRESULT (FAR PASCAL GetMapiDllVersion)();
/**
* Checks whether mapi32.dll is installed by this app.
* Returns TRUE if it is.
*/
static PRBool isMozDll()
{
char buffer[MAX_PATH] = {0};
if (GetSystemDirectory(buffer, sizeof(buffer)) == 0)
return PR_FALSE;
PL_strcatn(buffer, sizeof(buffer), "\\Mapi32.dll");
HINSTANCE hInst;
GetMapiDllVersion *doesExist = nsnull;
hInst = LoadLibrary(buffer);
if (hInst == nsnull)
return PR_FALSE;
doesExist = (GetMapiDllVersion *) GetProcAddress (hInst, "GetMapiDllVersion");
FreeLibrary(hInst);
return (doesExist != nsnull);
}
/** Renames Mapi32.dl in system directory to Mapi32_moz_bak.dll
* copies the mozMapi32.dll from bin directory to the system directory
*/
nsresult CopyMozMapiToWinSysDir()
{
nsresult rv;
char buffer[MAX_PATH] = {0};
if (GetSystemDirectory(buffer, sizeof(buffer)) == 0)
return NS_ERROR_FAILURE;
nsCAutoString filePath(buffer);
filePath.Append("\\Mapi32_moz_bak.dll");
nsCOMPtr<nsILocalFile> pCurrentMapiFile = do_CreateInstance (NS_LOCAL_FILE_CONTRACTID, &rv);
if (NS_FAILED(rv) || !pCurrentMapiFile) return rv;
pCurrentMapiFile->InitWithPath(filePath.get());
nsCOMPtr<nsIFile> pMozMapiFile;
nsCOMPtr<nsIProperties> directoryService =
do_GetService(NS_DIRECTORY_SERVICE_CONTRACTID, &rv);
if (!directoryService) return NS_ERROR_FAILURE;
rv = directoryService->Get(NS_OS_CURRENT_PROCESS_DIR,
NS_GET_IID(nsIFile),
getter_AddRefs(pMozMapiFile));
if (NS_FAILED(rv)) return rv;
pMozMapiFile->Append("mozMapi32.dll");
PRBool bExist;
rv = pMozMapiFile->Exists(&bExist);
if (NS_FAILED(rv) || !bExist) return rv;
rv = pCurrentMapiFile->Exists(&bExist);
if (NS_SUCCEEDED(rv) && bExist)
{
rv = pCurrentMapiFile->Remove(PR_FALSE);
}
if (NS_FAILED(rv)) return rv;
filePath.Assign(buffer);
filePath.Append("\\Mapi32.dll");
pCurrentMapiFile->InitWithPath(filePath.get());
rv = pCurrentMapiFile->Exists(&bExist);
if (NS_SUCCEEDED(rv) && bExist)
{
rv = pCurrentMapiFile->MoveTo(nsnull, "Mapi32_moz_bak.dll");
if (NS_FAILED(rv)) return rv;
nsCAutoString fullFilePath(buffer);
fullFilePath.Append("\\Mapi32_moz_bak.dll");
rv = SetRegistryKey(HKEY_LOCAL_MACHINE,
"Software\\Mozilla\\Desktop",
"Mapi_backup_dll",
(char *)fullFilePath.get());
if (NS_FAILED(rv)) {
RestoreBackedUpMapiDll();
return rv;
}
}
nsAutoString fileName;
fileName.AssignWithConversion("Mapi32.dll");
filePath.Assign(buffer);
pCurrentMapiFile->InitWithPath(filePath.get());
rv = pMozMapiFile->CopyToUnicode(pCurrentMapiFile, fileName.get());
if (NS_FAILED(rv))
RestoreBackedUpMapiDll();
return rv;
}
/** deletes the Mapi32.dll in system directory and renames Mapi32_moz_bak.dll
* to Mapi32.dll
*/
nsresult RestoreBackedUpMapiDll()
{
nsresult rv;
char buffer[MAX_PATH] = {0};
if (GetSystemDirectory(buffer, sizeof(buffer)) == 0)
return NS_ERROR_FAILURE;
nsCAutoString filePath(buffer);
nsCAutoString previousFileName(buffer);
filePath.Append("\\Mapi32.dll");
previousFileName.Append("\\Mapi32_moz_bak.dll");
nsCOMPtr <nsILocalFile> pCurrentMapiFile = do_CreateInstance(NS_LOCAL_FILE_CONTRACTID, &rv);
if (NS_FAILED(rv) || !pCurrentMapiFile) return NS_ERROR_FAILURE;
pCurrentMapiFile->InitWithPath(filePath);
nsCOMPtr<nsILocalFile> pPreviousMapiFile = do_CreateInstance (NS_LOCAL_FILE_CONTRACTID, &rv);
if (NS_FAILED(rv) || !pPreviousMapiFile) return NS_ERROR_FAILURE;
pPreviousMapiFile->InitWithPath(previousFileName);
PRBool bExist;
rv = pCurrentMapiFile->Exists(&bExist);
if (NS_SUCCEEDED(rv) && bExist) {
rv = pCurrentMapiFile->Remove(PR_FALSE);
if (NS_FAILED(rv)) return rv;
}
rv = pPreviousMapiFile->Exists(&bExist);
if (NS_SUCCEEDED(rv) && bExist)
rv = pPreviousMapiFile->MoveTo(nsnull, "Mapi32.dll");
if (NS_SUCCEEDED(rv))
DeleteRegistryValue(HKEY_LOCAL_MACHINE,
"Software\\Mozilla\\Desktop",
"Mapi_backup_dll");
return rv;
}
/** Sets Mozilla as default Mail Client
*/
nsresult setDefaultMailClient()
{
nsresult rv;
nsresult mailKeySet=NS_ERROR_FAILURE;
if (verifyRestrictedAccess()) return NS_ERROR_FAILURE;
if (!isSmartDll()) {
if (NS_FAILED(CopyMozMapiToWinSysDir())) return NS_ERROR_FAILURE;
}
rv = saveDefaultMailClient();
if (NS_FAILED(saveUserDefaultMailClient()) ||
NS_FAILED(rv)) return NS_ERROR_FAILURE;
nsCAutoString keyName("Software\\Clients\\Mail\\");
nsCAutoString appName(brandName());
if (!appName.IsEmpty()) {
keyName.Append(appName.get());
// hardcoding this for 0.9.4 branch
// need to change it before merging into the trunk
rv = SetRegistryKey(HKEY_LOCAL_MACHINE,
(char *)keyName.get(),
"", "Netscape 6.2 Mail");
}
else
rv = NS_ERROR_FAILURE;
if (NS_SUCCEEDED(rv)) {
nsCAutoString dllPath(thisApplication());
PRInt32 index = dllPath.RFind("\\");
if (index != kNotFound)
dllPath.Truncate(index + 1);
dllPath += "mozMapi32.dll";
rv = SetRegistryKey(HKEY_LOCAL_MACHINE,
(char *)keyName.get(), "DLLPath",
(char *)dllPath.get());
if (NS_SUCCEEDED(rv)) {
keyName.Append("\\protocols\\mailto");
rv = SetRegistryKey(HKEY_LOCAL_MACHINE,
(char *)keyName.get(),
"", "URL:MailTo Protocol");
if (NS_SUCCEEDED(rv)) {
nsCAutoString appPath(thisApplication());
appPath += " \"%1\"";
keyName.Append("\\shell\\open\\command");
rv = SetRegistryKey(HKEY_LOCAL_MACHINE,
(char *)keyName.get(),
"", (char *)appPath.get());
if (NS_SUCCEEDED(rv)) {
rv = SetRegistryKey(HKEY_LOCAL_MACHINE,
"Software\\Clients\\Mail",
"", (char *)appName.get());
}
if (NS_SUCCEEDED(rv)) {
nsCAutoString mailAppPath(thisApplication());
mailAppPath += " -mail";
nsCAutoString appKeyName ("Software\\Clients\\Mail\\");
appKeyName.Append(appName.get());
appKeyName.Append("\\shell\\open\\command");
rv = SetRegistryKey(HKEY_LOCAL_MACHINE,
(char *)appKeyName.get(),
"", (char *)mailAppPath.get());
}
if (NS_SUCCEEDED(rv)) {
nsCAutoString iconPath(thisApplication());
iconPath += ",0";
nsCAutoString iconKeyName ("Software\\Clients\\Mail\\");
iconKeyName.Append(appName.get());
iconKeyName.Append("\\DefaultIcon");
mailKeySet = SetRegistryKey(HKEY_LOCAL_MACHINE,
(char *)iconKeyName.get(),
"", (char *)iconPath.get());
}
}
}
}
if (NS_SUCCEEDED(mailKeySet)) {
nsresult desktopKeySet = SetRegistryKey(HKEY_CURRENT_USER,
"Software\\Clients\\Mail",
"", (char *)appName.get());
if (NS_SUCCEEDED(desktopKeySet)) {
desktopKeySet = SetRegistryKey(HKEY_LOCAL_MACHINE,
"Software\\Mozilla\\Desktop",
"defaultMailHasBeenSet", "1");
}
::SendMessage(HWND_BROADCAST, WM_SETTINGCHANGE, 0,
(LPARAM)"Software\\Clients\\Mail");
RegisterServer(CLSID_nsMapiImp, "Mozilla MAPI", "mozMapi", "mozMapi.1");
return desktopKeySet;
}
return mailKeySet;
}
/** Removes Mozilla as the default Mail client and restores the previous setting
*/
nsresult unsetDefaultMailClient() {
nsresult result = NS_OK;
nsresult mailKeySet = NS_ERROR_FAILURE;
if (verifyRestrictedAccess()) return NS_ERROR_FAILURE;
if (!isSmartDll()) {
if (NS_FAILED(RestoreBackedUpMapiDll())) return NS_ERROR_FAILURE;
}
nsCAutoString name(GetRegistryKey(HKEY_LOCAL_MACHINE,
"Software\\Mozilla\\Desktop",
"HKEY_LOCAL_MACHINE\\Software\\Clients\\Mail"));
nsCAutoString appName(brandName());
if (!name.IsEmpty() && !appName.IsEmpty() && name.Equals(appName)) {
nsCAutoString keyName("HKEY_LOCAL_MACHINE\\Software\\Clients\\Mail\\");
keyName.Append(appName.get());
keyName.Append("\\protocols\\mailto\\shell\\open\\command");
nsCAutoString appPath(GetRegistryKey(HKEY_LOCAL_MACHINE,
"Software\\Mozilla\\Desktop",
(char *)keyName.get()));
if (!appPath.IsEmpty()) {
keyName.Assign("Software\\Clients\\Mail\\");
keyName.Append(appName.get());
keyName.Append("\\protocols\\mailto\\shell\\open\\command");
result = SetRegistryKey(HKEY_LOCAL_MACHINE,
(char *) keyName.get(),
"", (char *)appPath.get());
if (NS_SUCCEEDED(result)) {
PRInt32 index = appPath.RFind("\\");
if (index != kNotFound)
appPath.Truncate(index + 1);
appPath += "mozMapi32.dll";
keyName.Assign("Software\\Clients\\Mail\\");
keyName.Append(appName.get());
result = SetRegistryKey(HKEY_LOCAL_MACHINE,
(char *)keyName.get(),
"DLLPath", (char *) appPath.get());
}
}
}
if (!name.IsEmpty()) {
if (NS_SUCCEEDED(result)) {
mailKeySet = SetRegistryKey(HKEY_LOCAL_MACHINE,
"Software\\Clients\\Mail",
"", (char *)name.get());
}
}
else
mailKeySet = SetRegistryKey(HKEY_LOCAL_MACHINE,
"Software\\Clients\\Mail",
"", "");
if (NS_SUCCEEDED(mailKeySet)) {
nsCAutoString userAppName(GetRegistryKey(HKEY_LOCAL_MACHINE,
"Software\\Mozilla\\Desktop",
"HKEY_CURRENT_USER\\Software\\Clients\\Mail"));
nsresult desktopKeySet = NS_OK;
if (!userAppName.IsEmpty()) {
desktopKeySet = SetRegistryKey(HKEY_CURRENT_USER,
"Software\\Clients\\Mail",
"", (char *)userAppName.get());
}
else {
DeleteRegistryValue(HKEY_CURRENT_USER, "Software\\Clients\\Mail", "");
}
if (NS_SUCCEEDED(desktopKeySet)) {
desktopKeySet = SetRegistryKey(HKEY_LOCAL_MACHINE,
"Software\\Mozilla\\Desktop",
"defaultMailHasBeenSet", "0");
}
::SendMessage(HWND_BROADCAST, WM_SETTINGCHANGE, 0,
(LPARAM)"Software\\Clients\\Mail");
UnregisterServer(CLSID_nsMapiImp, "mozMapi", "mozMapi.1");
return desktopKeySet;
}
return mailKeySet;
}
/** Returns FALSE if showMapiDialog is set to 0.
* Returns TRUE otherwise
* Also returns TRUE if the Mozilla has been set as the default mail client
* and some other application has changed that setting.
* This function gets called only if the current app is not the default mail
* client
*/
PRBool getShowDialog() {
PRBool rv = PR_FALSE;
nsCString showDialog(GetRegistryKey(HKEY_LOCAL_MACHINE,
"Software\\Mozilla\\Desktop",
"showMapiDialog"));
// if the user has not selected the checkbox, show dialog
if (showDialog.IsEmpty() || showDialog.Equals("1"))
rv = PR_TRUE;
if (!rv) {
// even if the user has selected the checkbox
// show it if some other application has changed the
// default setting.
nsCAutoString setMailDefault(GetRegistryKey(HKEY_LOCAL_MACHINE,
"Software\\Mozilla\\Desktop",
"defaultMailHasBeenSet"));
if (setMailDefault.Equals("1")) {
// need to reset the defaultMailHasBeenSet to "0"
// so that after the dialog is displayed once,
// we do not keep displaying this dialog after the user has
// selected the checkbox
rv = SetRegistryKey(HKEY_LOCAL_MACHINE,
"Software\\Mozilla\\Desktop",
"defaultMailHasBeenSet", "0");
rv = PR_TRUE;
}
}
return rv;
}

View File

@@ -1,90 +0,0 @@
/* ***** BEGIN LICENSE BLOCK *****
* Version: MPL 1.1/GPL 2.0/LGPL 2.1
*
* The contents of this file are subject to the Mozilla Public License Version
* 1.1 (the "License"); you may not use this file except in compliance with
* the License. You may obtain a copy of the License at
* http://www.mozilla.org/MPL/
*
* Software distributed under the License is distributed on an "AS IS" basis,
* WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
* for the specific language governing rights and limitations under the
* License.
*
* The Original Code is mozilla.org code.
*
* The Initial Developer of the Original Code is
* Netscape Communications Corporation.
* Portions created by the Initial Developer are Copyright (C) 2001
* the Initial Developer. All Rights Reserved.
*
* Contributor(s):
* Srilatha Moturi <srilatha@netscape.com>
*
* Alternatively, the contents of this file may be used under the terms of
* either the GNU General Public License Version 2 or later (the "GPL"), or
* the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
* in which case the provisions of the GPL or the LGPL are applicable instead
* of those above. If you wish to allow use of your version of this file only
* under the terms of either the GPL or the LGPL, and not to allow others to
* use your version of this file under the terms of the MPL, indicate your
* decision by deleting the provisions above and replace them with the notice
* and other provisions required by the GPL or the LGPL. If you do not delete
* the provisions above, a recipient may use your version of this file under
* the terms of any one of the MPL, the GPL or the LGPL.
*
* ***** END LICENSE BLOCK ***** */
#ifndef nsmapiregistryutils_h____
#define nsmapiregistryutils_h____
#include <windows.h>
#include <string.h>
#include <winreg.h>
#include "Registry.h"
#include "nsString.h"
//Sets the registry key for basekey/keyname valuename.
nsresult SetRegistryKey(HKEY baseKey, const char * keyName,
const char * valueName, char * value);
// Deletes the registry key for base/keyname/valuename
nsresult DeleteRegistryValue(HKEY baseKey, const char * keyName,
const char * valueName);
// Gets the current regiistry setting for the key.
nsCString GetRegistryKey(HKEY baseKey, const char * keyName,
const char * valueName);
// Returns PR_TRUE if this user only has restricted access
// to the registry keys we need to modify.
PRBool verifyRestrictedAccess();
// Returns true if mozilla is the default mail client
// by checking the registry.
PRBool IsDefaultMailClient();
// Save the current setting for the default mail client.
nsresult saveDefaultMailClient();
// Saves the current user setting for the default mail client.
nsresult saveUserDefaultMailClient();
// Renames Mapi32.dl in system directory to Mapi32_moz_bak.dll
// copies the mozMapi32.dll from bin directory to the system directory
nsresult CopyMozMapiToWinSysDir();
// deletes the Mapi32.dll in system directory and renames Mapi32_moz_bak.dll
// to Mapi32.dll
nsresult RestoreBackedUpMapiDll();
// Sets mozilla as the default mail client
nsresult setDefaultMailClient();
// unsets mozilla and resets the default mail client setting to previous one
nsresult unsetDefaultMailClient();
// returns true if we need to show the mail integration dialog.
PRBool getShowDialog();
#endif

View File

@@ -34,67 +34,77 @@
*
* ***** END LICENSE BLOCK ***** */
#include "msgMapiSupport.h"
#include "nsComPtr.h"
#include "nsMapiSupport.h"
#include "nsISupports.h"
#include "nsMapiRegistry.h"
#include "nsIGenericFactory.h"
#include "nsIObserverService.h"
#include "nsIAppStartupNotifier.h"
#include "nsIServiceManager.h"
#include "nsIComponentManager.h"
#include "nsICategoryManager.h"
const CLSID CLSID_nsMapiImp = {0x29f458be, 0x8866, 0x11d5, \
{0xa3, 0xdd, 0x0, 0xb0, 0xd0, 0xf3, 0xba, 0xa7}};
PRBool WINAPI DllMain(HINSTANCE aInstance, DWORD aReason, LPVOID aReserved)
/** Implementation of the nsIMapiSupport interface.
* Use standard implementation of nsISupports stuff.
*/
NS_IMPL_THREADSAFE_ISUPPORTS2(nsMapiSupport, nsIMapiSupport, nsIObserver);
static NS_METHOD nsMapiRegistrationProc(nsIComponentManager *aCompMgr,
nsIFile *aPath, const char *registryLocation, const char *componentType,
const nsModuleComponentInfo *info)
{
switch (aReason)
{
case DLL_PROCESS_ATTACH :
{
// Initialize MAPI Support
nsresult rv;
nsMapiSupport *pTemp = nsMapiSupport::GetNsMapiSupport();
break;
}
case DLL_PROCESS_DETACH :
{
nsMapiSupport *pTemp = nsMapiSupport::GetNsMapiSupport();
pTemp->UnInitMSCom();
delete pTemp;
pTemp = nsnull;
}
}
nsCOMPtr<nsICategoryManager> categoryManager(do_GetService(NS_CATEGORYMANAGER_CONTRACTID, &rv));
if (NS_SUCCEEDED(rv))
rv = categoryManager->AddCategoryEntry(APPSTARTUP_CATEGORY, "Mapi Support",
"service," NS_IMAPISUPPORT_CONTRACTID, PR_TRUE, PR_TRUE, nsnull);
return PR_TRUE;
return rv;
}
extern "C"
NS_IMETHODIMP
nsMapiSupport::Observe(nsISupports *aSubject, const char *aTopic, const PRUnichar *aData)
{
void __declspec(dllexport) Init()
{
nsMapiSupport *pTemp = nsMapiSupport::GetNsMapiSupport();
if (pTemp != nsnull)
pTemp->InitMSCom();
}
}
if (!nsCRT::strcmp(aTopic, "profile-after-change"))
return InitializeMAPISupport();
nsMapiSupport* nsMapiSupport::m_pSelfRef = nsnull;
if (!nsCRT::strcmp(aTopic, NS_XPCOM_SHUTDOWN_OBSERVER_ID))
return ShutdownMAPISupport();
nsMapiSupport *nsMapiSupport::GetNsMapiSupport()
{
if (m_pSelfRef == nsnull)
m_pSelfRef = new nsMapiSupport();
nsresult rv;
return m_pSelfRef;
nsCOMPtr<nsIObserverService> observerService(do_GetService("@mozilla.org/observer-service;1", &rv));
if (NS_FAILED(rv)) return rv;
rv = observerService->AddObserver(this,"profile-after-change", PR_FALSE);
if (NS_FAILED(rv)) return rv;
rv = observerService->AddObserver(this, NS_XPCOM_SHUTDOWN_OBSERVER_ID, PR_FALSE);
return rv;
}
nsMapiSupport::nsMapiSupport()
: m_dwRegister(0),
m_nsMapiFactory(nsnull)
{
NS_INIT_ISUPPORTS();
}
nsMapiSupport::~nsMapiSupport()
{
}
PRBool nsMapiSupport::RegsiterComponents()
NS_IMETHODIMP
nsMapiSupport::InitializeMAPISupport()
{
::CoInitialize(nsnull);
if (m_nsMapiFactory == nsnull) // No Registering if already done. Sanity Check!!
{
m_nsMapiFactory = new nsMapiFactory();
@@ -111,15 +121,16 @@ PRBool nsMapiSupport::RegsiterComponents()
{
m_nsMapiFactory->Release() ;
m_nsMapiFactory = nsnull;
return PR_FALSE;
return NS_ERROR_FAILURE;
}
}
}
return PR_TRUE;
return NS_OK;
}
PRBool nsMapiSupport::UnRegisterComponents()
NS_IMETHODIMP
nsMapiSupport::ShutdownMAPISupport()
{
if (m_dwRegister != 0)
::CoRevokeClassObject(m_dwRegister);
@@ -130,17 +141,34 @@ PRBool nsMapiSupport::UnRegisterComponents()
m_nsMapiFactory = nsnull;
}
return PR_TRUE;
}
void nsMapiSupport::InitMSCom()
{
::CoInitialize(nsnull);
RegsiterComponents();
}
void nsMapiSupport::UnInitMSCom()
{
UnRegisterComponents();
::CoUninitialize();
return NS_OK;
}
NS_GENERIC_FACTORY_CONSTRUCTOR(nsMapiRegistry);
NS_GENERIC_FACTORY_CONSTRUCTOR(nsMapiSupport);
// The list of components we register
static nsModuleComponentInfo components[] =
{
{
NS_IMAPIREGISTRY_CLASSNAME,
NS_IMAPIREGISTRY_CID,
NS_IMAPIREGISTRY_CONTRACTID,
nsMapiRegistryConstructor
},
{
NS_IMAPISUPPORT_CLASSNAME,
NS_IMAPISUPPORT_CID,
NS_IMAPISUPPORT_CONTRACTID,
nsMapiSupportConstructor,
nsMapiRegistrationProc,
nsnull
}
};
NS_IMPL_NSGETMODULE(msgMapiModule, components);

View File

@@ -34,31 +34,34 @@
*
* ***** END LICENSE BLOCK ***** */
#ifndef MSG_MAPI_SUPPORT_H_
#define MSG_MAPI_SUPPORT_H_
#ifndef NS_MAPI_SUPPORT_H_
#define NS_MAPI_SUPPORT_H_
#include <nsIObserver.h>
#include <nsIMapiSupport.h>
#include "msgMapiFactory.h"
#include "prtypes.h"
class __declspec(dllexport) nsMapiSupport
#define NS_IMAPISUPPORT_CID \
{0x8967fed2, 0xc8bb, 0x11d5, \
{ 0xa3, 0xe9, 0x00, 0xb0, 0xd0, 0xf3, 0xba, 0xa7 }}
class nsMapiSupport : public nsIMapiSupport, public nsIObserver
{
public :
nsMapiSupport();
~nsMapiSupport();
// Declare all interface methods we must implement.
NS_DECL_ISUPPORTS
NS_DECL_NSIOBSERVER
NS_DECL_NSIMAPISUPPORT
private :
DWORD m_dwRegister;
static nsMapiSupport *m_pSelfRef;
nsMapiFactory *m_nsMapiFactory;
nsMapiSupport();
public :
static nsMapiSupport *GetNsMapiSupport();
~nsMapiSupport();
PRBool RegsiterComponents();
void UnInitMSCom();
void InitMSCom();
PRBool UnRegisterComponents();
};
#endif // MSG_MAPI_SUPPORT_H_
#endif // NS_MAPI_SUPPORT_H_

View File

@@ -0,0 +1,64 @@
# The contents of this file are subject to the Netscape Public
# License Version 1.1 (the "License"); you may not use this file
# except in compliance with the License. You may obtain a copy of
# the License at http://www.mozilla.org/NPL/
#
# Software distributed under the License is distributed on an "AS
# IS" basis, WITHOUT WARRANTY OF ANY KIND, either express or
# implied. See the License for the specific language governing
# rights and limitations under the License.
#
# The Original Code is mozilla.org code.
#
# The Initial Developer of the Original Code is Netscape
# Communications Corporation. Portions created by Netscape are
# Copyright (C) 1998 Netscape Communications Corporation. All
# Rights Reserved.
#
# Contributor(s):
#
DEPTH=..\..\..
MODULE=mapiguts
################################################################################
## exports
#EXPORTS =
################################################################################
## library
LIBNAME = .\$(OBJDIR)\mapiguts
!ifdef MOZ_STATIC_COMPONENT_LIBS
LIB = $(LIBNAME).lib
!else
DLL = $(LIBNAME).dll
!endif
DEFINES= -NS_DEBUG
OBJS= \
.\$(OBJDIR)\mapihook.obj \
.\$(OBJDIR)\mapimail.obj \
$(NULL)
LLIBS= \
$(LLIBS) \
$(LIBNSPR) \
$(DIST)\lib\xppref32.lib \
$(DIST)\lib\xpcom.lib \
$(DIST)\lib\mapiutils_s.lib \
$(NULL)
include <$(DEPTH)\config\rules.mak>
!ifdef MOZ_STATIC_COMPONENT_LIBS
install:: $(LIb)
$(MAKE_INSTALL) $(LIBNAME).$(LIB_SUFFIX) $(DIST)\bin\components
!else
install:: $(DLL)
$(MAKE_INSTALL) $(LIBNAME).$(DLL_SUFFIX) $(DIST)\bin\components
!endif

File diff suppressed because it is too large Load Diff

View File

@@ -1,10 +1,11 @@
/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
/* ***** BEGIN LICENSE BLOCK *****
* Version: MPL 1.1/GPL 2.0/LGPL 2.1
* Version: NPL 1.1/GPL 2.0/LGPL 2.1
*
* The contents of this file are subject to the Mozilla Public License Version
* 1.1 (the "License"); you may not use this file except in compliance with
* the License. You may obtain a copy of the License at
* http://www.mozilla.org/MPL/
* The contents of this file are subject to the Netscape Public License
* Version 1.1 (the "License"); you may not use this file except in
* compliance with the License. You may obtain a copy of the License at
* http://www.mozilla.org/NPL/
*
* Software distributed under the License is distributed on an "AS IS" basis,
* WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
@@ -13,45 +14,35 @@
*
* The Original Code is mozilla.org code.
*
* The Initial Developer of the Original Code is
* The Initial Developer of the Original Code is
* Netscape Communications Corporation.
* Portions created by the Initial Developer are Copyright (C) 2001
* Portions created by the Initial Developer are Copyright (C) 1998
* the Initial Developer. All Rights Reserved.
*
* Contributor(s):
* Krishna Mohan Khandrika <kkhandrika@netscape.com>
*
* Alternatively, the contents of this file may be used under the terms of
* either the GNU General Public License Version 2 or later (the "GPL"), or
* either the GNU General Public License Version 2 or later (the "GPL"), or
* the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
* in which case the provisions of the GPL or the LGPL are applicable instead
* of those above. If you wish to allow use of your version of this file only
* under the terms of either the GPL or the LGPL, and not to allow others to
* use your version of this file under the terms of the MPL, indicate your
* use your version of this file under the terms of the NPL, indicate your
* decision by deleting the provisions above and replace them with the notice
* and other provisions required by the GPL or the LGPL. If you do not delete
* the provisions above, a recipient may use your version of this file under
* the terms of any one of the MPL, the GPL or the LGPL.
* the terms of any one of the NPL, the GPL or the LGPL.
*
* ***** END LICENSE BLOCK ***** */
#ifndef _MAPI_HOOK_H_
#define _MAPI_HOOK_H_
#ifndef _REGISTRY_H_
#define _REGISTRY_H_
#include <structs.h> // for MWContext
#include <objbase.h>
#include <assert.h>
//
// This is the entry point to the MAPI session manager that lives
// inside of Communicator.
//
LONG ProcessNetscapeMAPIHook(WPARAM wParam, LPARAM lParam);
// This function will register a component in the Registry.
HRESULT RegisterServer(const CLSID& clsid,
const char* szFriendlyName,
const char* szVerIndProgID,
const char* szProgID) ;
// This function will unregister a component.
HRESULT UnregisterServer(const CLSID& clsid,
const char* szVerIndProgID,
const char* szProgID) ;
#endif
#endif // _MAPI_HOOK_H_

View File

@@ -0,0 +1,853 @@
/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
/* ***** BEGIN LICENSE BLOCK *****
* Version: NPL 1.1/GPL 2.0/LGPL 2.1
*
* The contents of this file are subject to the Netscape Public License
* Version 1.1 (the "License"); you may not use this file except in
* compliance with the License. You may obtain a copy of the License at
* http://www.mozilla.org/NPL/
*
* Software distributed under the License is distributed on an "AS IS" basis,
* WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
* for the specific language governing rights and limitations under the
* License.
*
* The Original Code is mozilla.org code.
*
* The Initial Developer of the Original Code is
* Netscape Communications Corporation.
* Portions created by the Initial Developer are Copyright (C) 1998
* the Initial Developer. All Rights Reserved.
*
* Contributor(s):
*
* Alternatively, the contents of this file may be used under the terms of
* either the GNU General Public License Version 2 or later (the "GPL"), or
* the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
* in which case the provisions of the GPL or the LGPL are applicable instead
* of those above. If you wish to allow use of your version of this file only
* under the terms of either the GPL or the LGPL, and not to allow others to
* use your version of this file under the terms of the NPL, indicate your
* decision by deleting the provisions above and replace them with the notice
* and other provisions required by the GPL or the LGPL. If you do not delete
* the provisions above, a recipient may use your version of this file under
* the terms of any one of the NPL, the GPL or the LGPL.
*
* ***** END LICENSE BLOCK ***** */
//
// More MAPI Hooks for Communicator
// Written by: Rich Pizzarro (rhp@netscape.com)
// November 1997
//
#include "windows.h"
#include "template.h"
#include "msgcom.h"
#include "wfemsg.h"
#include "compstd.h"
#include "compbar.h"
#include "compmisc.h"
#include "compfrm.h"
#include "prefapi.h"
#include "intl_csi.h"
#include "dlghtmrp.h"
#include "dlghtmmq.h"
// rhp - was breaking the optimized build!
//#include "edt.h"
//#include "edview.h"
//#include "postal.h"
//#include "apiaddr.h"
//#include "mailmisc.h"
extern "C" {
#include "xpgetstr.h"
extern int MK_MSG_MSG_COMPOSITION;
};
#include "mapimail.h"
#include "nscpmapi.h"
#include "mailpriv.h"
#include "nsstrseq.h"
MWContext
*GetUsableContext(void)
{
CGenericFrame *pFrame = (CGenericFrame * )FEU_GetLastActiveFrame();
ASSERT(pFrame != NULL);
if (pFrame == NULL)
{
return(NULL);
}
// Now return the context...
return((MWContext *) pFrame->GetMainContext());
}
//
// This function will create a composition window and either do
// a blind send or pop up the compose window for the user to
// complete the operation
//
// Return: appropriate MAPI return code...
//
//
extern "C" LONG
DoFullMAPIMailOperation(MAPISendMailType *sendMailPtr,
const char *pInitialText,
BOOL winShowFlag)
{
CGenericDoc *pDocument;
LPSTR subject;
NSstringSeq mailInfoSeq;
DWORD stringCount = 6;
DWORD i;
CString csDefault;
// Get a context to use for this call...
MWContext *pOldContext = GetUsableContext();
if (!pOldContext)
{
return(MAPI_E_FAILURE);
}
// Don't allow a compose window to be created if the user hasn't
// specified an email address
const char *real_addr = FE_UsersMailAddress();
if (MISC_ValidateReturnAddress(pOldContext, real_addr) < 0)
{
return(MAPI_E_FAILURE);
}
//
// Now, we must build the fields object...
//
mailInfoSeq = (NSstringSeq) &(sendMailPtr->dataBuf[0]);
subject = NSStrSeqGet(mailInfoSeq, 0);
// We should give it a subject to preven the prompt from coming
// up...
if ((!subject) || !(*subject))
{
csDefault.LoadString(IDS_COMPOSE_DEFAULTNOSUBJECT);
subject = csDefault.GetBuffer(2);
}
TRACE("MAPI: ProcessMAPISendMail() Subject = [%s]\n", subject);
TRACE("MAPI: ProcessMAPISendMail() Text Size = [%d]\n", strlen((const char *)pInitialText));
TRACE("MAPI: ProcessMAPISendMail() # of Recipients = [%d]\n", sendMailPtr->MSG_nRecipCount);
char toString[1024] = "";
char ccString[1024] = "";
char bccString[1024] = "";
for (i=0; i<sendMailPtr->MSG_nRecipCount; i++)
{
LPSTR ptr;
UCHAR tempString[256];
ULONG addrType = atoi(NSStrSeqGet(mailInfoSeq, stringCount++));
// figure which type of address this is?
if (addrType == MAPI_CC)
ptr = ccString;
else if (addrType == MAPI_BCC)
ptr = bccString;
else
ptr = toString;
LPSTR namePtr = (LPSTR) NSStrSeqGet(mailInfoSeq, stringCount++);
LPSTR emailPtr = (LPSTR) NSStrSeqGet(mailInfoSeq, stringCount++);
if ( (lstrlen(emailPtr) > 5) && (*(emailPtr + 4) == ':') )
{
emailPtr += 5;
}
// Now build the temp string to tack on in the format
// "Rich Pizzarro" <rhp@netscape.com>
wsprintf((LPSTR) tempString, "\"%s\" <%s>", namePtr, emailPtr);
// add a comma if not the first one
if (ptr[0] != '\0')
lstrcat(ptr, ",");
// tack on string!
lstrcat(ptr, (LPSTR) tempString);
}
BOOL bEncrypt = FALSE;
BOOL bSign = FALSE;
PREF_GetBoolPref("mail.crypto_sign_outgoing_mail", &bSign);
PREF_GetBoolPref("mail.encrypt_outgoing_mail", &bEncrypt);
MSG_CompositionFields *fields =
MSG_CreateCompositionFields(real_addr, real_addr,
toString,
ccString,
bccString,
"", "", "",
"", subject, "",
"", "", "",
"",
bEncrypt,
bSign);
if (!fields)
{
return(MAPI_E_FAILURE);
}
// RICHIE
// INTL_CharSetInfo csi = LO_GetDocumentCharacterSetInfo(pOldContext);
// int16 win_csid = INTL_GetCSIWinCSID(csi);
pDocument = (CGenericDoc*)theApp.m_TextComposeTemplate->OpenDocumentFile(NULL, NULL, /*win_csid RICHIE*/ winShowFlag);
if ( !pDocument )
{
return(MAPI_E_FAILURE);
}
CWinCX * pContext = (CWinCX*) pDocument->GetContext();
if ( !pContext )
{
return(MAPI_E_FAILURE);
}
MSG_CompositionPaneCallbacks Callbacks;
Callbacks.CreateRecipientsDialog = CreateRecipientsDialog;
Callbacks.CreateAskHTMLDialog = CreateAskHTMLDialog;
int16 doccsid;
MWContext *context = pContext->GetContext();
CComposeFrame *pCompose = (CComposeFrame *) pContext->GetFrame()->GetFrameWnd();
pCompose->SetComposeStuff(context, fields); // squirl away stuff for post-create
// This needs to be set TRUE if using the old non-HTML text frame
// to prevent dropping dragged URLs
pContext->m_bDragging = !pCompose->UseHtml();
if (!pCompose->UseHtml())
{
pCompose->SetMsgPane(
MSG_CreateCompositionPane(pContext->GetContext(),
context,
g_MsgPrefs.m_pMsgPrefs,
fields,
WFE_MSGGetMaster())
);
}
ASSERT(pCompose->GetMsgPane());
MSG_SetFEData(pCompose->GetMsgPane(),(void *)pCompose);
pCompose->UpdateAttachmentInfo();
// Pass doccsid info to new context for MailToWin conversion
doccsid = INTL_GetCSIDocCSID(LO_GetDocumentCharacterSetInfo(context));
INTL_SetCSIDocCSID(LO_GetDocumentCharacterSetInfo(context),
(doccsid ? doccsid : INTL_DefaultDocCharSetID(context)));
pCompose->DisplayHeaders(NULL);
CComposeBar * pBar = pCompose->GetComposeBar();
ASSERT(pBar);
LPADDRESSCONTROL pIAddressList = pBar->GetAddressWidgetInterface();
if (!pIAddressList->IsCreated())
{
pBar->CreateAddressingBlock();
}
// rhp - Deal with addressing the brute force way! This is a
// "fix" for bad behavior when creating these windows and not
// showing them on the desktop.
if (!winShowFlag) // Hack to fix the window not being mapped
{
pCompose->AppendAddress(MSG_TO_HEADER_MASK, "");
pCompose->AppendAddress(MSG_CC_HEADER_MASK, "");
pCompose->AppendAddress(MSG_BCC_HEADER_MASK, "");
}
// Always do plain text composition!
pCompose->CompleteComposeInitialization();
// Do this so we don't get popups on "empty" messages
if ( (!pInitialText) || (!(*pInitialText)) )
pInitialText = " ";
const char * pBody = pInitialText ? pInitialText : MSG_GetCompBody(pCompose->GetMsgPane());
if (pBody)
{
FE_InsertMessageCompositionText(context,pBody,TRUE);
}
//
// Now set the message as being edited!
//
pCompose->SetModified(TRUE);
//
// Finally deal with the attachments...
//
if (sendMailPtr->MSG_nFileCount > 0)
{
// Send this puppy when done with the attachments...
if (!winShowFlag)
{
pCompose->SetMAPISendMode(MAPI_SEND);
}
MSG_AttachmentData *pAttach = (MSG_AttachmentData *)
XP_CALLOC((sendMailPtr->MSG_nFileCount + 1),
sizeof(MSG_AttachmentData));
if (!pAttach)
{
return(MAPI_E_INSUFFICIENT_MEMORY);
}
memset(pAttach, 0, (sendMailPtr->MSG_nFileCount + 1) *
sizeof(MSG_AttachmentData));
for (i=0; i<sendMailPtr->MSG_nFileCount; i++)
{
CString cs;
// Create URL from filename...
WFE_ConvertFile2Url(cs,
(const char *)NSStrSeqGet(mailInfoSeq, stringCount++));
pAttach[i].url = XP_STRDUP(cs);
// Now also include the "display" name...
StrAllocCopy(pAttach[i].real_name, NSStrSeqGet(mailInfoSeq, stringCount++));
}
// Set the list!
MSG_SetAttachmentList(pCompose->GetMsgPane(), pAttach);
// Now free everything...
for (i=0; i<sendMailPtr->MSG_nFileCount; i++)
{
if (pAttach[i].url)
XP_FREE(pAttach[i].url);
if (pAttach[i].real_name)
XP_FREE(pAttach[i].real_name);
}
XP_FREE(pAttach);
}
//
// Now, if we were supposed to do the blind send...do it, otherwise,
// just popup the window...
//
if (winShowFlag)
{
// Post message to compose window to set the initial focus.
pCompose->PostMessage(WM_COMP_SET_INITIAL_FOCUS);
}
else if (sendMailPtr->MSG_nFileCount <= 0) // Send NOW if no attachments!
{
pCompose->PostMessage(WM_COMMAND, IDM_SEND);
}
return(SUCCESS_SUCCESS);
}
//
// This function will create a composition window and just attach
// the attachments of interest and pop up the window...
//
// Return: appropriate MAPI return code...
//
//
extern "C" LONG
DoPartialMAPIMailOperation(MAPISendDocumentsType *sendDocPtr)
{
CGenericDoc *pDocument;
// Get a context to use for this call...
MWContext *pOldContext = GetUsableContext();
if (!pOldContext)
{
return(MAPI_E_FAILURE);
}
// Don't allow a compose window to be created if the user hasn't
// specified an email address
const char *real_addr = FE_UsersMailAddress();
if (MISC_ValidateReturnAddress(pOldContext, real_addr) < 0)
{
return(MAPI_E_FAILURE);
}
//
// Now, build the fields object w/o much info...
//
BOOL bEncrypt = FALSE;
BOOL bSign = FALSE;
PREF_GetBoolPref("mail.crypto_sign_outgoing_mail", &bSign);
PREF_GetBoolPref("mail.encrypt_outgoing_mail", &bEncrypt);
MSG_CompositionFields *fields =
MSG_CreateCompositionFields(real_addr, real_addr, NULL,
"", "",
"", "", "",
"", "", "",
"", "", "",
"",
bEncrypt,
bSign);
if (!fields)
{
return(MAPI_E_FAILURE);
}
// RICHIE - INTL_CharSetInfo csi = LO_GetDocumentCharacterSetInfo(pOldContext);
// int16 win_csid = INTL_GetCSIWinCSID(csi);
pDocument = (CGenericDoc*)theApp.m_TextComposeTemplate->OpenDocumentFile(NULL, NULL, /*RICHIE win_csid,*/ TRUE);
if ( !pDocument )
{
// cleanup fields object
MSG_DestroyCompositionFields(fields);
return(MAPI_E_FAILURE);
}
CWinCX * pContext = (CWinCX*) pDocument->GetContext();
if ( !pContext )
{
return(MAPI_E_FAILURE);
}
MSG_CompositionPaneCallbacks Callbacks;
Callbacks.CreateRecipientsDialog = CreateRecipientsDialog;
Callbacks.CreateAskHTMLDialog = CreateAskHTMLDialog;
MWContext *context = pContext->GetContext();
CComposeFrame *pCompose = (CComposeFrame *) pContext->GetFrame()->GetFrameWnd();
pCompose->SetComposeStuff(context,fields); // squirl away stuff for post-create
// This needs to be set TRUE if using the old non-HTML text frame
// to prevent dropping dragged URLs
pContext->m_bDragging = !pCompose->UseHtml();
if (!pCompose->UseHtml())
{
pCompose->SetMsgPane(MSG_CreateCompositionPane(
pContext->GetContext(),
context,
g_MsgPrefs.m_pMsgPrefs, fields,
WFE_MSGGetMaster()));
}
ASSERT(pCompose->GetMsgPane());
MSG_SetFEData(pCompose->GetMsgPane(),(void *)pCompose);
pCompose->UpdateAttachmentInfo();
// Pass doccsid info to new context for MailToWin conversion
/***
doccsid = INTL_GetCSIDocCSID(LO_GetDocumentCharacterSetInfo(pOldContext));
INTL_SetCSIDocCSID(LO_GetDocumentCharacterSetInfo(context),
(doccsid ? doccsid : INTL_DefaultDocCharSetID(pOldContext)));
****/
pCompose->DisplayHeaders(NULL);
CComposeBar * pBar = pCompose->GetComposeBar();
ASSERT(pBar);
LPADDRESSCONTROL pIAddressList = pBar->GetAddressWidgetInterface();
if (!pIAddressList->IsCreated())
{
pBar->CreateAddressingBlock();
}
// Always do plain text composition!
pCompose->CompleteComposeInitialization();
//
// Finally deal with the attachments...
//
NSstringSeq mailInfoSeq = (NSstringSeq) &(sendDocPtr->dataBuf[0]);
DWORD stringCount = 0;
DWORD i;
TRACE("MAPI: ProcessMAPISendDocuments() # of Attachments = [%d]\n", sendDocPtr->nFileCount);
if (sendDocPtr->nFileCount > 0)
{
MSG_AttachmentData *pAttach = (MSG_AttachmentData *)
XP_CALLOC((sendDocPtr->nFileCount + 1),
sizeof(MSG_AttachmentData));
if (!pAttach)
{
return(MAPI_E_INSUFFICIENT_MEMORY);
}
memset(pAttach, 0, (sendDocPtr->nFileCount + 1) *
sizeof(MSG_AttachmentData));
for (i=0; i<sendDocPtr->nFileCount; i++)
{
CString cs;
// Create URL from filename...
WFE_ConvertFile2Url(cs,
(const char *)NSStrSeqGet(mailInfoSeq, stringCount++));
pAttach[i].url = XP_STRDUP(cs);
// Now also include the "display" name...
StrAllocCopy(pAttach[i].real_name, NSStrSeqGet(mailInfoSeq, stringCount++));
}
// Set the list!
MSG_SetAttachmentList(pCompose->GetMsgPane(), pAttach);
// Now free everything...
for (i=0; i<sendDocPtr->nFileCount; i++)
{
if (pAttach[i].url)
XP_FREE(pAttach[i].url);
if (pAttach[i].real_name)
XP_FREE(pAttach[i].real_name);
}
XP_FREE(pAttach);
}
//
// Now some checking for ... well I'm not sure...
//
if (MSG_GetAttachmentList(pCompose->GetMsgPane()))
pCompose->SetModified(TRUE);
else
pCompose->SetModified(FALSE);
// Post message to compose window to set the initial focus.
pCompose->PostMessage(WM_COMP_SET_INITIAL_FOCUS);
//
// Now, just popup the window...
//
pCompose->ShowWindow(TRUE);
// return pCompose->GetMsgPane(); rhp - used to return the MsgPane
return(SUCCESS_SUCCESS);
}
static void _GetMailCallback(HWND hwnd, MSG_Pane *pane, void *closure)
{
if (pane != NULL)
{
ShowWindow(hwnd, SW_HIDE);
MSG_Command( pane, MSG_GetNewMail, NULL, 0 );
}
}
static void _GetMailDoneCallback(HWND hwnd, MSG_Pane *pane, void *closure)
{
for(CGenericFrame * f = theApp.m_pFrameList; f; f = f->m_pNext)
f->PostMessage(WM_COMMAND, (WPARAM) ID_DONEGETTINGMAIL, (LPARAM) 0);
}
//
// This will fire off a "get mail in background operation" in an
// async. fashion.
//
extern "C" void
MAPIGetNewMessagesInBackground(void)
{
CGenericFrame *pFrame = (CGenericFrame * )FEU_GetLastActiveFrame();
// rhp - we should not hit the net if we are offline!
if (NET_IsOffline())
return;
if (!pFrame)
return;
MWContext *pOldContext = GetUsableContext();
if (!pOldContext)
return;
TRACE("MAPI: DOWNLOAD MAIL IN BACKGROUND\n");
new CProgressDialog(
pFrame->GetFrameWnd(),
NULL,
_GetMailCallback, NULL, NULL,
_GetMailDoneCallback);
}
//
// This function will save a message into the Communicator "Drafts"
// folder with no UI showing.
//
// Return: appropriate MAPI return code...
//
//
extern "C" LONG
DoMAPISaveMailOperation(MAPISendMailType *sendMailPtr,
const char *pInitialText)
{
CGenericDoc *pDocument;
LPSTR subject;
NSstringSeq mailInfoSeq;
DWORD stringCount = 6;
DWORD i;
BOOL winShowFlag = FALSE;
// Get a context to use for this call...
MWContext *pOldContext = GetUsableContext();
if (!pOldContext)
{
return(MAPI_E_FAILURE);
}
// Don't allow a compose window to be created if the user hasn't
// specified an email address
const char *real_addr = FE_UsersMailAddress();
if (MISC_ValidateReturnAddress(pOldContext, real_addr) < 0)
{
return(MAPI_E_FAILURE);
}
//
// Now, we must build the fields object...
//
mailInfoSeq = (NSstringSeq) &(sendMailPtr->dataBuf[0]);
subject = NSStrSeqGet(mailInfoSeq, 0);
TRACE("MAPI: ProcessMAPISendMail() Subject = [%s]\n", subject);
TRACE("MAPI: ProcessMAPISendMail() Text Size = [%d]\n", strlen((const char *)pInitialText));
TRACE("MAPI: ProcessMAPISendMail() # of Recipients = [%d]\n", sendMailPtr->MSG_nRecipCount);
char toString[1024] = "";
char ccString[1024] = "";
char bccString[1024] = "";
for (i=0; i<sendMailPtr->MSG_nRecipCount; i++)
{
LPSTR ptr;
UCHAR tempString[256];
ULONG addrType = atoi(NSStrSeqGet(mailInfoSeq, stringCount++));
// figure which type of address this is?
if (addrType == MAPI_CC)
ptr = ccString;
else if (addrType == MAPI_BCC)
ptr = bccString;
else
ptr = toString;
LPSTR namePtr = (LPSTR) NSStrSeqGet(mailInfoSeq, stringCount++);
LPSTR emailPtr = (LPSTR) NSStrSeqGet(mailInfoSeq, stringCount++);
if ( (!emailPtr) && (!namePtr))
{
return(MAPI_E_INVALID_RECIPS);
}
if (!emailPtr)
emailPtr = namePtr;
char *tptr = strchr(emailPtr, ':');
if (tptr != NULL)
{
if ( (*tptr != '\0') && (*(tptr+1) != '\0') )
{
emailPtr = (tptr + 1);
}
}
/**
if ( (lstrlen(emailPtr) > 5) && (*(emailPtr + 4) == ':') )
{
emailPtr += 5;
}
**/
// Now build the temp string to tack on in the format
// "Rich Pizzarro" <rhp@netscape.com>
wsprintf((LPSTR) tempString, "\"%s\" <%s>", namePtr, emailPtr);
// add a comma if not the first one
if (ptr[0] != '\0')
lstrcat(ptr, ",");
// tack on string!
lstrcat(ptr, (LPSTR) tempString);
}
BOOL bEncrypt = FALSE;
BOOL bSign = FALSE;
PREF_GetBoolPref("mail.crypto_sign_outgoing_mail", &bSign);
PREF_GetBoolPref("mail.encrypt_outgoing_mail", &bEncrypt);
MSG_CompositionFields *fields =
MSG_CreateCompositionFields(real_addr, real_addr,
toString,
ccString,
bccString,
"", "", "",
"", subject, "",
"", "", "",
"",
bEncrypt,
bSign);
if (!fields)
{
return(MAPI_E_FAILURE);
}
// RICHIE
// INTL_CharSetInfo csi = LO_GetDocumentCharacterSetInfo(pOldContext);
// int16 win_csid = INTL_GetCSIWinCSID(csi);
pDocument = (CGenericDoc*)theApp.m_TextComposeTemplate->OpenDocumentFile(NULL, NULL, /*win_csid RICHIE*/ winShowFlag);
if ( !pDocument )
{
return(MAPI_E_FAILURE);
}
CWinCX * pContext = (CWinCX*) pDocument->GetContext();
if ( !pContext )
{
return(MAPI_E_FAILURE);
}
MSG_CompositionPaneCallbacks Callbacks;
Callbacks.CreateRecipientsDialog = CreateRecipientsDialog;
Callbacks.CreateAskHTMLDialog = CreateAskHTMLDialog;
int16 doccsid;
MWContext *context = pContext->GetContext();
CComposeFrame *pCompose = (CComposeFrame *) pContext->GetFrame()->GetFrameWnd();
pCompose->SetComposeStuff(context, fields); // squirl away stuff for post-create
// This needs to be set TRUE if using the old non-HTML text frame
// to prevent dropping dragged URLs
pContext->m_bDragging = !pCompose->UseHtml();
if (!pCompose->UseHtml())
{
pCompose->SetMsgPane(
MSG_CreateCompositionPane(pContext->GetContext(),
context,
g_MsgPrefs.m_pMsgPrefs,
fields,
WFE_MSGGetMaster())
);
}
ASSERT(pCompose->GetMsgPane());
MSG_SetFEData(pCompose->GetMsgPane(),(void *)pCompose);
pCompose->UpdateAttachmentInfo();
// Pass doccsid info to new context for MailToWin conversion
doccsid = INTL_GetCSIDocCSID(LO_GetDocumentCharacterSetInfo(context));
INTL_SetCSIDocCSID(LO_GetDocumentCharacterSetInfo(context),
(doccsid ? doccsid : INTL_DefaultDocCharSetID(context)));
pCompose->DisplayHeaders(NULL);
CComposeBar * pBar = pCompose->GetComposeBar();
ASSERT(pBar);
LPADDRESSCONTROL pIAddressList = pBar->GetAddressWidgetInterface();
if (!pIAddressList->IsCreated())
{
pBar->CreateAddressingBlock();
}
// rhp - Deal with addressing the brute force way! This is a
// "fix" for bad behavior when creating these windows and not
// showing them on the desktop.
if (!winShowFlag) // Hack to fix the window not being mapped
{
pCompose->AppendAddress(MSG_TO_HEADER_MASK, "");
pCompose->AppendAddress(MSG_CC_HEADER_MASK, "");
pCompose->AppendAddress(MSG_BCC_HEADER_MASK, "");
}
// Always do plain text composition!
pCompose->CompleteComposeInitialization();
// Do this so we don't get popups on "empty" messages
if ( (!pInitialText) || (!(*pInitialText)) )
pInitialText = " ";
const char * pBody = pInitialText ? pInitialText : MSG_GetCompBody(pCompose->GetMsgPane());
if (pBody)
{
FE_InsertMessageCompositionText(context,pBody,TRUE);
}
//
// Now set the message as being edited!
//
pCompose->SetModified(TRUE);
//
// Finally deal with the attachments...
//
if (sendMailPtr->MSG_nFileCount > 0)
{
// Send this puppy when done with the attachments...
if (!winShowFlag)
{
pCompose->SetMAPISendMode(MAPI_SAVE);
}
MSG_AttachmentData *pAttach = (MSG_AttachmentData *)
XP_CALLOC((sendMailPtr->MSG_nFileCount + 1),
sizeof(MSG_AttachmentData));
if (!pAttach)
{
return(MAPI_E_INSUFFICIENT_MEMORY);
}
memset(pAttach, 0, (sendMailPtr->MSG_nFileCount + 1) *
sizeof(MSG_AttachmentData));
for (i=0; i<sendMailPtr->MSG_nFileCount; i++)
{
CString cs;
// Create URL from filename...
WFE_ConvertFile2Url(cs,
(const char *)NSStrSeqGet(mailInfoSeq, stringCount++));
pAttach[i].url = XP_STRDUP(cs);
// Now also include the "display" name...
StrAllocCopy(pAttach[i].real_name, NSStrSeqGet(mailInfoSeq, stringCount++));
}
// Set the list!
MSG_SetAttachmentList(pCompose->GetMsgPane(), pAttach);
// Now free everything...
for (i=0; i<sendMailPtr->MSG_nFileCount; i++)
{
if (pAttach[i].url)
XP_FREE(pAttach[i].url);
if (pAttach[i].real_name)
XP_FREE(pAttach[i].real_name);
}
XP_FREE(pAttach);
}
//
// Now, if we were supposed to do the blind send...do it, otherwise,
// just popup the window...
//
if (winShowFlag)
{
// Post message to compose window to set the initial focus.
pCompose->PostMessage(WM_COMP_SET_INITIAL_FOCUS);
}
else if (sendMailPtr->MSG_nFileCount <= 0) // Send NOW if no attachments!
{
pCompose->PostMessage(WM_COMMAND, IDM_SAVEASDRAFT);
}
return(SUCCESS_SUCCESS);
}

View File

@@ -0,0 +1,89 @@
/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
/* ***** BEGIN LICENSE BLOCK *****
* Version: NPL 1.1/GPL 2.0/LGPL 2.1
*
* The contents of this file are subject to the Netscape Public License
* Version 1.1 (the "License"); you may not use this file except in
* compliance with the License. You may obtain a copy of the License at
* http://www.mozilla.org/NPL/
*
* Software distributed under the License is distributed on an "AS IS" basis,
* WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
* for the specific language governing rights and limitations under the
* License.
*
* The Original Code is mozilla.org code.
*
* The Initial Developer of the Original Code is
* Netscape Communications Corporation.
* Portions created by the Initial Developer are Copyright (C) 1998
* the Initial Developer. All Rights Reserved.
*
* Contributor(s):
*
* Alternatively, the contents of this file may be used under the terms of
* either the GNU General Public License Version 2 or later (the "GPL"), or
* the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
* in which case the provisions of the GPL or the LGPL are applicable instead
* of those above. If you wish to allow use of your version of this file only
* under the terms of either the GPL or the LGPL, and not to allow others to
* use your version of this file under the terms of the NPL, indicate your
* decision by deleting the provisions above and replace them with the notice
* and other provisions required by the GPL or the LGPL. If you do not delete
* the provisions above, a recipient may use your version of this file under
* the terms of any one of the NPL, the GPL or the LGPL.
*
* ***** END LICENSE BLOCK ***** */
#ifndef _MAPI_MAIL_H_
#define _MAPI_MAIL_H_
#include "nscpmapi.h"
#include <structs.h> // for MWContext
//extern "C" {
//
// This function will create a composition window and either do
// a blind send or pop up the compose window for the user to
// complete the operation
//
// Return: appropriate MAPI return code...
//
//
extern "C" LONG
DoFullMAPIMailOperation(MAPISendMailType *sendMailPtr,
const char *pInitialText,
BOOL winShowFlag);
//
// This function will create a composition window and just attach
// the attachments of interest and pop up the window...
//
// Return: appropriate MAPI return code...
//
//
extern "C" LONG
DoPartialMAPIMailOperation(MAPISendDocumentsType *sendDocPtr);
//
// This function will save a message into the Communicator "Drafts"
// folder with no UI showing.
//
// Return: appropriate MAPI return code...
//
//
extern "C" LONG
DoMAPISaveMailOperation(MAPISendMailType *sendMailPtr,
const char *pInitialText);
//
// This will fire off a "get mail in background operation" in an
// async. fashion.
//
extern "C" void
MAPIGetNewMessagesInBackground(void);
// } // extern "C"
#endif // _MAPI_MAIL_H_

View File

@@ -0,0 +1,50 @@
#!nmake
#
# The contents of this file are subject to the Netscape Public
# License Version 1.1 (the "License"); you may not use this file
# except in compliance with the License. You may obtain a copy of
# the License at http://www.mozilla.org/NPL/
#
# Software distributed under the License is distributed on an "AS
# IS" basis, WITHOUT WARRANTY OF ANY KIND, either express or
# implied. See the License for the specific language governing
# rights and limitations under the License.
#
# The Original Code is mozilla.org code.
#
# The Initial Developer of the Original Code is Netscape
# Communications Corporation. Portions created by Netscape are
# Copyright (C) 1998 Netscape Communications Corporation. All
# Rights Reserved.
#
# Contributor(s):
DEPTH=..\..\..
MODULE=mapiutils
include <$(DEPTH)\config\config.mak>
################################################################################
## exports
EXPORTS= mapismem.h \
nsstrseq.h \
$(NULL)
################################################################################
## library
LIBRARY_NAME=mapiutils_s
CPP_OBJS= .\$(OBJDIR)\mapismem.obj \
.\$(OBJDIR)\nsstrseq.obj \
$(NULL)
include <$(DEPTH)\config\rules.mak>
install:: $(LIBRARY)
$(MAKE_INSTALL) $(LIBRARY) $(DIST)\lib
clobber::
rm -f $(DIST)\lib\$(LIBRARY_NAME).lib

View File

@@ -0,0 +1,173 @@
/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
/* ***** BEGIN LICENSE BLOCK *****
* Version: NPL 1.1/GPL 2.0/LGPL 2.1
*
* The contents of this file are subject to the Netscape Public License
* Version 1.1 (the "License"); you may not use this file except in
* compliance with the License. You may obtain a copy of the License at
* http://www.mozilla.org/NPL/
*
* Software distributed under the License is distributed on an "AS IS" basis,
* WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
* for the specific language governing rights and limitations under the
* License.
*
* The Original Code is mozilla.org code.
*
* The Initial Developer of the Original Code is
* Netscape Communications Corporation.
* Portions created by the Initial Developer are Copyright (C) 1998
* the Initial Developer. All Rights Reserved.
*
* Contributor(s):
*
* Alternatively, the contents of this file may be used under the terms of
* either the GNU General Public License Version 2 or later (the "GPL"), or
* the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
* in which case the provisions of the GPL or the LGPL are applicable instead
* of those above. If you wish to allow use of your version of this file only
* under the terms of either the GPL or the LGPL, and not to allow others to
* use your version of this file under the terms of the NPL, indicate your
* decision by deleting the provisions above and replace them with the notice
* and other provisions required by the GPL or the LGPL. If you do not delete
* the provisions above, a recipient may use your version of this file under
* the terms of any one of the NPL, the GPL or the LGPL.
*
* ***** END LICENSE BLOCK ***** */
//
// smem.cpp - This deals with all shared memory functions needed for
// the MAPI component of Communicator
// Written by: Rich Pizzarro (rhp@netscape.com)
// November 1997
//
#include <windows.h>
#include <windowsx.h>
#include "mapismem.h"
#ifndef ZeroMemory
#include <memory.h>
#define ZeroMemory(PTR, SIZE) memset(PTR, 0, SIZE)
#endif // ZeroMemory
//
// *create new* shared memory chunk
// once this is created, use the pointer
// to the segment to to store data
// e.g.:
// lpString = "string for communicator";
// lstrcpy((LPSTR)pData->m_buf[0], lpString);
//
CSharedMem *
NSCreateSharedMemory(DWORD memSize, LPCTSTR memName, HANDLE *hSharedMemory)
{
#ifdef WIN32
BOOL bExistedBefore;
CSharedMem *pData;
LPCTSTR szObjectName = memName;
DWORD dwSize = sizeof(CSharedMem) + memSize;
*hSharedMemory = CreateFileMapping(
(HANDLE)0xFFFFFFFF,0,PAGE_READWRITE,0,dwSize,szObjectName);
if(*hSharedMemory == 0)
{
return NULL;
}
bExistedBefore = (GetLastError() == ERROR_ALREADY_EXISTS);
if(bExistedBefore)
{
return NULL;
}
pData = (CSharedMem *)MapViewOfFile(
*hSharedMemory, FILE_MAP_ALL_ACCESS, 0, 0, 0);
if(pData == NULL)
{
return NULL;
}
ZeroMemory(pData, dwSize);
pData->m_dwSize = memSize;
return pData;
#else
CSharedMem *sMemChunk = NULL;
DWORD dwSize = memSize = (sizeof(CSharedMem) + memSize);
if (sMemChunk != NULL)
return(sMemChunk);
sMemChunk = (CSharedMem *) GlobalAllocPtr(GMEM_MOVEABLE, dwSize);
ZeroMemory(sMemChunk, (size_t) dwSize);
sMemChunk->m_dwSize = dwSize; // Missing in Communicator code!
return(sMemChunk);
#endif // WIN32
}
//
// *open existing* shared memory chunk
// once you have the pointer to the new segment
// use this pointer to access data, e.g.:
//
CSharedMem *
NSOpenExistingSharedMemory(LPCTSTR memName, HANDLE *hSharedMemory)
{
#ifdef WIN32
CSharedMem *pData;
DWORD dwSize;
LPCTSTR szObjectName = memName;
*hSharedMemory = OpenFileMapping(
FILE_MAP_WRITE,FALSE,szObjectName);
if(*hSharedMemory == 0)
{
return NULL;
}
pData = (CSharedMem *)MapViewOfFile(
*hSharedMemory,FILE_MAP_ALL_ACCESS,0,0,0);
if(pData == NULL)
{
return NULL;
}
dwSize = pData->m_dwSize;
return pData;
#else
return(NULL); // In Win16, this is really meaningless...
#endif
}
//
// to close shared memory segment
//
void
NSCloseSharedMemory(CSharedMem *pData, HANDLE hSharedMemory)
{
#ifdef WIN32
if(pData != 0)
{
UnmapViewOfFile(pData);
pData = 0;
}
if(hSharedMemory != 0)
{
CloseHandle(hSharedMemory);
hSharedMemory = 0;
}
#else
if (pData != NULL)
{
GlobalFreePtr(pData);
pData = NULL;
}
#endif // WIN32
}

View File

@@ -0,0 +1,116 @@
/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
/* ***** BEGIN LICENSE BLOCK *****
* Version: NPL 1.1/GPL 2.0/LGPL 2.1
*
* The contents of this file are subject to the Netscape Public License
* Version 1.1 (the "License"); you may not use this file except in
* compliance with the License. You may obtain a copy of the License at
* http://www.mozilla.org/NPL/
*
* Software distributed under the License is distributed on an "AS IS" basis,
* WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
* for the specific language governing rights and limitations under the
* License.
*
* The Original Code is mozilla.org code.
*
* The Initial Developer of the Original Code is
* Netscape Communications Corporation.
* Portions created by the Initial Developer are Copyright (C) 1998
* the Initial Developer. All Rights Reserved.
*
* Contributor(s):
*
* Alternatively, the contents of this file may be used under the terms of
* either the GNU General Public License Version 2 or later (the "GPL"), or
* the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
* in which case the provisions of the GPL or the LGPL are applicable instead
* of those above. If you wish to allow use of your version of this file only
* under the terms of either the GPL or the LGPL, and not to allow others to
* use your version of this file under the terms of the NPL, indicate your
* decision by deleting the provisions above and replace them with the notice
* and other provisions required by the GPL or the LGPL. If you do not delete
* the provisions above, a recipient may use your version of this file under
* the terms of any one of the NPL, the GPL or the LGPL.
*
* ***** END LICENSE BLOCK ***** */
#ifndef __SMEM_HPP__
#define __SMEM_HPP__
//
// Need this for Win16 since it is an undocumented message
//
#ifndef WIN32
#define WM_COPYDATA 0x004A
/*
* lParam of WM_COPYDATA message points to...
*/
typedef struct tagCOPYDATASTRUCT {
DWORD dwData;
DWORD cbData;
LPVOID lpData;
} COPYDATASTRUCT, *PCOPYDATASTRUCT;
# ifndef LPCTSTR
# define LPCTSTR LPCSTR
# endif
#endif // ifndef WIN32
// The following structure will be stored in the shared memory
// and will be used to pass data back and forth
#pragma pack(4)
typedef struct
{
DWORD m_dwSize; // size of the shared memory block
BYTE m_buf[1]; // this is the buffer of memory to be used
} CSharedMem;
#pragma pack(4)
// ******************************************************
// Public routines...
// ******************************************************
//
//
// *create new* shared memory chunk
// once this is created, use the pointer
// to the segment to to store data
// e.g.:
// lpString = "string for communicator";
// lstrcpy((LPSTR)pData->m_buf[0], lpString);
// pData->m_dwBytesUsed = lstrlen(lpString) + 1; // count '\0'
//
CSharedMem *
NSCreateSharedMemory(DWORD memSize, LPCTSTR memName, HANDLE *hSharedMemory);
//
// *open existing* shared memory chunk
// once you have the pointer to the new segment
// use this pointer to access data, e.g.:
//
// This will return the pointer to the memory chunk as well as
// fill out the hSharedMemory argument that is needed for subsequent
// operations.
//
// if(pData->m_dwBytesUsed > 0)
// {
// // use pData->m_buf here
// }
//
CSharedMem *
NSOpenExistingSharedMemory(LPCTSTR memName, HANDLE *hSharedMemory);
//
// You must pass in the pointer to the memory chunk as well as
// the hSharedMemory HANDLE to close shared memory segment
//
void
NSCloseSharedMemory(CSharedMem *pData, HANDLE hSharedMemory);
#endif // __SMEM_HPP__

View File

@@ -0,0 +1,230 @@
/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
/* ***** BEGIN LICENSE BLOCK *****
* Version: NPL 1.1/GPL 2.0/LGPL 2.1
*
* The contents of this file are subject to the Netscape Public License
* Version 1.1 (the "License"); you may not use this file except in
* compliance with the License. You may obtain a copy of the License at
* http://www.mozilla.org/NPL/
*
* Software distributed under the License is distributed on an "AS IS" basis,
* WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
* for the specific language governing rights and limitations under the
* License.
*
* The Original Code is mozilla.org code.
*
* The Initial Developer of the Original Code is
* Netscape Communications Corporation.
* Portions created by the Initial Developer are Copyright (C) 1998
* the Initial Developer. All Rights Reserved.
*
* Contributor(s):
*
* Alternatively, the contents of this file may be used under the terms of
* either the GNU General Public License Version 2 or later (the "GPL"), or
* the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
* in which case the provisions of the GPL or the LGPL are applicable instead
* of those above. If you wish to allow use of your version of this file only
* under the terms of either the GPL or the LGPL, and not to allow others to
* use your version of this file under the terms of the NPL, indicate your
* decision by deleting the provisions above and replace them with the notice
* and other provisions required by the GPL or the LGPL. If you do not delete
* the provisions above, a recipient may use your version of this file under
* the terms of any one of the NPL, the GPL or the LGPL.
*
* ***** END LICENSE BLOCK ***** */
//
// This is a string sequence handling routine to take complex
// structures and merge them into a chunk of memory.
//
// Written by: Rich Pizzarro (rhp@netscape.com)
// November 1997
//
#include <string.h>
#include <stdlib.h>
#include <windows.h>
#include <windowsx.h>
#include "nsstrseq.h"
#ifndef NULL
#define NULL '\0'
#endif
#define MARKER '\377'
//
// Delete an existing string sequence
//
void NSStrSeqDelete(NSstringSeq seq)
{
if (seq != NULL)
free(seq);
seq = NULL;
}
//
// Allocate a new sequence, copying the given strings into it.
//
NSstringSeq NSStrSeqNew(LPSTR strings[])
{
int size;
if (!strings)
{
return NULL;
}
{
int i;
for (i=0,size=0; strings[i]; i++)
{
size+=strlen(strings[i])+1;
switch (strings[i][0])
{
// Need to pad "" or anything starting with 255
// to allow for multiple blank strings in a row
case 0:
case MARKER:
size++;
break;
default:
break;
}
}
}
{
NSstringSeq s=(NSstringSeq)malloc(size+1);
if (!s)
{ return NULL;}
{
int i,offset;
for (i=0,offset=0; strings[i]; i++)
{
switch (strings[i][0])
{
// Need to pad "" or anything starting with 255
case 0:
case MARKER:
s[offset++]=MARKER;
break;
default:
break;
}
strcpy(s+offset,strings[i]);
offset+=strlen(strings[i])+1;
}
s[offset]=0;
}
return s;
}
}
//
// Get the # of bytes required for the sequence
//
LONG NSStrSeqSize(NSstringSeq seq)
{
const char* s;
if (!seq)
{
return -1;
}
for (s=seq+1; ((*s) || (*(s-1))); s++)
;
// At this point, s points to the second 0
// of the double 0 at the end
return (s-seq)+1;
}
//
// Get the # of strings in the sequence
//
LONG NSStrSeqNumStrs(NSstringSeq seq)
{
const char* s;
int N;
if (!seq)
{
return -1;
}
for (s=seq+1,N=0; ((*s) || (*(s-1))); s++)
{
if (!(*s))
N++;
}
return N;
}
static LPSTR correct(LPSTR s)
{
if (s[0]==MARKER)
return s+1;
else // Anup , 4/96
return s;
}
//
// Extract the index'th string in the sequence
//
LPSTR NSStrSeqGet(NSstringSeq seq, LONG index)
{
char* s;
int N;
if (!seq)
{
return NULL;
}
if (index<0)
{
return NULL;
}
if (!index)
return correct(seq);
for (s=seq+1,N=0; ((*s) || (*(s-1))) && (N<index); s++)
{
if (!(*s))
N++;
}
if (N==index)
return correct(s);
return NULL;
}
LPSTR * NSStrSeqGetAll(NSstringSeq seq)
{
LONG N=NSStrSeqNumStrs(seq);
if (N<0)
return NULL;
{
char** res=(char**)malloc( (size_t) ((N+1)*sizeof(char*)) );
int i;
if (!res)
{
return NULL;
}
for (i=0; i<N; i++)
res[i]=NSStrSeqGet(seq,i);
res[N]=NULL;
return res;
}
}

View File

@@ -0,0 +1,68 @@
/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
/* ***** BEGIN LICENSE BLOCK *****
* Version: NPL 1.1/GPL 2.0/LGPL 2.1
*
* The contents of this file are subject to the Netscape Public License
* Version 1.1 (the "License"); you may not use this file except in
* compliance with the License. You may obtain a copy of the License at
* http://www.mozilla.org/NPL/
*
* Software distributed under the License is distributed on an "AS IS" basis,
* WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
* for the specific language governing rights and limitations under the
* License.
*
* The Original Code is mozilla.org code.
*
* The Initial Developer of the Original Code is
* Netscape Communications Corporation.
* Portions created by the Initial Developer are Copyright (C) 1998
* the Initial Developer. All Rights Reserved.
*
* Contributor(s):
*
* Alternatively, the contents of this file may be used under the terms of
* either the GNU General Public License Version 2 or later (the "GPL"), or
* the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
* in which case the provisions of the GPL or the LGPL are applicable instead
* of those above. If you wish to allow use of your version of this file only
* under the terms of either the GPL or the LGPL, and not to allow others to
* use your version of this file under the terms of the NPL, indicate your
* decision by deleting the provisions above and replace them with the notice
* and other provisions required by the GPL or the LGPL. If you do not delete
* the provisions above, a recipient may use your version of this file under
* the terms of any one of the NPL, the GPL or the LGPL.
*
* ***** END LICENSE BLOCK ***** */
#ifndef __SEQUENCES_OF_STRINGS_H_
#define __SEQUENCES_OF_STRINGS_H
typedef LPSTR NSstringSeq;
#ifdef __cplusplus
extern "C"
{
#endif
void NSStrSeqDelete(NSstringSeq seq);
NSstringSeq NSStrSeqNew(LPSTR strings[]);
// Get the # of bytes required for the sequence
LONG NSStrSeqSize(NSstringSeq seq);
// Get the # of strings in the sequence
LONG NSStrSeqNumStrs(NSstringSeq seq);
// Extract the index'th string in the sequence
LPSTR NSStrSeqGet(NSstringSeq seq, LONG index);
// Build an array of all the strings in the sequence
LPSTR *NSStrSeqGetAll(NSstringSeq seq);
#ifdef __cplusplus
}
#endif
#endif // __sequences_of_strings_h_

View File

@@ -0,0 +1,26 @@
#!nmake
#
# The contents of this file are subject to the Netscape Public
# License Version 1.1 (the "License"); you may not use this file
# except in compliance with the License. You may obtain a copy of
# the License at http://www.mozilla.org/NPL/
#
# Software distributed under the License is distributed on an "AS
# IS" basis, WITHOUT WARRANTY OF ANY KIND, either express or
# implied. See the License for the specific language governing
# rights and limitations under the License.
#
# The Original Code is mozilla.org code.
#
# The Initial Developer of the Original Code is Netscape
# Communications Corporation. Portions created by Netscape are
# Copyright (C) 1998 Netscape Communications Corporation. All
# Rights Reserved.
#
# Contributor(s):
DEPTH=..\..
DIRS=public lib mapi32 tests hook
include <$(DEPTH)\config\rules.mak>

View File

@@ -0,0 +1,100 @@
/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
/* ***** BEGIN LICENSE BLOCK *****
* Version: NPL 1.1/GPL 2.0/LGPL 2.1
*
* The contents of this file are subject to the Netscape Public License
* Version 1.1 (the "License"); you may not use this file except in
* compliance with the License. You may obtain a copy of the License at
* http://www.mozilla.org/NPL/
*
* Software distributed under the License is distributed on an "AS IS" basis,
* WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
* for the specific language governing rights and limitations under the
* License.
*
* The Original Code is mozilla.org code.
*
* The Initial Developer of the Original Code is
* Netscape Communications Corporation.
* Portions created by the Initial Developer are Copyright (C) 1998
* the Initial Developer. All Rights Reserved.
*
* Contributor(s):
*
* Alternatively, the contents of this file may be used under the terms of
* either the GNU General Public License Version 2 or later (the "GPL"), or
* the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
* in which case the provisions of the GPL or the LGPL are applicable instead
* of those above. If you wish to allow use of your version of this file only
* under the terms of either the GPL or the LGPL, and not to allow others to
* use your version of this file under the terms of the NPL, indicate your
* decision by deleting the provisions above and replace them with the notice
* and other provisions required by the GPL or the LGPL. If you do not delete
* the provisions above, a recipient may use your version of this file under
* the terms of any one of the NPL, the GPL or the LGPL.
*
* ***** END LICENSE BLOCK ***** */
//
// DLLMain to get a handle on an hInstance
// Written by: Rich Pizzarro (rhp@netscape.com)
// November 1997
#include <windows.h>
//
// global variables
//
HINSTANCE hInstance;
//
// DLL entry
//
#ifdef WIN32
/****************************************************************************
FUNCTION: DllMain(HANDLE, DWORD, LPVOID)
PURPOSE: DllMain is called by Windows when
the DLL is initialized, Thread Attached, and other times.
Refer to SDK documentation, as to the different ways this
may be called.
The DllMain function should perform additional initialization
tasks required by the DLL. In this example, no initialization
tasks are required. DllMain should return a value of 1 if
the initialization is successful.
*******************************************************************************/
BOOL APIENTRY DllMain(HANDLE hInstLocal, DWORD ul_reason_being_called, LPVOID lpReserved)
{
hInstance = (HINSTANCE)hInstLocal;
if (hInstance != NULL)
return 1;
else
return 0;
}
#else // WIN16
//--------------------------------------------------------------------
// LibMain( hInstance, wDataSegment, wHeapSize, lpszCmdLine ) : WORD
//
// hInstance library instance handle
// wDataSegment library data segment
// wHeapSize default heap size
// lpszCmdLine command line arguments
//
//--------------------------------------------------------------------
int CALLBACK LibMain(HINSTANCE hInstLocal, WORD wDataSegment, WORD wHeapSize, LPSTR lpszCmdLine)
{
hInstance = hInstLocal;
/* return result 1 = success; 0 = fail */
if (hInstance != NULL)
return 1;
else
return 0;
}
#endif // WIN16

View File

@@ -0,0 +1,70 @@
# The contents of this file are subject to the Netscape Public
# License Version 1.1 (the "License"); you may not use this file
# except in compliance with the License. You may obtain a copy of
# the License at http://www.mozilla.org/NPL/
#
# Software distributed under the License is distributed on an "AS
# IS" basis, WITHOUT WARRANTY OF ANY KIND, either express or
# implied. See the License for the specific language governing
# rights and limitations under the License.
#
# The Original Code is mozilla.org code.
#
# The Initial Developer of the Original Code is Netscape
# Communications Corporation. Portions created by Netscape are
# Copyright (C) 1998 Netscape Communications Corporation. All
# Rights Reserved.
#
# Contributor(s):
#
DEPTH=..\..\..
MODULE=mapi32
################################################################################
## exports
#EXPORTS =
################################################################################
## library
LIBNAME = .\$(OBJDIR)\mapi32
DEFINES= -NS_DEBUG
DEFFILE=MAPI32.def
!ifdef MOZ_STATIC_COMPONENT_LIBS
LIB = $(LIBNAME).lib
!else
DLL = $(LIBNAME).dll
!endif
OBJS= \
.\$(OBJDIR)\maindll.obj \
.\$(OBJDIR)\mapi32.obj \
.\$(OBJDIR)\mapiipc.obj \
.\$(OBJDIR)\mapimem.obj \
.\$(OBJDIR)\mapiutl.obj \
.\$(OBJDIR)\smem.obj \
.\$(OBJDIR)\trace.obj \
.\$(OBJDIR)\xpapi.obj \
$(NULL)
LLIBS= \
$(LLIBS) \
$(LIBNSPR) \
$(DIST)\lib\xppref32.lib \
$(DIST)\lib\xpcom.lib \
$(DIST)\lib\mapiutils_s.lib \
$(NULL)
include <$(DEPTH)\config\rules.mak>
!ifdef MOZ_STATIC_COMPONENT_LIBS
install:: $(LIB)
$(MAKE_INSTALL) $(LIBNAME).$(LIB_SUFFIX) $(DIST)\bin\components
!else
install:: $(DLL)
$(MAKE_INSTALL) $(LIBNAME).$(DLL_SUFFIX) $(DIST)\bin\components
!endif

File diff suppressed because it is too large Load Diff

View File

@@ -0,0 +1,14 @@
EXPORTS
MAPILogon
MAPILogoff
MAPISendMail
MAPISendDocuments
MAPIFreeBuffer
MAPIFindNext
MAPIReadMail
MAPISaveMail
MAPIDeleteMail
MAPIAddress
MAPIDetails
MAPIResolveName
MAPIGetNetscapeVersion

View File

@@ -0,0 +1,146 @@
// Insert copyright and license here 1997
//Microsoft Developer Studio generated resource script.
//
#include "resource.h"
#define APSTUDIO_READONLY_SYMBOLS
/////////////////////////////////////////////////////////////////////////////
//
// Generated from the TEXTINCLUDE 2 resource.
//
#include "afxres.h"
/////////////////////////////////////////////////////////////////////////////
#undef APSTUDIO_READONLY_SYMBOLS
/////////////////////////////////////////////////////////////////////////////
// English (U.S.) resources
#if !defined(AFX_RESOURCE_DLL) || defined(AFX_TARG_ENU)
#ifdef _WIN32
LANGUAGE LANG_ENGLISH, SUBLANG_ENGLISH_US
#pragma code_page(1252)
#endif //_WIN32
/////////////////////////////////////////////////////////////////////////////
//
// Dialog
//
ID_DIALOG_MAPI DIALOGEX 0, 0, 186, 111
STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU
EXSTYLE WS_EX_TOOLWINDOW
CAPTION "Netscape MAPI Support"
FONT 8, "MS Sans Serif"
BEGIN
DEFPUSHBUTTON "OK",IDOK,41,95,50,14
PUSHBUTTON "Cancel",IDCANCEL,104,95,50,14
GROUPBOX "Diagnostic Information",IDC_STATIC,2,2,182,91
CTEXT "This window will contain MAPI relative\ninformation for Netscape Communicator",
IDC_STATIC,11,14,159,30
END
/////////////////////////////////////////////////////////////////////////////
//
// DESIGNINFO
//
#ifdef APSTUDIO_INVOKED
GUIDELINES DESIGNINFO DISCARDABLE
BEGIN
ID_DIALOG_MAPI, DIALOG
BEGIN
LEFTMARGIN, 2
RIGHTMARGIN, 184
TOPMARGIN, 2
BOTTOMMARGIN, 109
END
END
#endif // APSTUDIO_INVOKED
#ifdef APSTUDIO_INVOKED
/////////////////////////////////////////////////////////////////////////////
//
// TEXTINCLUDE
//
1 TEXTINCLUDE DISCARDABLE
BEGIN
"resource.h\0"
END
2 TEXTINCLUDE DISCARDABLE
BEGIN
"#include ""afxres.h""\r\n"
"\0"
END
3 TEXTINCLUDE DISCARDABLE
BEGIN
"\r\n"
"\0"
END
#endif // APSTUDIO_INVOKED
#ifndef _MAC
/////////////////////////////////////////////////////////////////////////////
//
// Version
//
VS_VERSION_INFO VERSIONINFO
FILEVERSION 5,0,0,1
PRODUCTVERSION 5,0,0,1
FILEFLAGSMASK 0x3fL
#ifdef _DEBUG
FILEFLAGS 0x1L
#else
FILEFLAGS 0x0L
#endif
FILEOS 0x40004L
FILETYPE 0x2L
FILESUBTYPE 0x0L
BEGIN
BLOCK "StringFileInfo"
BEGIN
BLOCK "040904b0"
BEGIN
VALUE "Comments", "Simple MAPI DLL\0"
VALUE "CompanyName", "Netscape Communications Corporation\0"
VALUE "FileDescription", "mapi32\0"
VALUE "FileVersion", "5, 0, 0, 1\0"
VALUE "InternalName", "mapi32\0"
VALUE "LegalCopyright", "Copyright © 1997\0"
VALUE "LegalTrademarks", "Netscape and Netscape Navigator are registered trademarks of Netscape Communications Corporation.\0"
VALUE "OriginalFilename", "mapi32.dll\0"
VALUE "ProductName", "Netscape Communications Simple MAPI\0"
VALUE "ProductVersion", "5, 0, 0, 1\0"
END
END
BLOCK "VarFileInfo"
BEGIN
VALUE "Translation", 0x409, 1200
END
END
#endif // !_MAC
#endif // English (U.S.) resources
/////////////////////////////////////////////////////////////////////////////
#ifndef APSTUDIO_INVOKED
/////////////////////////////////////////////////////////////////////////////
//
// Generated from the TEXTINCLUDE 3 resource.
//
/////////////////////////////////////////////////////////////////////////////
#endif // not APSTUDIO_INVOKED

View File

@@ -0,0 +1,249 @@
/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
/* ***** BEGIN LICENSE BLOCK *****
* Version: NPL 1.1/GPL 2.0/LGPL 2.1
*
* The contents of this file are subject to the Netscape Public License
* Version 1.1 (the "License"); you may not use this file except in
* compliance with the License. You may obtain a copy of the License at
* http://www.mozilla.org/NPL/
*
* Software distributed under the License is distributed on an "AS IS" basis,
* WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
* for the specific language governing rights and limitations under the
* License.
*
* The Original Code is mozilla.org code.
*
* The Initial Developer of the Original Code is
* Netscape Communications Corporation.
* Portions created by the Initial Developer are Copyright (C) 1998
* the Initial Developer. All Rights Reserved.
*
* Contributor(s):
*
* Alternatively, the contents of this file may be used under the terms of
* either the GNU General Public License Version 2 or later (the "GPL"), or
* the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
* in which case the provisions of the GPL or the LGPL are applicable instead
* of those above. If you wish to allow use of your version of this file only
* under the terms of either the GPL or the LGPL, and not to allow others to
* use your version of this file under the terms of the NPL, indicate your
* decision by deleting the provisions above and replace them with the notice
* and other provisions required by the GPL or the LGPL. If you do not delete
* the provisions above, a recipient may use your version of this file under
* the terms of any one of the NPL, the GPL or the LGPL.
*
* ***** END LICENSE BLOCK ***** */
//
// MAPI IPC Routines
// Written by: Rich Pizzarro (rhp@netscape.com)
// November 1997
//
#include <windows.h>
#include <windowsx.h>
#include <nscpmapi.h> // Should live in Communicator
#include "resource.h"
#include "mapiipc.h"
#include "mapismem.h"
#include "trace.h"
#ifndef WIN32
#include <string.h>
#endif
//
// Necessary variables...
//
static LONG instanceCount = 0;
HWND hWndMAPI = NULL;
char szClassName[] = "NetscapeMAPIClient";
char szWindowName[] = "NetscapeMAPI";
//
// External declares...
//
extern HINSTANCE hInstance;
void
ProcessCommand(HWND hWnd, int id, HWND hCtl, UINT codeNotify)
{
switch (id)
{
case IDOK:
case IDCANCEL:
{
ShowWindow(hWnd, SW_HIDE);
}
default:
;
}
}
BOOL CALLBACK LOADDS
MyDlgProc(HWND hWndMain, UINT wMsg, WPARAM wParam, LPARAM lParam)
{
switch (wMsg)
{
case WM_INITDIALOG:
{
hWndMAPI = hWndMain;
}
break;
case WM_CLOSE:
// DestroyWindow(hWndMain);
break;
case WM_DESTROY:
hWndMain = NULL;
break;
case WM_COMMAND:
HANDLE_WM_COMMAND(hWndMAPI, wParam, lParam, ProcessCommand);
break;
default:
return FALSE;
}
return TRUE;
}
BOOL
InitInstance(HINSTANCE hInstance)
{
//
// Create a main window for this application instance.
//
/* RICHIE - TRY SOME CHANGES!!!
hWndMAPI = CreateDialog((HINSTANCE) hInstance,
MAKEINTRESOURCE(ID_DIALOG_QAHOOK),
(HWND) NULL, (DLGPROC) MyDlgProc);
******/
hWndMAPI = CreateWindow(
szClassName, // pointer to registered class name
szWindowName, // pointer to window name
WS_CHILD, // window style
-10, // horizontal position of window
-10, // vertical position of window
1, // window width
1, // window height
GetDesktopWindow(), // handle to parent or owner window
NULL, // handle to menu or child-window identifier
hInstance, // handle to application instance
NULL // pointer to window-creation data
);
if (!hWndMAPI)
return FALSE;
else
return TRUE;
}
BOOL
InitApp(void)
{
#ifdef WIN32
WNDCLASS wc;
wc.style = 0;
wc.lpfnWndProc = DefDlgProc;
wc.cbClsExtra = 0;
wc.cbWndExtra = DLGWINDOWEXTRA;
wc.hInstance = hInstance;
wc.hIcon = LoadIcon(hInstance, MAKEINTRESOURCE(ID_ICON_APP));
wc.hCursor = LoadCursor(0, IDC_ARROW);
wc.hbrBackground = (HBRUSH)(COLOR_BTNFACE + 1);
wc.lpszMenuName = NULL;
wc.lpszClassName = szClassName;
if(!RegisterClass(&wc))
return FALSE;
#endif
return TRUE;
} // end InitApp
BOOL
InitDLL(void)
{
if (hWndMAPI != NULL)
return TRUE;
if (!InitApp())
{
return FALSE;
}
if (!InitInstance(hInstance))
{
return FALSE;
}
// ShowWindow(hWndMAPI, SW_SHOW); Just for jollies
return(TRUE);
}
//*************************************************************
//* Calls exposed for rest of DLL...
//*************************************************************
//
// Purpose: Open the API
// Return: 1 on success
// 0 on failure
//
DWORD nsMAPI_OpenAPI(void)
{
if (instanceCount > 0)
{
return(1);
}
++instanceCount;
return(1);
}
//
// Purpose: Close the API
//
void nsMAPI_CloseAPI(void)
{
--instanceCount;
if (instanceCount <= 0)
{
instanceCount = 0;
}
return;
}
//
// Send the actual request to Communicator
//
LRESULT
SendMAPIRequest(HWND hWnd,
DWORD mapiRequestID,
MAPIIPCType *ipcInfo)
{
LRESULT returnVal = 0;
COPYDATASTRUCT cds;
if (!InitDLL())
{
return 0;
}
cds.dwData = mapiRequestID;
cds.cbData = sizeof(MAPIIPCType);
cds.lpData = ipcInfo;
// Make the call into Communicator
returnVal = SendMessage(hWnd, WM_COPYDATA, (WPARAM) hWndMAPI, (LPARAM) &cds);
// Now kill the window...
DestroyWindow(hWndMAPI);
hWndMAPI = NULL;
UnregisterClass(szClassName, hInstance);
return returnVal;
}

View File

@@ -0,0 +1,63 @@
/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
/* ***** BEGIN LICENSE BLOCK *****
* Version: NPL 1.1/GPL 2.0/LGPL 2.1
*
* The contents of this file are subject to the Netscape Public License
* Version 1.1 (the "License"); you may not use this file except in
* compliance with the License. You may obtain a copy of the License at
* http://www.mozilla.org/NPL/
*
* Software distributed under the License is distributed on an "AS IS" basis,
* WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
* for the specific language governing rights and limitations under the
* License.
*
* The Original Code is mozilla.org code.
*
* The Initial Developer of the Original Code is
* Netscape Communications Corporation.
* Portions created by the Initial Developer are Copyright (C) 1998
* the Initial Developer. All Rights Reserved.
*
* Contributor(s):
*
* Alternatively, the contents of this file may be used under the terms of
* either the GNU General Public License Version 2 or later (the "GPL"), or
* the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
* in which case the provisions of the GPL or the LGPL are applicable instead
* of those above. If you wish to allow use of your version of this file only
* under the terms of either the GPL or the LGPL, and not to allow others to
* use your version of this file under the terms of the NPL, indicate your
* decision by deleting the provisions above and replace them with the notice
* and other provisions required by the GPL or the LGPL. If you do not delete
* the provisions above, a recipient may use your version of this file under
* the terms of any one of the NPL, the GPL or the LGPL.
*
* ***** END LICENSE BLOCK ***** */
#ifndef __MAPIIPC_HPP__
#define __MAPIIPC_HPP__
#include "port.h"
#include <nscpmapi.h>
//********************************************************
// Open and close functions for API
//********************************************************
// Open the API
// Return: 1 on success, 0 on failure
//
DWORD nsMAPI_OpenAPI(void);
//
// Purpose: Close the API
//
void nsMAPI_CloseAPI(void);
//
// Send the actual request to Communicator
//
LRESULT SendMAPIRequest(HWND hWnd,
DWORD mapiRequestID,
MAPIIPCType *ipcInfo);
#endif // __MAPIIPC_HPP__

View File

@@ -0,0 +1,363 @@
/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
/* ***** BEGIN LICENSE BLOCK *****
* Version: NPL 1.1/GPL 2.0/LGPL 2.1
*
* The contents of this file are subject to the Netscape Public License
* Version 1.1 (the "License"); you may not use this file except in
* compliance with the License. You may obtain a copy of the License at
* http://www.mozilla.org/NPL/
*
* Software distributed under the License is distributed on an "AS IS" basis,
* WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
* for the specific language governing rights and limitations under the
* License.
*
* The Original Code is mozilla.org code.
*
* The Initial Developer of the Original Code is
* Netscape Communications Corporation.
* Portions created by the Initial Developer are Copyright (C) 1998
* the Initial Developer. All Rights Reserved.
*
* Contributor(s):
*
* Alternatively, the contents of this file may be used under the terms of
* either the GNU General Public License Version 2 or later (the "GPL"), or
* the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
* in which case the provisions of the GPL or the LGPL are applicable instead
* of those above. If you wish to allow use of your version of this file only
* under the terms of either the GPL or the LGPL, and not to allow others to
* use your version of this file under the terms of the NPL, indicate your
* decision by deleting the provisions above and replace them with the notice
* and other provisions required by the GPL or the LGPL. If you do not delete
* the provisions above, a recipient may use your version of this file under
* the terms of any one of the NPL, the GPL or the LGPL.
*
* ***** END LICENSE BLOCK ***** */
//
// mem.cpp
// Written by: Rich Pizzarro (rhp@netscape.com)
// November 1997
// This implements various memory management functions for use with
// MAPI features of Communicator
//
#include <windows.h>
#include <memory.h>
#include <malloc.h>
#include "mapimem.h"
#include <nscpmapi.h> // lives in communicator winfe
#include "nsstrseq.h"
#include "trace.h"
#include "mapiutl.h"
#include "xpapi.h"
LPSTR
CheckNullString(LPSTR inStr)
{
static UCHAR str[1];
str[0] = '\0';
if (inStr == NULL)
return((LPSTR)str);
else
return(inStr);
}
void
FreeMAPIFile(lpMapiFileDesc pv)
{
if (!pv)
return;
if (pv->lpszPathName != NULL)
free(pv->lpszPathName);
if (pv->lpszFileName != NULL)
free(pv->lpszFileName);
}
void
FreeMAPIMessage(lpMapiMessage pv)
{
ULONG i;
if (!pv)
return;
if (pv->lpszSubject != NULL)
free(pv->lpszSubject);
if (pv->lpszNoteText)
free(pv->lpszNoteText);
if (pv->lpszMessageType)
free(pv->lpszMessageType);
if (pv->lpszDateReceived)
free(pv->lpszDateReceived);
if (pv->lpszConversationID)
free(pv->lpszConversationID);
if (pv->lpOriginator)
FreeMAPIRecipient(pv->lpOriginator);
for (i=0; i<pv->nRecipCount; i++)
{
if (&(pv->lpRecips[i]) != NULL)
{
FreeMAPIRecipient(&(pv->lpRecips[i]));
}
}
if (pv->lpRecips != NULL)
{
free(pv->lpRecips);
}
for (i=0; i<pv->nFileCount; i++)
{
if (&(pv->lpFiles[i]) != NULL)
{
FreeMAPIFile(&(pv->lpFiles[i]));
}
}
if (pv->lpFiles != NULL)
{
free(pv->lpFiles);
}
free(pv);
pv = NULL;
}
void
FreeMAPIRecipient(lpMapiRecipDesc pv)
{
if (!pv)
return;
if (pv->lpszName != NULL)
free(pv->lpszName);
if (pv->lpszAddress != NULL)
free(pv->lpszAddress);
if (pv->lpEntryID != NULL)
free(pv->lpEntryID);
}
//
// This routine will take an lpMapiMessage structure and "flatten" it into
// one contiguous chunk of memory that can be easily passed around. After this
// is done, "extract" routines will be written to get complicated string routines
// out of the chunk of memory at the end.
//
LPVOID
FlattenMAPIMessageStructure(lpMapiMessage msg, DWORD *totalSize)
{
MAPISendMailType *mailPtr;
LPSTR *strArray;
DWORD strCount = 0;
DWORD currentString = 0;
DWORD arrayBufSize = 0;
DWORD i;
*totalSize = 0;
if (!msg)
return(NULL);
//
// Allocate the initial structure to hold all of the mail info.
//
*totalSize = sizeof(MAPISendMailType);
mailPtr = (MAPISendMailType *) malloc(sizeof(MAPISendMailType));
if (!mailPtr)
return(NULL);
memset(mailPtr, 0, sizeof(MAPISendMailType));
//
// First, assign all of the easy numeric values...
//
mailPtr->MSG_flFlags = msg->flFlags; // unread,return receipt
mailPtr->MSG_nRecipCount = msg->nRecipCount; // Number of recipients
mailPtr->MSG_nFileCount = msg->nFileCount; // # of file attachments
if (msg->lpOriginator != NULL)
{
mailPtr->MSG_ORIG_ulRecipClass = msg->lpOriginator->ulRecipClass; // Recipient class - MAPI_TO, MAPI_CC, MAPI_BCC, MAPI_ORIG
}
//
// Now, figure out how many string pointers we need...
//
strCount = 4; // These are the 4 KNOWN strings up front for a message
strCount += 2; // This is for the originator name and address
strCount += msg->nRecipCount * 3; // Name, address & class (cc, bcc) for each recipient
strCount += msg->nFileCount * 2; // filename and display name for each attachment
//
// Now allocate a new string sequence...add one entry for NULL at the end
//
arrayBufSize = sizeof(LPSTR) * (strCount + 1);
#ifdef WIN16 // Check for max mem allocation...
if ((sizeof(MAPISendMailType) + arrayBufSize) > 64000)
{
free(mailPtr);
return NULL;
}
#endif
//
// Allocate a buffer for the string pointers and if this fails,
// cleanup and return.
//
strArray = (LPSTR *)malloc( (size_t) arrayBufSize);
if (!strArray)
{
free(mailPtr);
return NULL;
}
memset(strArray, 0, (size_t) arrayBufSize); // Set the array to NULL
strArray[currentString++] = CheckNullString(msg->lpszSubject); // Message Subject
strArray[currentString++] = CheckNullString(msg->lpszNoteText); // Message Text
strArray[currentString++] = CheckNullString(msg->lpszDateReceived); // in YYYY/MM/DD HH:MM format
strArray[currentString++] = CheckNullString(msg->lpszConversationID); // conversation thread ID
if (msg->lpOriginator)
{
strArray[currentString++] = CheckNullString(msg->lpOriginator[0].lpszName);
strArray[currentString++] = CheckNullString(msg->lpOriginator[0].lpszAddress);
}
else
{
strArray[currentString++] = CheckNullString(NULL);
strArray[currentString++] = CheckNullString(NULL);
}
//
// Assign pointers for the Name and address of each recipient
//
LPSTR toString = "1";
LPSTR ccString = "2";
LPSTR bccString = "3";
for (i=0; i<msg->nRecipCount; i++)
{
// rhp - need message class
if (msg->lpRecips[i].ulRecipClass == MAPI_BCC)
strArray[currentString++] = CheckNullString(bccString);
else if (msg->lpRecips[i].ulRecipClass == MAPI_CC)
strArray[currentString++] = CheckNullString(ccString);
else
strArray[currentString++] = CheckNullString(toString);
strArray[currentString++] = CheckNullString(msg->lpRecips[i].lpszName);
strArray[currentString++] = CheckNullString(msg->lpRecips[i].lpszAddress);
}
BYTE szNewFileName[_MAX_PATH];
for (i=0; i<msg->nFileCount; i++)
{
char *namePtr;
// have to copy/create temp files here of office won't work...
if (
(msg->lpFiles[i].lpszFileName != NULL) &&
(*msg->lpFiles[i].lpszFileName != '\0')
)
{
namePtr = (char *)msg->lpFiles[i].lpszFileName;
}
else
{
namePtr = (char *)msg->lpFiles[i].lpszPathName;
}
if (GetTempMailNameWithExtension((char *)szNewFileName, namePtr) == 0)
{
free(strArray);
free(mailPtr);
return NULL;
}
if (!XP_CopyFile((char *)msg->lpFiles[i].lpszPathName, (char *)szNewFileName, TRUE))
{
free(strArray);
free(mailPtr);
return NULL;
}
strArray[currentString++] = CheckNullString((char *)szNewFileName);
strArray[currentString++] = CheckNullString(msg->lpFiles[i].lpszFileName);
AddTempFile((LPSTR) szNewFileName);
// strArray[currentString++] = CheckNullString(msg->lpFiles[i].lpszPathName);
// strArray[currentString++] = CheckNullString(msg->lpFiles[i].lpszFileName);
}
if (currentString != strCount)
{
TRACE("MAPI PROBLEM!!!!!! FlattenMAPIMessageStructure() currentString != strCount\n");
}
strArray[strCount] = NULL; // terminate at the end
NSstringSeq strSeq = NSStrSeqNew(strArray);
if (!strSeq)
{
free(strArray);
free(mailPtr);
return NULL;
}
//
// Now we need to copy the structure into a big, contiguous chunk of memory
//
LONG totalArraySize = NSStrSeqSize(strSeq);
LONG totalMemSize = sizeof(MAPISendMailType) + totalArraySize;
#ifdef WIN16
if (totalMemSize > 64000)
{
free(strArray);
NSStrSeqDelete(strSeq);
free(mailPtr);
return NULL;
}
#endif
MAPISendMailType *newMailPtr = (MAPISendMailType *)malloc((size_t)totalMemSize);
if (!newMailPtr)
{
free(strArray);
NSStrSeqDelete(strSeq);
free(mailPtr);
return NULL;
}
memset(newMailPtr, 0, (size_t) totalMemSize);
//
// Finally do the copy...
//
memcpy(newMailPtr, mailPtr, sizeof(MAPISendMailType));
memcpy(newMailPtr->dataBuf, strSeq, (size_t) totalArraySize);
*totalSize = totalMemSize;
//
// Cleanup and scram...
//
if (strArray)
free(strArray);
if (strSeq)
NSStrSeqDelete(strSeq);
if (mailPtr)
free(mailPtr);
return(newMailPtr);
}

View File

@@ -0,0 +1,76 @@
/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
/* ***** BEGIN LICENSE BLOCK *****
* Version: NPL 1.1/GPL 2.0/LGPL 2.1
*
* The contents of this file are subject to the Netscape Public License
* Version 1.1 (the "License"); you may not use this file except in
* compliance with the License. You may obtain a copy of the License at
* http://www.mozilla.org/NPL/
*
* Software distributed under the License is distributed on an "AS IS" basis,
* WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
* for the specific language governing rights and limitations under the
* License.
*
* The Original Code is mozilla.org code.
*
* The Initial Developer of the Original Code is
* Netscape Communications Corporation.
* Portions created by the Initial Developer are Copyright (C) 1998
* the Initial Developer. All Rights Reserved.
*
* Contributor(s):
*
* Alternatively, the contents of this file may be used under the terms of
* either the GNU General Public License Version 2 or later (the "GPL"), or
* the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
* in which case the provisions of the GPL or the LGPL are applicable instead
* of those above. If you wish to allow use of your version of this file only
* under the terms of either the GPL or the LGPL, and not to allow others to
* use your version of this file under the terms of the NPL, indicate your
* decision by deleting the provisions above and replace them with the notice
* and other provisions required by the GPL or the LGPL. If you do not delete
* the provisions above, a recipient may use your version of this file under
* the terms of any one of the NPL, the GPL or the LGPL.
*
* ***** END LICENSE BLOCK ***** */
#ifndef __MY_MEM_HPP__
#define __MY_MEM_HPP__
#ifndef MAPI_OLE // Because MSFT doesn't do this for us :-(
#include <mapi.h>
#endif
//
// Needed for turning NULL's into ""'s for string sequence routines...
//
LPSTR CheckNullString(LPSTR inStr);
//
// Memory allocation functions...
//
//
// This will free an lpMapiMessage structure allocated by this DLL
//
void FreeMAPIMessage(lpMapiMessage pv);
//
// This will free an lpMapiRecipDesc structure allocated by this DLL
//
void FreeMAPIRecipient(lpMapiRecipDesc pv);
//
// Frees a mapi file object...
//
void FreeMAPIFile(lpMapiFileDesc pv);
//
// This routine will take an lpMapiMessage structure and "flatten" it into
// one contiguous chunk of memory that can be easily passed around.
//
LPVOID FlattenMAPIMessageStructure(lpMapiMessage msg, DWORD *totalSize);
#endif // __MY_MEM_HPP__

View File

@@ -0,0 +1,899 @@
/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
/* ***** BEGIN LICENSE BLOCK *****
* Version: NPL 1.1/GPL 2.0/LGPL 2.1
*
* The contents of this file are subject to the Netscape Public License
* Version 1.1 (the "License"); you may not use this file except in
* compliance with the License. You may obtain a copy of the License at
* http://www.mozilla.org/NPL/
*
* Software distributed under the License is distributed on an "AS IS" basis,
* WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
* for the specific language governing rights and limitations under the
* License.
*
* The Original Code is mozilla.org code.
*
* The Initial Developer of the Original Code is
* Netscape Communications Corporation.
* Portions created by the Initial Developer are Copyright (C) 1998
* the Initial Developer. All Rights Reserved.
*
* Contributor(s):
*
* Alternatively, the contents of this file may be used under the terms of
* either the GNU General Public License Version 2 or later (the "GPL"), or
* the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
* in which case the provisions of the GPL or the LGPL are applicable instead
* of those above. If you wish to allow use of your version of this file only
* under the terms of either the GPL or the LGPL, and not to allow others to
* use your version of this file under the terms of the NPL, indicate your
* decision by deleting the provisions above and replace them with the notice
* and other provisions required by the GPL or the LGPL. If you do not delete
* the provisions above, a recipient may use your version of this file under
* the terms of any one of the NPL, the GPL or the LGPL.
*
* ***** END LICENSE BLOCK ***** */
//
// Various utils needed for the MAPI functions
// Written by: Rich Pizzarro (rhp@netscape.com)
// November 1997
//
#include <windows.h>
#include <time.h>
#include <sys/stat.h>
#include <io.h>
#include "xpapi.h"
#include "trace.h"
#include "mapiipc.h"
#include "mapiutl.h"
//
// Global variables
//
BOOL gLoggingEnabled = FALSE;
void
SetLoggingEnabled(BOOL val)
{
gLoggingEnabled = val;
}
// Log File
void
LogString(LPCSTR pStr1)
{
// Off of the declaration line...
LPCSTR pStr2 = NULL;
BOOL useStr1 = TRUE;
if (gLoggingEnabled)
{
char tempPath[_MAX_PATH] = "";
if (getenv("TEMP"))
{
lstrcpy((LPSTR) tempPath, getenv("TEMP")); // environmental variable
}
int len = lstrlen(tempPath);
if ((len > 1) && tempPath[len - 1] != '\\')
{
lstrcat(tempPath, "\\");
}
lstrcat(tempPath, szMapiLog);
HFILE hFile = _lopen(tempPath, OF_WRITE);
if (hFile == HFILE_ERROR)
{
hFile = _lcreat(tempPath, 0);
}
if (hFile != HFILE_ERROR)
{
_llseek(hFile, 0, SEEK_END); // seek to the end of the file
LPCSTR pTemp = useStr1 ? pStr1 : pStr2;
_lwrite(hFile, pTemp, lstrlen(pTemp));
_lclose(hFile);
}
}
}
//
// Find Communicator and return an HWND, if not, start Communicator,
// then find an HWND
//
HWND
GetCommunicatorIPCWindow(void)
{
HWND hWnd = NULL;
DWORD timeCount = 0;
BOOL launchTry = FALSE;
//
// This will wait for 10 seconds before giving up and failing
//
while ((hWnd == NULL) && (timeCount < 20))
{
if ((hWnd = FindWindow("AfxFrameOrView", NULL)) && !FindWindow("aHiddenFrameClass", NULL))
return(hWnd);
else if ((hWnd = FindWindow("aHiddenFrameClass", NULL)))
return(hWnd);
if (!launchTry)
{
char szPath[_MAX_PATH] = "";
DWORD nMAPIERROR;
if ((nMAPIERROR = XP_GetInstallLocation(szPath, _MAX_PATH)) != SUCCESS_SUCCESS)
{
return(NULL);
}
WORD nReturn = XP_CallProcess(szPath, " -MAPICLIENT");
launchTry = TRUE;
}
//
// Pause for 1/2 a second and try to connect again...
//
#ifdef WIN32
Sleep(500);
#else
Yield();
#endif
timeCount++;
}
return(hWnd);
}
void
BuildMemName(LPSTR name, ULONG winSeed)
{
static DWORD id = 0;
if (id == 0)
{
// Seed the random-number generator with current time so that
// the numbers will be different every time we run.
srand( (unsigned)time( NULL ) );
id = rand();
}
wsprintf(name, "MAPI_IPC_SMEM-%d", (winSeed + id++));
TRACE("Shared Memory Name = [%s]\n", name);
}
DWORD
ValidateFile(LPCSTR szFile)
{
struct _stat buf;
int result;
result = _stat( szFile, &buf );
if (result != 0)
return(1);
if (!(buf.st_mode & S_IREAD))
return(2);
return(0);
}
//
// return of zero is ok
// 1 = MAPI_E_ATTACHMENT_NOT_FOUND
// 2 = MAPI_E_ATTACHMENT_OPEN_FAILURE
//
DWORD
SanityCheckAttachmentFiles(lpMapiMessage lpMessage)
{
ULONG i;
DWORD rc;
for (i=0; i<lpMessage->nFileCount; i++)
{
if ((rc = ValidateFile(lpMessage->lpFiles[i].lpszPathName)) != 0)
{
return(rc);
}
}
return(0);
}
DWORD
GetFileCount(LPSTR pFiles, LPSTR delimChar)
{
DWORD count = 1;
if ((!pFiles) || (!*pFiles))
return(0);
for (DWORD i=0; i<strlen(pFiles); i++)
{
if (pFiles[i] == delimChar[0])
{
++count;
}
}
return(count);
}
//
// Extract a filename from a string
// Return TRUE if file found, else FALSE
//
BOOL
ExtractFile(LPSTR pFiles, LPSTR delimChar, DWORD fIndex, LPSTR fName)
{
LPSTR ptr = pFiles;
DWORD loc;
DWORD count = 0;
if ((!pFiles) || (!*pFiles))
return(0);
// Get to the fIndex'th entry
for (loc=0; loc<strlen(pFiles); loc++)
{
if (count == fIndex)
break;
if (pFiles[loc] == delimChar[0])
count++;
}
if (loc >= strlen(pFiles)) // Got to the end of string!
return(FALSE);
lstrcpy(fName, (LPSTR)pFiles + loc);
//
// Truncate at 2nd delimiter
//
for (DWORD i=0; i<strlen(fName); i++)
{
if (fName[i] == delimChar[0])
{
fName[i] = '\0';
break;
}
}
return(TRUE);
}
ULONG
GetFileSize(LPSTR fName)
{
struct _stat buf;
int result;
result = _stat( fName, &buf );
if (result != 0)
return(0);
return(buf.st_size);
}
LPVOID
LoadBlobToMemory(LPSTR fName)
{
UCHAR *ptr = NULL;
ULONG bufSize = GetFileSize(fName);
if (bufSize == 0)
{
_unlink(fName);
return(NULL);
}
ptr = (UCHAR *)malloc( (size_t) bufSize);
if (!ptr)
{
_unlink(fName);
return(NULL);
}
HFILE hFile = _lopen(fName, OF_READ);
if (hFile == HFILE_ERROR)
{
_unlink(fName);
free(ptr);
return(NULL);
}
UINT numRead = _lread(hFile, ptr, (size_t) bufSize);
_lclose(hFile);
if (numRead != bufSize)
{
_unlink(fName);
free(ptr);
return(NULL);
}
_unlink(fName);
return(ptr);
}
LONG
WriteMemoryBufferToDisk(LPSTR fName, LONG bufSize, LPSTR buf)
{
if (!buf)
{
return(-1);
}
HFILE hFile = _lcreat(fName, 0);
if (hFile == HFILE_ERROR)
{
return(-1);
}
LONG writeCount = _lwrite(hFile, buf, (size_t) bufSize);
_lclose(hFile);
if (writeCount != bufSize)
{
_unlink(fName);
return(-1);
}
return(0);
}
LPSTR
GetTheTempDirectoryOnTheSystem(void)
{
static UCHAR retPath[_MAX_PATH];
if (getenv("TEMP"))
{
lstrcpy((LPSTR) retPath, getenv("TEMP")); // environmental variable
}
else if (getenv("TMP"))
{
lstrcpy((LPSTR) retPath, getenv("TMP")); // How about this environmental variable?
}
else
{
GetWindowsDirectory((LPSTR) retPath, sizeof(retPath));
}
return((LPSTR) &(retPath[0]));
}
#ifdef WIN16
int WINAPI EXPORT ISGetTempFileName(LPCSTR a_pDummyPath, LPCSTR a_pPrefix, UINT a_uUnique, LPSTR a_pResultName)
{
#ifdef GetTempFileName // we need the real thing comming up next...
#undef GetTempFileName
#endif
return GetTempFileName(0, a_pPrefix, a_uUnique, a_pResultName);
}
#endif
LONG
GetTempAttachmentName(LPSTR fName)
{
UINT res;
static UINT uUnique = 1;
if (!fName)
return(-1);
LPSTR szTempPath = GetTheTempDirectoryOnTheSystem();
TRYAGAIN:
#ifdef WIN32
res = GetTempFileName(szTempPath, "MAPI", uUnique++, fName);
#else
res = ISGetTempFileName(szTempPath, "MAPI", uUnique++, fName);
#endif
if (ValidateFile(fName) != 1)
{
if (uUnique < 32000)
{
goto TRYAGAIN;
}
else
{
return(-1);
}
}
return 0;
}
// RICHIE - strip all of the HTML stuff out of the message...
int
CheckForInlineHTML(char *noteBody, DWORD len, DWORD *curPos, char *newBody, DWORD *realLen)
{
LPSTR tags[] = {"&nbsp;", "&lt;", "&amp;", NULL};
UCHAR tagsSubst[] = {' ', '<', '&', NULL};
int x = 0;
while (tags[x])
{
// should we check for first tag
if ( (*curPos+strlen(tags[x])) < len)
{
if (strncmp(tags[x], noteBody, strlen(tags[x])) == 0)
{
*curPos += strlen(tags[x]) - 1;
newBody[*realLen] = tagsSubst[x];
*realLen += 1;
return(-1);
}
}
++x;
}
return(0);
}
//
// RICHIE - This is also temporary fix for now...
//
LPSTR
StripSignedMessage(LPSTR noteText, DWORD totalCR)
{
char *newBuf;
LPSTR startTag = "<HTML>";
LPSTR endTag = "/HTML>";
DWORD i;
DWORD realLen = 0;
DWORD startPos = 0;
DWORD len = strlen(noteText);;
// create a new buffer...
newBuf = (char *) malloc((size_t)(len + totalCR));
if (!newBuf)
return(noteText);
newBuf[0] = '\0';
// First, find the start of the HTML for the message...
for (i=0; i<len; i++)
{
// should we check for first tag
if ( (i+strlen(startTag)) < len)
{
if (strncmp(startTag, (noteText + i), strlen(startTag)) == 0)
{
startPos = i + strlen(startTag);
break;
}
}
}
// Didn't find any HTML start tag
if (i == len)
return(noteText);
BOOL inHTML = FALSE;
BOOL firstChar = FALSE;
for (i=startPos; i<len; i++)
{
char *ptr = (noteText + i);
if ( ((*ptr == 0x0D) || (*ptr == 0x20)) && (!firstChar) )
continue;
else
firstChar = TRUE;
// First, check for the end /HTML> tag
if ( (i+strlen(endTag)) < len)
{
if (strncmp(endTag, ptr, strlen(endTag)) == 0)
{
break;
}
}
// If we are in HTML, check for a ">"...
if (inHTML)
{
if (*ptr == '>')
{
inHTML = FALSE;
}
continue;
}
// Check for NEW HTML...
if (*ptr == '<')
{
inHTML = TRUE;
continue;
}
if (CheckForInlineHTML(ptr, len, &i, newBuf, &realLen))
continue;
newBuf[realLen++] = *ptr;
// Tack on a line feed if we hit a CR...
if ( *ptr == 0x0D )
{
newBuf[realLen++] = 0x0A;
}
}
// terminate the buffer - reallocate and move on...
newBuf[realLen++] = '\0';
newBuf = (LPSTR) realloc(newBuf, (size_t) realLen);
// check if the realloc worked and if so, free old memory and
// return...if not, just return the original buffer
if (!newBuf)
{
return(noteText);
}
else
{
free(noteText);
return(newBuf);
}
}
//
// RICHIE - this is a temporary fix for now to get rid of
// html stuff within the text of a message - if there was a
// valid noteText buffer coming into this call, we need to
// free it on the way out.
//
LPSTR
StripHTML(LPSTR noteText)
{
char *newBuf;
LPSTR signTag = "This is a cryptographically signed message in MIME format.";
LPSTR mimeTag = "This is a multi-part message in MIME format.";
DWORD i;
DWORD realLen = 0;
DWORD totalCR = 0;
// do sanity checking...
if ((!noteText) || (!(*noteText)))
return(noteText);
// more sanity checking...
DWORD len = strlen(noteText) + 1;
if (len <= 0)
return(noteText);
// Get the number of CR's in this message and add room for
// the LF's
for (i=0; i<len; i++)
{
if ( (*(noteText + i)) == 0x0D )
++totalCR;
}
// This is a check for a signed message in the start of a message
// check for sign line...
if ( strlen(signTag) < len)
{
if (
(strncmp(signTag, noteText, strlen(signTag)) == 0) ||
(strncmp(mimeTag, noteText, strlen(mimeTag)) == 0)
)
{
return( StripSignedMessage(noteText, totalCR) );
}
}
// create a new buffer...
newBuf = (char *) malloc((size_t)(len + totalCR));
if (!newBuf)
return(noteText);
newBuf[0] = '\0';
BOOL firstChar = FALSE;
// Now do the translation for the body of the note...
for (i=0; i<len; i++)
{
char *ptr = (noteText + i);
if ( ((*ptr == 0x0D) || (*ptr == 0x20)) && (!firstChar) )
continue;
else
firstChar = TRUE;
if (CheckForInlineHTML(ptr, len, &i, newBuf, &realLen))
continue;
newBuf[realLen++] = *ptr;
if ( *ptr == 0x0D )
{
newBuf[realLen++] = 0x0A;
}
}
// terminate the buffer - reallocate and move on...
newBuf[realLen++] = '\0';
newBuf = (LPSTR) realloc(newBuf, (size_t) realLen);
// check if the realloc worked and if so, free old memory and
// return...if not, just return the original buffer
if (!newBuf)
{
return(noteText);
}
else
{
free(noteText);
return(newBuf);
}
}
#ifdef WIN16
void
GetWin16TempName(LPSTR realFileName, LPSTR tempPath,
LPSTR szTempFileName, UINT uUnique)
{
char *dotPtr = strrchr(realFileName, '.');
if (dotPtr != NULL)
{
*dotPtr = '\0';
}
int nameLen = lstrlen(realFileName);
if (dotPtr != NULL)
{
*dotPtr = '.';
}
if (nameLen <= 7)
{
wsprintf(szTempFileName, "%s\\%d%s", tempPath, uUnique, realFileName);
}
else
{
wsprintf(szTempFileName, "%s\\%d%s", tempPath, uUnique, (realFileName + 1));
}
}
#endif
#define MAXTRY 9999 // How many times do we try..
UINT
GetTempMailNameWithExtension(LPSTR szTempFileName,
LPSTR origName)
{
UINT res = 1;
UINT uUnique = 0;
char *szTempPath = GetTheTempDirectoryOnTheSystem();
char *tmpPtr;
char *realFileName = NULL;
if ( (origName != NULL) && (*origName != '\0') )
{
tmpPtr = origName;
}
else
{
tmpPtr = szTempFileName;
}
realFileName = strrchr(tmpPtr, '\\');
if (!realFileName)
realFileName = tmpPtr;
else
realFileName++;
TRYAGAIN:
#ifdef WIN32
if (uUnique == 0)
{
wsprintf(szTempFileName, "%s\\%s", szTempPath, realFileName);
}
else
{
wsprintf(szTempFileName, "%s\\%d_%s",
szTempPath, uUnique, realFileName);
}
#else // WIN16
if ( (uUnique == 0) && (strlen(realFileName) <= 12) )
{
wsprintf(szTempFileName, "%s\\%s", szTempPath, realFileName);
}
else
{
if (uUnique < 10)
{
GetWin16TempName(realFileName, szTempPath, szTempFileName, uUnique);
}
else
{
res = ISGetTempFileName(szTempPath, "ns", uUnique++, szTempFileName);
}
// Now add the correct extension...
char *origExt = strrchr(realFileName, '.');
if (origExt != NULL)
{
char *tmpExt = strrchr(szTempFileName, '.');
if (tmpExt != NULL)
{
origExt++;
tmpExt++;
while ( ((tmpExt) && (origExt)) && (*origExt != '\0') )
{
*tmpExt = *origExt;
tmpExt++;
origExt++;
}
*tmpExt = '\0';
}
}
}
#endif
if ( (ValidateFile(szTempFileName) != 1) && (uUnique < MAXTRY) )
{
uUnique++;
if (uUnique >= MAXTRY)
return(1);
goto TRYAGAIN;
}
return res;
}
#define kMaxTempFiles 10
#define kMaxListLength (10 * _MAX_PATH)
void GetTempFiles(LPSTR pBuf, int lenBuf)
{
if (!GetConfigInfoStr(szMapiSection, szTempFiles, pBuf, lenBuf, HKEY_ROOT))
{
*pBuf = 0;
}
}
void WriteTempFiles(LPSTR pBuf)
{
SetConfigInfoStr(szMapiSection, szTempFiles, pBuf, HKEY_ROOT);
}
void AddTempFile(LPCSTR pFileName)
{
if ( (!pFileName) || (pFileName[0] == '\0') )
return;
char *files = (char *)malloc(kMaxListLength);
if (!files)
return;
GetTempFiles(files, kMaxListLength);
if ((lstrlen(files) + lstrlen(pFileName) + 2) >= kMaxListLength)
{
free(files);
return;
}
if (lstrlen(files) != 0)
{
lstrcat(files, ";");
}
lstrcat(files, pFileName);
WriteTempFiles(files);
free(files);
}
void DeleteFirstTempFile(LPSTR pFiles)
{
if (!*pFiles)
return;
LPSTR pTemp = strchr(pFiles, ';');
if (pTemp)
{
*pTemp = 0;
}
//#ifndef _DEBUG
_unlink(pFiles);
//#endif
if (pTemp)
{
memmove(pFiles, pTemp + 1, lstrlen(pTemp + 1) + 1);
}
else
{
*pFiles = 0;
}
}
void
RemoveAllTempFiles(void)
{
char *files = (char *)malloc(kMaxListLength);
if (!files)
return;
GetTempFiles(files, kMaxListLength);
while (*files)
{
DeleteFirstTempFile(files);
}
WriteTempFiles(files);
free(files);
}
void CheckAgeTempFiles(void)
{
char *files = (char *)malloc(kMaxListLength);
if (!files)
return;
GetTempFiles(files, kMaxListLength);
int i = 0;
LPSTR pTemp = files;
while (TRUE)
{
pTemp = strchr(pTemp, ';');
if (!pTemp)
break;
++pTemp;
++i;
}
if (i >= 10)
{
DeleteFirstTempFile(files);
WriteTempFiles(files);
}
free(files);
}
void
CleanupMAPITempFiles(void)
{
if (Is_16_OR_32_BIT_CommunitorRunning() == 0)
{
RemoveAllTempFiles(); // if Communicator not running, clean up all the temp files
}
else
{
CheckAgeTempFiles();
}
}
void *
CleanMalloc(size_t mallocSize)
{
void *ptr = malloc(mallocSize);
if (!ptr)
return(NULL);
memset(ptr, 0, mallocSize);
return(ptr);
}
void
SafeFree(void *ptr)
{
if (!ptr)
return;
free(ptr);
ptr = NULL;
}

View File

@@ -0,0 +1,89 @@
/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
/* ***** BEGIN LICENSE BLOCK *****
* Version: NPL 1.1/GPL 2.0/LGPL 2.1
*
* The contents of this file are subject to the Netscape Public License
* Version 1.1 (the "License"); you may not use this file except in
* compliance with the License. You may obtain a copy of the License at
* http://www.mozilla.org/NPL/
*
* Software distributed under the License is distributed on an "AS IS" basis,
* WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
* for the specific language governing rights and limitations under the
* License.
*
* The Original Code is mozilla.org code.
*
* The Initial Developer of the Original Code is
* Netscape Communications Corporation.
* Portions created by the Initial Developer are Copyright (C) 1998
* the Initial Developer. All Rights Reserved.
*
* Contributor(s):
*
* Alternatively, the contents of this file may be used under the terms of
* either the GNU General Public License Version 2 or later (the "GPL"), or
* the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
* in which case the provisions of the GPL or the LGPL are applicable instead
* of those above. If you wish to allow use of your version of this file only
* under the terms of either the GPL or the LGPL, and not to allow others to
* use your version of this file under the terms of the NPL, indicate your
* decision by deleting the provisions above and replace them with the notice
* and other provisions required by the GPL or the LGPL. If you do not delete
* the provisions above, a recipient may use your version of this file under
* the terms of any one of the NPL, the GPL or the LGPL.
*
* ***** END LICENSE BLOCK ***** */
#ifndef __UTILS_
#define __UTILS_
#ifdef __cplusplus
extern "C"
{
#endif
#ifndef MAPI_OLE // Because MSFT doesn't do this for us :-(
#include <mapi.h>
#endif
//
// Utility functions...
//
void SetLoggingEnabled(BOOL val); // Set a logging enabled flag
void LogString(LPCSTR pStr1); // Log a string to a file...
void BuildMemName(LPSTR name, ULONG winSeed); // Shared memory name
HWND GetCommunicatorIPCWindow(void); // Get the IPC window we will use...
DWORD SanityCheckAttachmentFiles(lpMapiMessage lpMessage); // Check attachments
DWORD ValidateFile(LPCSTR szFile); // Is this a valid file - 0=Yes 1 = NOT_FOUND 2 = OPEN_FAILURE
DWORD GetFileCount(LPSTR pFiles, LPSTR delimChar); // Get File count from string of file1;file2, etc..
BOOL ExtractFile(LPSTR pFiles, LPSTR delimChar, DWORD fIndex, LPSTR fName); // Extract a filename from a string
LPVOID LoadBlobToMemory(LPSTR fName); // Load the blob into memory!
LONG GetTempAttachmentName(LPSTR fName); // Get a temp file name and put it in fName
UINT GetTempMailNameWithExtension(LPSTR szTempFileName, LPSTR origName);
void CleanupMAPITempFiles(void);
void AddTempFile(LPCSTR pFileName);
void *CleanMalloc(size_t mallocSize);
void SafeFree(void *ptr);
//
// RICHIE - this is a temporary fix for now to get rid of
// html stuff within the text of a message - if there was a
// valid noteText buffer coming into this call, we need to
// free it on the way out.
//
LPSTR StripHTML(LPSTR noteText);
//
// Write a buffer to disk
// Return 0 on success -1 on failure
//
LONG WriteMemoryBufferToDisk(LPSTR fName, LONG bufSize, LPSTR buf);
#ifdef __cplusplus
}
#endif
#endif // __UTILS_

View File

@@ -0,0 +1,303 @@
/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
/* ***** BEGIN LICENSE BLOCK *****
* Version: NPL 1.1/GPL 2.0/LGPL 2.1
*
* The contents of this file are subject to the Netscape Public License
* Version 1.1 (the "License"); you may not use this file except in
* compliance with the License. You may obtain a copy of the License at
* http://www.mozilla.org/NPL/
*
* Software distributed under the License is distributed on an "AS IS" basis,
* WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
* for the specific language governing rights and limitations under the
* License.
*
* The Original Code is mozilla.org code.
*
* The Initial Developer of the Original Code is
* Netscape Communications Corporation.
* Portions created by the Initial Developer are Copyright (C) 1998
* the Initial Developer. All Rights Reserved.
*
* Contributor(s):
*
* Alternatively, the contents of this file may be used under the terms of
* either the GNU General Public License Version 2 or later (the "GPL"), or
* the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
* in which case the provisions of the GPL or the LGPL are applicable instead
* of those above. If you wish to allow use of your version of this file only
* under the terms of either the GPL or the LGPL, and not to allow others to
* use your version of this file under the terms of the NPL, indicate your
* decision by deleting the provisions above and replace them with the notice
* and other provisions required by the GPL or the LGPL. If you do not delete
* the provisions above, a recipient may use your version of this file under
* the terms of any one of the NPL, the GPL or the LGPL.
*
* ***** END LICENSE BLOCK ***** */
//
#ifndef PORT_H
#define PORT_H
#ifdef __cplusplus
extern "C" {
#endif
/*****************************************************************\
* *
* PORT.H *
* *
* Win16/Win32 portability stuff *
* *
* A.Sokolsky *
* 3.10.94 distilled into this header *
* *
\*****************************************************************/
/*
* calling conventions
*/
#include <assert.h>
#ifndef CDECL
#define CDECL __cdecl
#endif // CDECL
#ifndef PASCAL
#define PASCAL __pascal
#endif // PASCAL
#ifdef FASTCALL
#error FASTCALL defined
#endif // FASTCALL
#ifdef NDEBUG
#define FASTCALL __fastcall
#else
#define FASTCALL PASCAL
#endif // NDEBUG
#ifndef HWND2DWORD
# ifdef WIN32
# define HWND2DWORD(X_hWnd) ( (DWORD)(X_hWnd) )
# else // WIN16
# define HWND2DWORD(X_hWnd) ( (DWORD)MAKELONG(((WORD)(X_hWnd)), 0) )
# endif
#endif // HWND2DWORD
/*
* WIN16 - WIN32 compatibility stuff
*/
#ifdef WIN32
# define DLLEXPORT __declspec( dllexport )
# define EXPORT
# define LOADDS
# define HUGE
# ifndef FAR
# define FAR
# endif // FAR
# ifndef NEAR
# define NEAR
# endif // NEAR
# ifdef UNICODE
# define SIZEOF(x) (sizeof(x)/sizeof(WCHAR))
# else
# define SIZEOF(x) sizeof(x)
# endif
#else // !WIN32 == WIN16
# define DLLEXPORT
# define EXPORT __export
# define LOADDS __loadds
# define HUGE __huge
# ifndef FAR
# define FAR __far
# define NEAR __near
# endif // FAR
# define CONST const
# define SIZEOF(x) sizeof(x)
# define CHAR char
# define TCHAR char
# define WCHAR char
# ifndef LPTSTR
# define LPTSTR LPSTR
# endif
# ifndef LPCTSTR
# define LPCTSTR LPCSTR
# endif
# define UNREFERENCED_PARAMETER(x) x;
# ifndef TEXT
# define TEXT(x) x
# endif
# define GetWindowTextW GetWindowText
# define lstrcpyW lstrcpy
# define BN_DBLCLK BN_DOUBLECLICKED // ~~MRJ needed for custom control.
// ~~MRJ begin Win95 backward compat section
# define LPWSTR LPSTR
# define LPCWSTR LPCSTR
// button check state for WIN16
#ifndef BST_UNCHECKED
#define BST_UNCHECKED 0x0000
#endif
#ifndef BST_CHECKED
#define BST_CHECKED 0x0001
#endif
#ifndef WIN95_COMPAT
# define WIN95_COMPAT
#endif
// ~~MRJ end Win95 compat section.
// critical section API stubs
typedef DWORD CRITICAL_SECTION;
typedef CRITICAL_SECTION FAR * LPCRITICAL_SECTION;
#ifdef __cplusplus
inline void InitializeCriticalSection(LPCRITICAL_SECTION lpSection) {}
inline void DeleteCriticalSection(LPCRITICAL_SECTION lpSection) {}
inline void EnterCriticalSection(LPCRITICAL_SECTION lpSection) {}
inline void LeaveCriticalSection(LPCRITICAL_SECTION lpSection) {}
#endif // __cplusplus
// Added for nssock16 ---Neeti
#ifndef ZeroMemory
#include <memory.h>
#define ZeroMemory(PTR, SIZE) memset(PTR, 0, SIZE)
#endif // ZeroMemory
#endif // WIN16
/*
* unix - windows compatibility stuff
*/
typedef DWORD u_int32;
typedef WORD u_int16;
typedef BYTE u_int8;
#ifdef WIN32
typedef short int Bool16;
#else // WIN16
typedef BOOL Bool16;
#endif // WIN16
/*
* Cross Platform Compatibility
*/
#ifndef UNALIGNED
# ifdef _M_ALPHA
# define UNALIGNED __unaligned
# else // !_M_ALPHA
# define UNALIGNED
# endif // !_M_ALPHA
#endif // UNALIGNED
//
// RICHIE - for the Alpha port
//
#ifdef _M_ALPHA
# undef pascal
# undef PASCAL
# if (_MSC_VER >= 800) || defined(_STDCALL_SUPPORTED)
# define pascal __stdcall
# define PASCAL __stdcall
# else
# define PASCAL
# endif
#endif
/*
* Useful Types
*/
typedef char HUGE *HPSTR;
typedef const char HUGE *HPCSTR;
typedef unsigned char HUGE *HPBYTE;
typedef WORD HUGE *HPWORD;
typedef UINT FAR *LPUINT;
typedef BOOL (CALLBACK *USERABORTPROC)();
typedef BOOL (CALLBACK *PROGRESSPROC)(UINT uPos, UINT uRange);
typedef int INT; // ~~MRJ a function needed this defined.
typedef MINMAXINFO FAR *LPMINMAXINFO; // ~~MRJ
//
// stuff missing from windows.h
//
#ifndef MAKEWORD
#define MAKEWORD(low, high) ((WORD)(((BYTE)(low)) | (((WORD)((BYTE)(high))) << 8)))
#endif // MAKEWORD
#ifdef WIN32
# ifndef hmemcpy
# define hmemcpy memcpy
# endif // !defined(hmemcpy)
# define _fmemset memset
# include <malloc.h>
#ifdef __cplusplus
inline BOOL IsGDIObject(HGDIOBJ hObj) { return (hObj != 0); }
inline void *_halloc(long num, unsigned int size) { return malloc(num * size); }
inline void _hfree( void *memblock ) { free(memblock); }
/*
inline BOOL IsInstance(HINSTANCE hInst) {
# ifdef WIN32
return (hInst != 0);
# else // WIN16
return (hInst > HINSTANCE_ERROR);
# endif
}
*/
#endif // __cplusplus
WINUSERAPI HANDLE WINAPI LoadImageA(HINSTANCE, LPCSTR, UINT, int, int, UINT);
#endif // WIN32
#ifdef __cplusplus
inline BOOL IsInstance(HINSTANCE hInst) {
# ifdef WIN32
return (hInst != 0);
# else // WIN16
return (hInst > HINSTANCE_ERROR);
# endif
}
inline void SetWindowSmallIcon(HINSTANCE hInst, HWND hWnd, UINT uIconResourceId) {
#ifdef WIN32
# ifndef WM_SETICON
# define WM_SETICON 0x0080
# endif // WM_SETICON
# ifndef IMAGE_ICON
# define IMAGE_ICON 1
# endif
assert(IsWindow(hWnd));
HICON hIcon = (HICON)LoadImageA(hInst, MAKEINTRESOURCE(uIconResourceId), IMAGE_ICON,
16, 16, 0);
if(NULL != hIcon) {
SendMessage(hWnd, WM_SETICON, FALSE, (LPARAM)hIcon);
} else {
HICON hIcon = LoadIcon(hInst, MAKEINTRESOURCE(uIconResourceId));
assert(hIcon != 0);
SendMessage(hWnd, WM_SETICON, FALSE, (LPARAM)hIcon);
}
#endif // WIN32
}
#endif // __cplusplus
#ifdef __cplusplus
}
#endif /* __cplusplus */
#endif /* PORT_H */

View File

@@ -0,0 +1,54 @@
/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
/* ***** BEGIN LICENSE BLOCK *****
* Version: NPL 1.1/GPL 2.0/LGPL 2.1
*
* The contents of this file are subject to the Netscape Public License
* Version 1.1 (the "License"); you may not use this file except in
* compliance with the License. You may obtain a copy of the License at
* http://www.mozilla.org/NPL/
*
* Software distributed under the License is distributed on an "AS IS" basis,
* WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
* for the specific language governing rights and limitations under the
* License.
*
* The Original Code is mozilla.org code.
*
* The Initial Developer of the Original Code is
* Netscape Communications Corporation.
* Portions created by the Initial Developer are Copyright (C) 1998
* the Initial Developer. All Rights Reserved.
*
* Contributor(s):
*
* Alternatively, the contents of this file may be used under the terms of
* either the GNU General Public License Version 2 or later (the "GPL"), or
* the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
* in which case the provisions of the GPL or the LGPL are applicable instead
* of those above. If you wish to allow use of your version of this file only
* under the terms of either the GPL or the LGPL, and not to allow others to
* use your version of this file under the terms of the NPL, indicate your
* decision by deleting the provisions above and replace them with the notice
* and other provisions required by the GPL or the LGPL. If you do not delete
* the provisions above, a recipient may use your version of this file under
* the terms of any one of the NPL, the GPL or the LGPL.
*
* ***** END LICENSE BLOCK ***** */
//{{NO_DEPENDENCIES}}
// Microsoft Developer Studio generated include file.
// Used by mapi32.rc
//
#define ID_DIALOG_QAHOOK 101
#define ID_DIALOG_MAPI 101
#define ID_ICON_APP 102
// Next default values for new objects
//
#ifdef APSTUDIO_INVOKED
#ifndef APSTUDIO_READONLY_SYMBOLS
#define _APS_NEXT_RESOURCE_VALUE 103
#define _APS_NEXT_COMMAND_VALUE 40001
#define _APS_NEXT_CONTROL_VALUE 1000
#define _APS_NEXT_SYMED_VALUE 101
#endif
#endif

View File

@@ -0,0 +1,172 @@
/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
/* ***** BEGIN LICENSE BLOCK *****
* Version: NPL 1.1/GPL 2.0/LGPL 2.1
*
* The contents of this file are subject to the Netscape Public License
* Version 1.1 (the "License"); you may not use this file except in
* compliance with the License. You may obtain a copy of the License at
* http://www.mozilla.org/NPL/
*
* Software distributed under the License is distributed on an "AS IS" basis,
* WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
* for the specific language governing rights and limitations under the
* License.
*
* The Original Code is mozilla.org code.
*
* The Initial Developer of the Original Code is
* Netscape Communications Corporation.
* Portions created by the Initial Developer are Copyright (C) 1998
* the Initial Developer. All Rights Reserved.
*
* Contributor(s):
*
* Alternatively, the contents of this file may be used under the terms of
* either the GNU General Public License Version 2 or later (the "GPL"), or
* the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
* in which case the provisions of the GPL or the LGPL are applicable instead
* of those above. If you wish to allow use of your version of this file only
* under the terms of either the GPL or the LGPL, and not to allow others to
* use your version of this file under the terms of the NPL, indicate your
* decision by deleting the provisions above and replace them with the notice
* and other provisions required by the GPL or the LGPL. If you do not delete
* the provisions above, a recipient may use your version of this file under
* the terms of any one of the NPL, the GPL or the LGPL.
*
* ***** END LICENSE BLOCK ***** */
//
// smem.cpp - This deals with all shared memory functions needed for
// the MAPI component of Communicator
// Written by: Rich Pizzarro (rhp@netscape.com)
// November 1997
//
#include <windows.h>
#include <windowsx.h>
#include "mapismem.h"
#ifndef ZeroMemory
#include <memory.h>
#define ZeroMemory(PTR, SIZE) memset(PTR, 0, SIZE)
#endif // ZeroMemory
//
// *create new* shared memory chunk
// once this is created, use the pointer
// to the segment to to store data
// e.g.:
// lpString = "string for communicator";
// lstrcpy((LPSTR)pData->m_buf[0], lpString);
//
CSharedMem *
NSCreateSharedMemory(DWORD memSize, LPCTSTR memName, HANDLE *hSharedMemory)
{
#ifdef WIN32
BOOL bExistedBefore;
CSharedMem *pData;
LPCTSTR szObjectName = memName;
DWORD dwSize = sizeof(CSharedMem) + memSize;
*hSharedMemory = CreateFileMapping(
(HANDLE)0xFFFFFFFF,0,PAGE_READWRITE,0,dwSize,szObjectName);
if(*hSharedMemory == 0)
{
return NULL;
}
bExistedBefore = (GetLastError() == ERROR_ALREADY_EXISTS);
if(bExistedBefore)
{
return NULL;
}
pData = (CSharedMem *)MapViewOfFile(
*hSharedMemory, FILE_MAP_ALL_ACCESS, 0, 0, 0);
if(pData == NULL)
{
return NULL;
}
ZeroMemory(pData, dwSize);
pData->m_dwSize = memSize;
return pData;
#else
CSharedMem *sMemChunk = NULL;
DWORD dwSize = memSize = (sizeof(CSharedMem) + memSize);
if (sMemChunk != NULL)
return(sMemChunk);
sMemChunk = (CSharedMem *) GlobalAllocPtr(GMEM_MOVEABLE, dwSize);
ZeroMemory(sMemChunk, (size_t) dwSize);
sMemChunk->m_dwSize = dwSize; // Missing in Communicator code!
return(sMemChunk);
#endif // WIN32
}
//
// *open existing* shared memory chunk
// once you have the pointer to the new segment
// use this pointer to access data, e.g.:
//
CSharedMem *
NSOpenExistingSharedMemory(LPCTSTR memName, HANDLE *hSharedMemory)
{
#ifdef WIN32
CSharedMem *pData;
DWORD dwSize;
LPCTSTR szObjectName = memName;
*hSharedMemory = OpenFileMapping(
PAGE_READWRITE,FALSE,szObjectName);
if(*hSharedMemory == 0)
{
return NULL;
}
pData = (CSharedMem *)MapViewOfFile(
*hSharedMemory,FILE_MAP_ALL_ACCESS,0,0,0);
if(pData == NULL)
{
return NULL;
}
dwSize = pData->m_dwSize;
return pData;
#else
return(NULL); // In Win16, this is really meaningless...
#endif
}
//
// to close shared memory segment
//
void
NSCloseSharedMemory(CSharedMem *pData, HANDLE hSharedMemory)
{
#ifdef WIN32
if(pData != 0)
{
UnmapViewOfFile(pData);
pData = 0;
}
if(hSharedMemory != 0)
{
CloseHandle(hSharedMemory);
hSharedMemory = 0;
}
#else
if (pData != NULL)
{
GlobalFreePtr(pData);
pData = NULL;
}
#endif // WIN32
}

View File

@@ -0,0 +1,68 @@
/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
/* ***** BEGIN LICENSE BLOCK *****
* Version: NPL 1.1/GPL 2.0/LGPL 2.1
*
* The contents of this file are subject to the Netscape Public License
* Version 1.1 (the "License"); you may not use this file except in
* compliance with the License. You may obtain a copy of the License at
* http://www.mozilla.org/NPL/
*
* Software distributed under the License is distributed on an "AS IS" basis,
* WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
* for the specific language governing rights and limitations under the
* License.
*
* The Original Code is mozilla.org code.
*
* The Initial Developer of the Original Code is
* Netscape Communications Corporation.
* Portions created by the Initial Developer are Copyright (C) 1998
* the Initial Developer. All Rights Reserved.
*
* Contributor(s):
*
* Alternatively, the contents of this file may be used under the terms of
* either the GNU General Public License Version 2 or later (the "GPL"), or
* the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
* in which case the provisions of the GPL or the LGPL are applicable instead
* of those above. If you wish to allow use of your version of this file only
* under the terms of either the GPL or the LGPL, and not to allow others to
* use your version of this file under the terms of the NPL, indicate your
* decision by deleting the provisions above and replace them with the notice
* and other provisions required by the GPL or the LGPL. If you do not delete
* the provisions above, a recipient may use your version of this file under
* the terms of any one of the NPL, the GPL or the LGPL.
*
* ***** END LICENSE BLOCK ***** */
#include <windows.h>
#include <stdio.h>
#include <stdarg.h>
#include <tchar.h>
#include "trace.h"
#ifdef _DEBUG
#ifndef WIN16
void CDECL AfxTrace(LPCTSTR lpszFormat, ...)
#else
void CDECL AfxTrace(LPCSTR lpszFormat, ...)
#endif
{
va_list args;
va_start(args, lpszFormat);
int nBuf;
TCHAR szBuffer[512];
nBuf = _vstprintf(szBuffer, lpszFormat, args);
va_end(args);
OutputDebugString(szBuffer);
return;
}
BOOL AfxAssertFailedLine(LPCSTR lpszFileName, int nLine)
{
return TRUE;
}
#endif

View File

@@ -0,0 +1,81 @@
/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
/* ***** BEGIN LICENSE BLOCK *****
* Version: NPL 1.1/GPL 2.0/LGPL 2.1
*
* The contents of this file are subject to the Netscape Public License
* Version 1.1 (the "License"); you may not use this file except in
* compliance with the License. You may obtain a copy of the License at
* http://www.mozilla.org/NPL/
*
* Software distributed under the License is distributed on an "AS IS" basis,
* WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
* for the specific language governing rights and limitations under the
* License.
*
* The Original Code is mozilla.org code.
*
* The Initial Developer of the Original Code is
* Netscape Communications Corporation.
* Portions created by the Initial Developer are Copyright (C) 1998
* the Initial Developer. All Rights Reserved.
*
* Contributor(s):
*
* Alternatively, the contents of this file may be used under the terms of
* either the GNU General Public License Version 2 or later (the "GPL"), or
* the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
* in which case the provisions of the GPL or the LGPL are applicable instead
* of those above. If you wish to allow use of your version of this file only
* under the terms of either the GPL or the LGPL, and not to allow others to
* use your version of this file under the terms of the NPL, indicate your
* decision by deleting the provisions above and replace them with the notice
* and other provisions required by the GPL or the LGPL. If you do not delete
* the provisions above, a recipient may use your version of this file under
* the terms of any one of the NPL, the GPL or the LGPL.
*
* ***** END LICENSE BLOCK ***** */
#include <windows.h>
#ifdef _DEBUG
BOOL AfxAssertFailedLine(LPCSTR lpszFileName, int nLine);
#ifndef WIN16
void CDECL AfxTrace(LPCTSTR lpszFormat, ...);
#else
void CDECL AfxTrace(LPCSTR lpszFormat, ...);
#endif
#define TRACE ::AfxTrace
#define THIS_FILE __FILE__
#define ASSERT(f) \
do \
{ \
if (!(f) && AfxAssertFailedLine(THIS_FILE, __LINE__)) \
AfxDebugBreak(); \
} while (0) \
#define VERIFY(f) ASSERT(f)
#define TRACE_FN(name) LogFn __logFn(name)
class LogFn
{
public:
LogFn(LPCSTR pFnName) {m_pFnName = pFnName; TRACE("--%s: In--\n", pFnName);}
~LogFn() {TRACE("--%s: Out--\n", m_pFnName);}
private:
LPCSTR m_pFnName;
};
#else
// NDEBUG
#define ASSERT(f) ((void)0)
#define VERIFY(f) ((void)(f))
#define ASSERT_VALID(pOb) ((void)0)
#define DEBUG_ONLY(f) ((void)0)
#ifdef WIN32
inline void CDECL AfxTrace(LPCTSTR, ...) { }
#else
inline void CDECL AfxTrace(LPCSTR, ...) { }
#endif
#define TRACE 1 ? (void)0 : ::AfxTrace
#define TRACE_FN(name)
#endif // _DEBUG

View File

@@ -0,0 +1,347 @@
/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
/* ***** BEGIN LICENSE BLOCK *****
* Version: NPL 1.1/GPL 2.0/LGPL 2.1
*
* The contents of this file are subject to the Netscape Public License
* Version 1.1 (the "License"); you may not use this file except in
* compliance with the License. You may obtain a copy of the License at
* http://www.mozilla.org/NPL/
*
* Software distributed under the License is distributed on an "AS IS" basis,
* WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
* for the specific language governing rights and limitations under the
* License.
*
* The Original Code is mozilla.org code.
*
* The Initial Developer of the Original Code is
* Netscape Communications Corporation.
* Portions created by the Initial Developer are Copyright (C) 1998
* the Initial Developer. All Rights Reserved.
*
* Contributor(s):
*
* Alternatively, the contents of this file may be used under the terms of
* either the GNU General Public License Version 2 or later (the "GPL"), or
* the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
* in which case the provisions of the GPL or the LGPL are applicable instead
* of those above. If you wish to allow use of your version of this file only
* under the terms of either the GPL or the LGPL, and not to allow others to
* use your version of this file under the terms of the NPL, indicate your
* decision by deleting the provisions above and replace them with the notice
* and other provisions required by the GPL or the LGPL. If you do not delete
* the provisions above, a recipient may use your version of this file under
* the terms of any one of the NPL, the GPL or the LGPL.
*
* ***** END LICENSE BLOCK ***** */
//
// XPAPI.CPP
// API implementation file for mapi16.dll and mapi32.dll
// Written by: Rich Pizzarro (rhp@netscape.com)
// November 1997
//
#include <windows.h>
#include <stdio.h>
#include <stdarg.h>
#include "xpapi.h"
#include "mapiutl.h"
WORD LOAD_DS XP_CallProcess(LPCSTR pPath, LPCSTR pCmdLine)
{
WORD wReturn = 0;
#ifndef WIN16
STARTUPINFO startupInfo;
PROCESS_INFORMATION processInfo;
memset(&startupInfo, 0, sizeof(startupInfo));
startupInfo.cb = sizeof(startupInfo);
if (wReturn = CreateProcess(pPath, (LPTSTR)pCmdLine, NULL, NULL, FALSE, CREATE_DEFAULT_ERROR_MODE | CREATE_NEW_PROCESS_GROUP, NULL, NULL, &startupInfo, &processInfo))
{
WaitForInputIdle(processInfo.hProcess, 120000);
}
#else
// char szMsg[80];
char szExecute[512];
lstrcpy(szExecute, pPath);
lstrcat(szExecute, " ");
lstrcat(szExecute, pCmdLine);
wReturn = WinExec(szExecute,SW_SHOW);
if (wReturn < 32)
{
wReturn = 0;
}
#endif
return wReturn;
}
HKEY LOAD_DS RegOpenParent(LPCSTR pSection, HKEY hRootKey, REGSAM access)
{
HKEY hKey;
#ifndef WIN16
if (RegOpenKeyEx(hRootKey, pSection, 0, access, &hKey) != ERROR_SUCCESS)
{
return(NULL);
}
#else
if (RegOpenKey(hRootKey, pSection, &hKey) != ERROR_SUCCESS)
{
return(NULL);
}
#endif
return(hKey);
}
HKEY LOAD_DS RegCreateParent(LPCSTR pSection, HKEY hMasterKey)
{
HKEY hKey;
if (RegCreateKey(hMasterKey, pSection, &hKey) != ERROR_SUCCESS)
{
return(NULL);
}
return(hKey);
}
BOOL LOAD_DS GetConfigInfoStr(LPCSTR pSection, LPCSTR pKey, LPSTR pBuf, int lenBuf, HKEY hMasterKey)
{
HKEY hKey;
hKey = RegOpenParent(pSection, hMasterKey, KEY_QUERY_VALUE);
if (!hKey)
{
return(FALSE);
}
DWORD len = (DWORD)lenBuf;
#ifndef WIN16
BOOL retVal = (RegQueryValueEx(hKey, pKey, NULL, NULL, (LPBYTE)pBuf, &len) == ERROR_SUCCESS);
#else
BOOL retVal = (RegQueryValue(hKey, pKey, pBuf, (long far*)&len) == ERROR_SUCCESS);
#endif
RegCloseKey(hKey);
return(retVal);
}
BOOL LOAD_DS GetConfigInfoNum(LPCSTR pSection, LPCSTR pKey, DWORD* pVal, HKEY hMasterKey)
{
HKEY hKey;
hKey = RegOpenParent(pSection, hMasterKey, KEY_QUERY_VALUE);
if (!hKey)
{
return(FALSE);
}
DWORD len = sizeof(DWORD);
#ifndef WIN16
BOOL retVal = (RegQueryValueEx(hKey, pKey, NULL, NULL, (LPBYTE)pVal, &len) == ERROR_SUCCESS);
#else
BOOL retVal = (RegQueryValue(hKey, pKey, (char far*)pVal, (long far*)&len) == ERROR_SUCCESS);
#endif
RegCloseKey(hKey);
return(retVal);
}
BOOL LOAD_DS SetConfigInfoStr(LPCSTR pSection, LPCSTR pKey, LPSTR pStr, HKEY hMasterKey)
{
HKEY hKey;
hKey = RegCreateParent(pSection, hMasterKey);
if (!hKey)
{
return(FALSE);
}
#ifndef WIN16
BOOL retVal = (RegSetValueEx(hKey, pKey, 0, REG_SZ, (LPBYTE)pStr, lstrlen(pStr) + 1) == ERROR_SUCCESS);
#else
BOOL retVal = (RegSetValue(hKey, pKey, REG_SZ, pStr, lstrlen(pStr) + 1) == ERROR_SUCCESS);
#endif
RegCloseKey(hKey);
return(retVal);
}
BOOL LOAD_DS XP_GetInstallDirectory(LPCSTR pcurVersionSection, LPCSTR pInstallDirKey, LPSTR path, UINT nSize, HKEY hKey)
{
#ifdef WIN32
if (!GetConfigInfoStr(pcurVersionSection, pInstallDirKey, path, nSize, hKey))
{
return FALSE;
}
else
{
return TRUE;
}
#else
if ( 0 < GetPrivateProfileString(pcurVersionSection, pInstallDirKey,"ERROR", path, nSize, szNetscapeINI))
{
return TRUE;
}
else
{
return FALSE;
}
#endif
}
BOOL LOAD_DS XP_GetVersionInfoString(LPCSTR pNavigatorSection, LPCSTR pCurrentVersionKey, LPSTR pcurVersionStr, UINT nSize, HKEY hKey)
{
#ifdef WIN32
if (!GetConfigInfoStr(pNavigatorSection, pCurrentVersionKey, pcurVersionStr, nSize, HKEY_LOCAL_MACHINE))
{
return FALSE;
}
else
{
return TRUE;
}
#else
if ( 0 < GetPrivateProfileString(pNavigatorSection, pCurrentVersionKey,"ERROR", pcurVersionStr, nSize, szNetscapeINI))
{
return TRUE;
}
else
{
return FALSE;
}
#endif
}
DWORD LOAD_DS XP_GetInstallLocation(LPSTR pPath, UINT nSize)
{
char curVersionStr[256];
char curVersionSection[256];
if (!pPath)
return MAPI_E_LOGON_FAILURE;
#ifdef WIN32
if (!XP_GetVersionInfoString(szNavigatorSection, szCurrentVersionKey, curVersionStr,
sizeof(curVersionStr), HKEY_LOCAL_MACHINE))
{
return (MAPI_E_LOGON_FAILURE);
}
wsprintf(curVersionSection, szNavigatorCurVersionSection, curVersionStr);
if (!XP_GetInstallDirectory(curVersionSection, szInstallDirKey, pPath,
nSize, HKEY_LOCAL_MACHINE))
{
return (MAPI_E_ACCESS_DENIED);
}
lstrcat(pPath, "\\");
lstrcat(pPath, "Program\\netscape.exe");
return SUCCESS_SUCCESS;
#else
if (32 == Is_16_OR_32_BIT_CommunitorRunning())
{
if (!GetConfigInfoStr("snews\\shell\\open", "command", curVersionStr, sizeof(curVersionStr), HKEY_CLASSES_ROOT))
{
return (MAPI_E_ACCESS_DENIED);
}
else
{
char *pFind = strstr(curVersionStr,"-h");
if (pFind)
{
*pFind=0;
lstrcpy(pPath,curVersionStr);
}
else
{
return (MAPI_E_ACCESS_DENIED);
}
}
return SUCCESS_SUCCESS;
}
else //setup up to start navstart since we are a sixteen bit DLL.
{
if (!XP_GetVersionInfoString(szNavigatorSection, szCurrentVersionKey, curVersionStr, sizeof(curVersionStr), HKEY_LOCAL_MACHINE))
{
return (MAPI_E_LOGON_FAILURE);
}
wsprintf(curVersionSection, szNavigatorCurVersionSection, curVersionStr);
if (!XP_GetInstallDirectory(curVersionSection, szInstallDirKey, pPath,nSize, HKEY_LOCAL_MACHINE))
{
return (MAPI_E_ACCESS_DENIED);
}
lstrcat(pPath, "\\");
lstrcat(pPath, "NAVSTART.EXE");
return SUCCESS_SUCCESS;
}
#endif
}
int LOAD_DS Is_16_OR_32_BIT_CommunitorRunning()
{
if (FindWindow("AfxFrameOrView", NULL) && !FindWindow("aHiddenFrameClass", NULL))
return(16);
else if (FindWindow("aHiddenFrameClass", NULL))
return(32);
else
return 0;
}
// size of buffer to use for copying files.
#define COPYBUFSIZE 1024
#ifdef WIN16
BOOL Win16CopyFile(LPCSTR a_Src, LPCSTR a_Dest, BOOL a_bOverwrite)
{
OFSTRUCT ofSrc, ofDest;
HFILE hSrc, hDest;
BOOL bResult;
ofDest.cBytes = ofSrc.cBytes = sizeof(OFSTRUCT);
hDest = OpenFile(a_Dest, &ofDest, OF_EXIST);
if (hDest != HFILE_ERROR && !a_bOverwrite)
bResult = FALSE; // file exists but caller doesn't want file overwritten
else { // file either doesn't exist, or caller wants it overwritten.
hSrc = OpenFile(a_Src, &ofSrc, OF_READ);
hDest = OpenFile(a_Dest, &ofDest, OF_WRITE | OF_CREATE);
if (hSrc != HFILE_ERROR && hDest != HFILE_ERROR) {
unsigned char buf[COPYBUFSIZE];
UINT bufsize = COPYBUFSIZE;
UINT bytesread;
bResult = TRUE;
while (0 != (bytesread = _lread(hSrc, (LPVOID)buf, bufsize))) {
if ((bytesread == HFILE_ERROR) || // check for read error...
// and write error
(bytesread != _lwrite(hDest, (LPVOID)buf, bytesread))) {
bResult = FALSE; // could be out of diskspace
break;
}
}
}
else
bResult = FALSE;
if (hSrc != HFILE_ERROR)
_lclose(hSrc);
if (hDest != HFILE_ERROR)
_lclose(hDest);
}
return bResult;
}
#endif // WIN16
BOOL LOAD_DS
XP_CopyFile(LPCSTR lpExistingFile, LPCSTR lpNewFile, BOOL bFailifExist)
{
#ifdef WIN32
return CopyFile(lpExistingFile, lpNewFile, bFailifExist);
#else
return Win16CopyFile(lpExistingFile, lpNewFile, TRUE);
#endif
}

View File

@@ -0,0 +1,138 @@
/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
/* ***** BEGIN LICENSE BLOCK *****
* Version: NPL 1.1/GPL 2.0/LGPL 2.1
*
* The contents of this file are subject to the Netscape Public License
* Version 1.1 (the "License"); you may not use this file except in
* compliance with the License. You may obtain a copy of the License at
* http://www.mozilla.org/NPL/
*
* Software distributed under the License is distributed on an "AS IS" basis,
* WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
* for the specific language governing rights and limitations under the
* License.
*
* The Original Code is mozilla.org code.
*
* The Initial Developer of the Original Code is
* Netscape Communications Corporation.
* Portions created by the Initial Developer are Copyright (C) 1998
* the Initial Developer. All Rights Reserved.
*
* Contributor(s):
*
* Alternatively, the contents of this file may be used under the terms of
* either the GNU General Public License Version 2 or later (the "GPL"), or
* the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
* in which case the provisions of the GPL or the LGPL are applicable instead
* of those above. If you wish to allow use of your version of this file only
* under the terms of either the GPL or the LGPL, and not to allow others to
* use your version of this file under the terms of the NPL, indicate your
* decision by deleting the provisions above and replace them with the notice
* and other provisions required by the GPL or the LGPL. If you do not delete
* the provisions above, a recipient may use your version of this file under
* the terms of any one of the NPL, the GPL or the LGPL.
*
* ***** END LICENSE BLOCK ***** */
//
// Various routines for MAPI functions.
// Written by: Rich Pizzarro (rhp@netscape.com)
// November 1997
//
#ifndef __XPAPI_H
#define __XPAPI_H
#ifdef WIN16
#include <string.h>
#include <direct.h>
#include <shellapi.h>
#include <stdlib.h>
#else
#include <winreg.h>
#endif
#ifdef WIN16
extern "C" {
#ifndef MAPI_OLE // Because MSFT doesn't do this for us :-(
#include <mapi.h>
#endif
}
#else
//#include <mapi.h>
#endif
#ifdef WIN32
#define MAPI_IMPLEMENT(param) param PASCAL
#define LOAD_DS
#else
#define LOAD_DS __loadds
#define MAPI_IMPLEMENT(param) extern "C" param FAR PASCAL
#endif
#ifdef WIN16
#define _MAX_PATH 260 /* max. length of full pathname*/
#define MAPI_E_LOGON_FAILURE 3
#define MAPI_E_ACCESS_DENIED 6
#define INVALID_HANDLE_VALUE (HANDLE)-1
#define KEY_QUERY_VALUE 0x0001
#define HKEY_LOCAL_MACHINE ((HKEY)0x80000002)
#define HKEY_ROOT HKEY_CLASSES_ROOT
#else
#define HKEY_ROOT ((HKEY)0x80000002)
#endif
//
// registry keys
//
#ifdef WIN32
static char szNavigatorSection[] = "Software\\Netscape\\Netscape Navigator";
static char szNavigatorCurVersionSection[] = "Software\\Netscape\\Netscape Navigator\\%s\\Main";
static char szCurrentVersionKey[] = "CurrentVersion";
static char szInstallDirKey[] = "Install Directory";
static char szMapiSection[] = "Software\\Netscape\\Netscape Navigator\\MAPI";
static char szTempFiles[] = "TempFiles";
static char szMapiLog[] = "NSMAPI32.LOG";
#else
//32 bit key strings for trying to read the 32bit registry
static char szNavigatorSection32[] = "Software\\Netscape\\Netscape Navigator";
static char szNavigatorCurVersionSection32[] = "Software\\Netscape\\Netscape Navigator\\%s\\Main";
static char szMapiSection32[] = "Software\\Netscape\\Netscape Navigator\\MAPI";
// ini section and key strings
static char szNetscapeINI[] = "nscp.ini";
static char szNavigatorSection[] = "Netscape Navigator";
static char szNavigatorCurVersionSection[] = "Netscape Navigator-%s";
static char szCurrentVersionKey[] = "CurrentVersion";
static char szInstallDirKey[] = "Install Directory";
static char szMapiSection[] = "MAPI";
static char szTempFiles[] = "TempFiles";
static char szExeName[] = "NAVSTART.EXE";
static char szMapiLog[] = "NSMAPI16.LOG";
#endif
//Since REGSAM is just an ACCESS_MASK which is just a DWORD and it's not
//declared in win16 we'll make one hear for the purpose of keeping parameters
//the same even though the access rights don't get used for win16.
typedef DWORD REGSAM;
// XP declarations
int LOAD_DS Is_16_OR_32_BIT_CommunitorRunning();
WORD LOAD_DS XP_CallProcess(LPCSTR pPath, LPCSTR pCmdLine);
HKEY LOAD_DS RegOpenParent(LPCSTR pSection, HKEY hRootKey, REGSAM access);
HKEY LOAD_DS RegCreateParent(LPCSTR pSection, HKEY hMasterKey);
BOOL LOAD_DS GetConfigInfoStr(LPCSTR pSection, LPCSTR pKey, LPSTR pBuf, int lenBuf, HKEY hMasterKey);
BOOL LOAD_DS GetConfigInfoNum(LPCSTR pSection, LPCSTR pKey, DWORD* pVal, HKEY hMasterKey);
BOOL LOAD_DS SetConfigInfoStr(LPCSTR pSection, LPCSTR pKey, LPSTR pStr, HKEY hMasterKey);
BOOL LOAD_DS XP_GetInstallDirectory(LPCSTR pcurVersionSection, LPCSTR pInstallDirKey, LPSTR path, UINT nSize, HKEY hKey);
BOOL LOAD_DS XP_GetVersionInfoString(LPCSTR pNavigatorSection, LPCSTR pCurrentVersionKey, LPSTR pcurVersionStr, UINT nSize, HKEY hKey);
DWORD LOAD_DS XP_GetInstallLocation(LPSTR pPath, UINT nSize);
BOOL LOAD_DS XP_CopyFile(LPCSTR lpExistingFile, LPCSTR lpNewFile, BOOL bFailifExist);
#endif // __XPAPI_H

View File

@@ -0,0 +1,31 @@
#!nmake
#
# The contents of this file are subject to the Netscape Public
# License Version 1.1 (the "License"); you may not use this file
# except in compliance with the License. You may obtain a copy of
# the License at http://www.mozilla.org/NPL/
#
# Software distributed under the License is distributed on an "AS
# IS" basis, WITHOUT WARRANTY OF ANY KIND, either express or
# implied. See the License for the specific language governing
# rights and limitations under the License.
#
# The Original Code is mozilla.org code.
#
# The Initial Developer of the Original Code is Netscape
# Communications Corporation. Portions created by Netscape are
# Copyright (C) 1998 Netscape Communications Corporation. All
# Rights Reserved.
#
# Contributor(s):
DEPTH=..\..\..
MODULE=mime
EXPORTS = \
nscpmapi.h \
$(NULL)
include <$(DEPTH)\config\rules.mak>

View File

@@ -0,0 +1,351 @@
/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
/* ***** BEGIN LICENSE BLOCK *****
* Version: NPL 1.1/GPL 2.0/LGPL 2.1
*
* The contents of this file are subject to the Netscape Public License
* Version 1.1 (the "License"); you may not use this file except in
* compliance with the License. You may obtain a copy of the License at
* http://www.mozilla.org/NPL/
*
* Software distributed under the License is distributed on an "AS IS" basis,
* WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
* for the specific language governing rights and limitations under the
* License.
*
* The Original Code is mozilla.org code.
*
* The Initial Developer of the Original Code is
* Netscape Communications Corporation.
* Portions created by the Initial Developer are Copyright (C) 1998
* the Initial Developer. All Rights Reserved.
*
* Contributor(s):
*
* Alternatively, the contents of this file may be used under the terms of
* either the GNU General Public License Version 2 or later (the "GPL"), or
* the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
* in which case the provisions of the GPL or the LGPL are applicable instead
* of those above. If you wish to allow use of your version of this file only
* under the terms of either the GPL or the LGPL, and not to allow others to
* use your version of this file under the terms of the NPL, indicate your
* decision by deleting the provisions above and replace them with the notice
* and other provisions required by the GPL or the LGPL. If you do not delete
* the provisions above, a recipient may use your version of this file under
* the terms of any one of the NPL, the GPL or the LGPL.
*
* ***** END LICENSE BLOCK ***** */
//
// This is a header file for the MAPI support within
// Communicator.
//
// Written by: Rich Pizzarro (rhp@netscape.com)
//
#ifndef _NSCPMAPI
#define _NSCPMAPI
#ifndef MAPI_OLE // Because MSFT doesn't do this for us :-(
#include <mapi.h> // for MAPI specific types...
#endif
#ifdef WIN16
typedef unsigned char UCHAR;
#endif
#define MAX_NAME_LEN 256
#define MAX_PW_LEN 256
#define MAX_MSGINFO_LEN 512
#define MAX_CON 4 // Maximum MAPI session supported
#define MAX_POINTERS 32
//
// The MAPI class that will act as the internal mechanism for
// Communicator to control multiple MAPI sessions.
//
class CMAPIConnection
{
protected:
LONG m_ID;
BOOL m_defaultConnection;
LONG m_sessionCount;
LONG m_messageIndex;
LPVOID m_cookie;
UCHAR m_messageFindInfo[MAX_MSGINFO_LEN];
UCHAR m_profileName[MAX_NAME_LEN];
UCHAR m_password[MAX_PW_LEN];
// Methods
public:
CMAPIConnection ( LONG, LPSTR, LPSTR );
~CMAPIConnection ( );
// ID related methods
LONG GetID( ) { return m_ID; } ;
// Dealing with the default session...
BOOL IsDefault( ) { return m_defaultConnection; } ;
void SetDefault( BOOL flag ) { m_defaultConnection = flag; } ;
// For handling multiple sessions on a profile name...
LONG GetSessionCount( ) { return m_sessionCount; } ;
void IncrementSessionCount() { ++m_sessionCount; } ;
void DecrementSessionCount() { --m_sessionCount; } ;
// Information retrieval stuff...
LPSTR GetProfileName( ) { return (LPSTR) m_profileName; };
LPSTR GetPassword( ) { return (LPSTR) m_password; };
// Dealing with message information...
void SetMessageIndex( LONG mIndex ) { m_messageIndex = mIndex; } ;
LONG GetMessageIndex( ) { return m_messageIndex; };
void SetMessageFindInfo( LPSTR info ) { lstrcpy((LPSTR)m_messageFindInfo, info); } ;
LPSTR GetMessageFindInfo( ) { return (LPSTR) m_messageFindInfo; };
// For enumerating Messages...
void SetMapiListContext( LPVOID cookie) { m_cookie = cookie; } ;
LPVOID GetMapiListContext( ) { return m_cookie; };
};
//
// Defines needed for requests being made with the WM_COPYDATA call...
//
typedef enum {
NSCP_MAPIStartRequestID = 0,
NSCP_MAPILogon,
NSCP_MAPILogoff,
NSCP_MAPIFree,
NSCP_MAPISendMail,
NSCP_MAPISendDocuments,
NSCP_MAPIFindNext,
NSCP_MAPIReadMail,
NSCP_MAPISaveMail,
NSCP_MAPIDeleteMail,
NSCP_MAPIAddress,
NSCP_MAPIDetails,
NSCP_MAPIResolveName,
NSCP_MAPIEndRequestID // Note: this is a marker for MAPI IPC requests
} NSCP_IPC_REQUEST;
//
// This is to keep track of the pointers allocated in the MAPI DLL
// and deal with them correctly.
//
#define MAPI_MESSAGE_TYPE 0
#define MAPI_RECIPIENT_TYPE 1
typedef struct {
LPVOID lpMem;
UCHAR memType;
} memTrackerType;
//
// This is the generic message that WM_COPYDATA will send to the
// Communicator product to allow it to attach to shared memory.
// NOTE: On Win16, this will simply reference a pointer.
//
typedef struct {
UCHAR smemName[64]; // Name of shared memory
DWORD smemSize; // Size of shared memory
LPVOID lpsmem; // Will be really used in Win16 only
} MAPIIPCType;
//
// These are message specific structures that will be used for
// the various MAPI operations.
//
typedef struct {
ULONG ulUIParam;
FLAGS flFlags;
LHANDLE lhSession;
DWORD ipcWorked; // Necessary for IPC check with Communicator
// LPSTR strSequence, // LPSTR lpszProfileName, LPSTR lpszPassword
// This is here to document the fact there will be a string sequence at
// this location
} MAPILogonType;
typedef struct {
LHANDLE lhSession;
ULONG ulUIParam;
FLAGS flFlags;
DWORD ipcWorked; // Necessary for IPC check with Communicator
} MAPILogoffType;
typedef struct {
LHANDLE lhSession;
ULONG ulUIParam;
FLAGS flFlags;
DWORD ipcWorked; // Necessary for IPC check with Communicator
// The following is the "FLAT" representation of the (lpMapiMessage lpMessage)
// argument of this structure
FLAGS MSG_flFlags; // unread,return receipt
ULONG MSG_nRecipCount; // Number of recipients
ULONG MSG_nFileCount; // # of file attachments
ULONG MSG_ORIG_ulRecipClass; // Recipient class - MAPI_TO, MAPI_CC, MAPI_BCC, MAPI_ORIG
BYTE dataBuf[1]; // For easy referencing
//
// This is where it gets CONFUSING...the following buffer of memory is a
// contiguous chunk of memory for various strings that are part of this
// multilevel structure. For any of the following structure, any numbers
// are represented by strings that will have to be converted back to numeric
// values with atoi() calls.
// String 0: LPSTR lpszSubject; // Message Subject
// String 1: LPSTR lpszNoteText FILE NAME; // Message Text will be
// stored into a temp file and this will be the pointer to that file.
// String 2: LPSTR lpszDateReceived; // in YYYY/MM/DD HH:MM format
// String 3: LPSTR lpszConversationID; // conversation thread ID
//
// The following are for the originator of the message. Only ONE of these.
//
// String 4: LPSTR lpszName; // Originator name
// String 5: LPSTR lpszAddress; // Originator address (optional)
//
// The following strings are for the recipients for this message. There are
// MSG_nRecipCount of these in a row:
//
// for (i=0; i<MSG_nRecipCount; i++)
// String x: LPSTR lpszRecipClass (ULONG) // Recipient class - MAPI_TO, MAPI_CC, MAPI_BCC, MAPI_ORIG
// String x: LPSTR lpszName; // Recipient N name
// String x: LPSTR lpszAddress; // Recipient N address (optional)
//
// Now, finally, add the attachments for this beast. There are MSG_nFileCount
// attachments so it would look like the following:
//
// for (i=0; i<MSG_nFileCount; i++)
//
// String x: LPSTR lpszPathName // Fully qualified path of the attached file.
// // This path should include the disk drive letter and directory name.
// String x: LPSTR lpszFileName // The display name for the attached file
//
} MAPISendMailType;
typedef struct {
ULONG ulUIParam;
ULONG nFileCount;
DWORD ipcWorked; // Necessary for IPC check with Communicator
BYTE dataBuf[1]; // For easy referencing
//
// The sequence of strings to follow are groups of PathName/FileName couples.
// The strings will be parsed in MAPI[32].DLL and then put into this format:
//
// for (i=0; i<nFileCount; i++)
//
// String x: LPSTR lpszPathName // Fully qualified path of the attached file.
// // This path should include the disk drive letter and directory name.
// String x: LPSTR lpszFileName // The display name for the attached file
} MAPISendDocumentsType;
typedef struct {
LHANDLE lhSession;
ULONG ulUIParam;
FLAGS flFlags;
DWORD ipcWorked; // Necessary for IPC check with Communicator
UCHAR lpszSeedMessageID[MAX_MSGINFO_LEN];
UCHAR lpszMessageID[MAX_MSGINFO_LEN];
} MAPIFindNextType;
typedef struct {
LHANDLE lhSession;
ULONG ulUIParam;
DWORD ipcWorked; // Necessary for IPC check with Communicator
UCHAR lpszMessageID[MAX_MSGINFO_LEN];
} MAPIDeleteMailType;
typedef struct {
LHANDLE lhSession;
ULONG ulUIParam;
FLAGS flFlags;
DWORD ipcWorked; // Necessary for IPC check with Communicator
UCHAR lpszName[MAX_NAME_LEN];
// These are returned by Communicator
UCHAR lpszABookID[MAX_NAME_LEN];
UCHAR lpszABookName[MAX_NAME_LEN];
UCHAR lpszABookAddress[MAX_NAME_LEN];
} MAPIResolveNameType;
typedef struct {
LHANDLE lhSession;
ULONG ulUIParam;
FLAGS flFlags;
DWORD ipcWorked; // Necessary for IPC check with Communicator
UCHAR lpszABookID[MAX_NAME_LEN];
} MAPIDetailsType;
typedef struct {
LHANDLE lhSession;
ULONG ulUIParam;
FLAGS flFlags;
DWORD ipcWorked; // Necessary for IPC check with Communicator
UCHAR lpszMessageID[MAX_MSGINFO_LEN];
//
// The following is the "FLAT" representation of the (lpMapiMessage lpMessage)
// argument of this structure
//
FLAGS MSG_flFlags; // unread, return or receipt
ULONG MSG_nRecipCount; // Number of recipients
ULONG MSG_nFileCount; // # of file attachments
ULONG MSG_ORIG_ulRecipClass; // Recipient class - MAPI_TO, MAPI_CC, MAPI_BCC, MAPI_ORIG
//
// Output parameter for blob of information that will live on disk.
//
UCHAR lpszBlob[MAX_MSGINFO_LEN]; // file name on disk
//
// The format of this blob of information will be:
//
// String 0: LPSTR lpszSubject; // Message Subject
// String 1: LPSTR lpszNoteText FILE NAME; // Message Text will be
// stored into a temp file and this will be the pointer to that file.
// String 2: LPSTR lpszDateReceived; // in YYYY/MM/DD HH:MM format
// String 3: LPSTR lpszConversationID; // conversation thread ID
//
// The following are for the originator of the message. Only ONE of these.
//
// String 4: LPSTR lpszName; // Originator name
// String 5: LPSTR lpszAddress; // Originator address (optional)
//
// The following strings are for the recipients for this message. There are
// MSG_nRecipCount of these in a row:
//
// for (i=0; i<MSG_nRecipCount; i++)
// String x: LPSTR lpszName; // Recipient N name
// String x: LPSTR lpszAddress; // Recipient N address (optional)
// String x: LPSTR lpszRecipClass // recipient class - sprintf of ULONG
//
// Now, finally, add the attachments for this beast. There are MSG_nFileCount
// attachments so it would look like the following:
//
// for (i=0; i<MSG_nFileCount; i++)
//
// String x: LPSTR lpszPathName // Fully qualified path of the attached file.
// // This path should include the disk drive letter and directory name.
// String x: LPSTR lpszFileName // The display name for the attached file
//
} MAPIReadMailType;
typedef struct {
LHANDLE lhSession;
ULONG ulUIParam;
FLAGS flFlags;
UCHAR lpszCaption[MAX_MSGINFO_LEN];
DWORD ipcWorked; // Necessary for IPC check with Communicator
// The following is the "FLAT" representation of the (lpMapiRecipDesc lpRecips)
// argument of this structure
ULONG nRecips; // number of recips to start with...
ULONG nNewRecips; // number of recips returned...
UCHAR lpszBlob[MAX_MSGINFO_LEN]; // file name for blob of information
// that will live on disk.
BYTE dataBuf[1]; // For easy referencing
//
// The following contiguous chunk of memory is the buffer that holds
// the recipients to load into the address picker...
//
// for (i=0; i<MSG_nRecipCount; i++)
// String x: LPSTR lpszRecipClass (ULONG) // Recipient class - MAPI_TO, MAPI_CC, MAPI_BCC, MAPI_ORIG
// String x: LPSTR lpszName; // Recipient N name
// String x: LPSTR lpszAddress; // Recipient N address (optional)
//
} MAPIAddressType;
#endif // _NSCPMAPI

View File

@@ -0,0 +1,27 @@
#!nmake
#
# The contents of this file are subject to the Netscape Public
# License Version 1.1 (the "License"); you may not use this file
# except in compliance with the License. You may obtain a copy of
# the License at http://www.mozilla.org/NPL/
#
# Software distributed under the License is distributed on an "AS
# IS" basis, WITHOUT WARRANTY OF ANY KIND, either express or
# implied. See the License for the specific language governing
# rights and limitations under the License.
#
# The Original Code is mozilla.org code.
#
# The Initial Developer of the Original Code is Netscape
# Communications Corporation. Portions created by Netscape are
# Copyright (C) 1998 Netscape Communications Corporation. All
# Rights Reserved.
#
# Contributor(s):
DEPTH=..\..\..
DIRS=mapitest
include <$(DEPTH)\config\rules.mak>

View File

@@ -0,0 +1,239 @@
/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
/* ***** BEGIN LICENSE BLOCK *****
* Version: NPL 1.1/GPL 2.0/LGPL 2.1
*
* The contents of this file are subject to the Netscape Public License
* Version 1.1 (the "License"); you may not use this file except in
* compliance with the License. You may obtain a copy of the License at
* http://www.mozilla.org/NPL/
*
* Software distributed under the License is distributed on an "AS IS" basis,
* WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
* for the specific language governing rights and limitations under the
* License.
*
* The Original Code is mozilla.org code.
*
* The Initial Developer of the Original Code is
* Netscape Communications Corporation.
* Portions created by the Initial Developer are Copyright (C) 1998
* the Initial Developer. All Rights Reserved.
*
* Contributor(s):
*
* Alternatively, the contents of this file may be used under the terms of
* either the GNU General Public License Version 2 or later (the "GPL"), or
* the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
* in which case the provisions of the GPL or the LGPL are applicable instead
* of those above. If you wish to allow use of your version of this file only
* under the terms of either the GPL or the LGPL, and not to allow others to
* use your version of this file under the terms of the NPL, indicate your
* decision by deleting the provisions above and replace them with the notice
* and other provisions required by the GPL or the LGPL. If you do not delete
* the provisions above, a recipient may use your version of this file under
* the terms of any one of the NPL, the GPL or the LGPL.
*
* ***** END LICENSE BLOCK ***** */
//
#include <windows.h>
#include <windowsx.h>
#include <string.h>
#include <stdlib.h>
#ifndef MAPI_OLE // Because MSFT doesn't do this for us :-(
#include <mapi.h>
#endif
#include "port.h"
#include "resource.h"
#ifndef WM_PAINTICON
#define WM_PAINTICON 0x26
#endif // WM_PAINTICON
/*
* Forward Declarations...
*/
BOOL InitInstance(HINSTANCE hInstance, int nCmdShow);
BOOL CALLBACK LOADDS MyDlgProc(HWND hWnd, UINT wMsg, WPARAM wParam, LPARAM lParam);
extern void ProcessCommand(HWND hWnd, int id, HWND hCtl, UINT codeNotify);
BOOL OpenMAPI(void);
void CloseMAPI(void);
/*
* Global variables
*/
HINSTANCE hInst;
HWND hWnd;
#ifdef WIN16
HICON hIconApp;
#endif
char NEAR szAppName[] = "Netscape QA Helper";
char NEAR szShortAppName[] = "QAHelper";
char szClassName[] = "Netscape_QAHelper_Class_Name";
void
AppCleanup(void)
{
extern void DoMAPILogoff(HWND hWnd);
static BOOL isDone = FALSE;
if (isDone)
return;
extern LHANDLE mapiSession;
if (mapiSession != 0)
{
DoMAPILogoff(hWnd);
}
CloseMAPI();
isDone = TRUE;
}
BOOL
InitInstance(HINSTANCE hInstance, int nCmdShow)
{
/* Create a main window for this application instance. */
hWnd = CreateDialog((HINSTANCE) hInstance,
MAKEINTRESOURCE(ID_DIALOG),
(HWND) NULL, (DLGPROC) MyDlgProc);
if (!hWnd)
return FALSE;
else
return TRUE;
}
BOOL InitApp(void)
{
#ifndef WIN16
WNDCLASS wc;
wc.style = 0;
wc.lpfnWndProc = DefDlgProc;
wc.cbClsExtra = 0;
wc.cbWndExtra = DLGWINDOWEXTRA;
wc.hInstance = hInst;
wc.hIcon = LoadIcon(hInst, MAKEINTRESOURCE(ID_ICON_APP));
wc.hCursor = LoadCursor(0, IDC_ARROW);
wc.hbrBackground = (HBRUSH)(COLOR_BTNFACE + 1);
wc.lpszMenuName = NULL;
wc.lpszClassName = szClassName;
if(!RegisterClass(&wc))
return FALSE;
#else
hIconApp = LoadIcon(hInst, MAKEINTRESOURCE(ID_ICON_APP));
#endif
return TRUE;
} // end InitApp
// Win Main
int WINAPI WinMain(HINSTANCE hInstance, HINSTANCE hPrevInstance, LPSTR lpCmdLine, int nCmdShow)
{
MSG msg;
hInst = hInstance;
if (!InitApp())
{
return FALSE;
}
if (!InitInstance(hInstance, nCmdShow))
{
return FALSE;
}
if (!OpenMAPI())
{
return FALSE;
}
ShowWindow(hWnd, SW_SHOW);
// Start the application
while ((GetMessage(&msg, (HWND) NULL, (UINT) NULL, (UINT) NULL)))
{
if(IsDialogMessage(hWnd, &msg))
continue;
TranslateMessage(&msg);
DispatchMessage(&msg);
}
return(msg.wParam);
}
BOOL CALLBACK LOADDS
MyDlgProc(HWND hWndMain, UINT wMsg, WPARAM wParam, LPARAM lParam)
{
switch (wMsg)
{
case WM_INITDIALOG:
{
hWnd = hWndMain;
SetDlgItemText(hWnd, ID_EDIT_ROW, "0");
}
break;
case WM_CLOSE:
{
DestroyWindow(hWnd);
break;
}
case WM_DESTROY:
{
AppCleanup();
#ifndef WIN16
UnregisterClass(szClassName, hInst);
#else
// Destroy the 16 bit windows icon
if(hIconApp != 0)
DestroyIcon(hIconApp);
#endif
PostQuitMessage(0);
break;
}
case WM_COMMAND:
HANDLE_WM_COMMAND(hWnd, wParam, lParam, ProcessCommand);
break;
case WM_QUERYDRAGICON:
#ifdef WIN16
return (BOOL)hIconApp;
#endif
case WM_PAINTICON:
#ifdef WIN16
SetClassWord(hWnd, GCW_HICON, 0);
// fall trough
case WM_PAINT:
{
if(!IsIconic(hWnd))
return FALSE;
PAINTSTRUCT ps;
HDC hDC = BeginPaint(hWnd, &ps);
SetMapMode(hDC, MM_TEXT);
DrawIcon(hDC, 2, 2, hIconApp);
EndPaint(hWnd, &ps);
break;
}
#endif //WIN16
break; // RICHIE - if this is not here NT 3.51 Pukes!!!!
default:
return FALSE;
}
//~~av return (DefWindowProc(hWnd, wMsg, wParam, lParam));
return TRUE;
}

View File

@@ -0,0 +1,240 @@
# Microsoft Developer Studio Generated NMAKE File, Based on mapitest.dsp
!IF "$(CFG)" == ""
CFG=mapitest - Win32 Debug
!MESSAGE No configuration specified. Defaulting to mapitest - Win32 Debug.
!ENDIF
!IF "$(CFG)" != "mapitest - Win32 Release" && "$(CFG)" != "mapitest - Win32 Debug"
!MESSAGE Invalid configuration "$(CFG)" specified.
!MESSAGE You can specify a configuration when running NMAKE
!MESSAGE by defining the macro CFG on the command line. For example:
!MESSAGE
!MESSAGE NMAKE /f "mapitest.mak" CFG="mapitest - Win32 Debug"
!MESSAGE
!MESSAGE Possible choices for configuration are:
!MESSAGE
!MESSAGE "mapitest - Win32 Release" (based on "Win32 (x86) Application")
!MESSAGE "mapitest - Win32 Debug" (based on "Win32 (x86) Application")
!MESSAGE
!ERROR An invalid configuration is specified.
!ENDIF
!IF "$(OS)" == "Windows_NT"
NULL=
!ELSE
NULL=nul
!ENDIF
!IF "$(CFG)" == "mapitest - Win32 Release"
OUTDIR=.\Release
INTDIR=.\Release
# Begin Custom Macros
OutDir=.\Release
# End Custom Macros
ALL : "$(OUTDIR)\mapitest.exe"
export :
libs :
install :
clobber_all : clobber
clobber:
-@erase "$(INTDIR)\main.obj"
-@erase "$(INTDIR)\mapimail.obj"
-@erase "$(INTDIR)\mapiproc.obj"
-@erase "$(INTDIR)\mtest32.res"
-@erase "$(INTDIR)\readmail.obj"
-@erase "$(INTDIR)\vc60.idb"
-@erase "$(OUTDIR)\mapitest.exe"
-@erase "$(OUTDIR)\mapitest.pch"
"$(OUTDIR)" :
if not exist "$(OUTDIR)/$(NULL)" mkdir "$(OUTDIR)"
CPP=cl.exe
CPP_PROJ=/nologo /ML /W3 /GX /O2 /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "_MBCS" /Fp"$(INTDIR)\mapitest.pch" /YX /Fo"$(INTDIR)\\" /Fd"$(INTDIR)\\" /FD /c
.c{$(INTDIR)}.obj::
$(CPP) @<<
$(CPP_PROJ) $<
<<
.cpp{$(INTDIR)}.obj::
$(CPP) @<<
$(CPP_PROJ) $<
<<
.cxx{$(INTDIR)}.obj::
$(CPP) @<<
$(CPP_PROJ) $<
<<
.c{$(INTDIR)}.sbr::
$(CPP) @<<
$(CPP_PROJ) $<
<<
.cpp{$(INTDIR)}.sbr::
$(CPP) @<<
$(CPP_PROJ) $<
<<
.cxx{$(INTDIR)}.sbr::
$(CPP) @<<
$(CPP_PROJ) $<
<<
MTL=midl.exe
MTL_PROJ=/nologo /D "NDEBUG" /mktyplib203 /win32
RSC=rc.exe
RSC_PROJ=/l 0x409 /fo"$(INTDIR)\mtest32.res" /d "NDEBUG"
BSC32=bscmake.exe
BSC32_FLAGS=/nologo /o"$(OUTDIR)\mapitest.bsc"
BSC32_SBRS= \
LINK32=link.exe
LINK32_FLAGS=kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /subsystem:windows /incremental:no /pdb:"$(OUTDIR)\mapitest.pdb" /machine:I386 /out:"$(OUTDIR)\mapitest.exe"
LINK32_OBJS= \
"$(INTDIR)\main.obj" \
"$(INTDIR)\mapimail.obj" \
"$(INTDIR)\mapiproc.obj" \
"$(INTDIR)\readmail.obj" \
"$(INTDIR)\mtest32.res"
"$(OUTDIR)\mapitest.exe" : "$(OUTDIR)" $(DEF_FILE) $(LINK32_OBJS)
$(LINK32) @<<
$(LINK32_FLAGS) $(LINK32_OBJS)
<<
!ELSEIF "$(CFG)" == "mapitest - Win32 Debug"
OUTDIR=.\Debug
INTDIR=.\Debug
# Begin Custom Macros
OutDir=.\Debug
# End Custom Macros
ALL : "$(OUTDIR)\mapitest.exe"
export :
libs :
install :
clobber_all : clobber
clobber :
-@erase "$(INTDIR)\main.obj"
-@erase "$(INTDIR)\mapimail.obj"
-@erase "$(INTDIR)\mapiproc.obj"
-@erase "$(INTDIR)\mtest32.res"
-@erase "$(INTDIR)\readmail.obj"
-@erase "$(INTDIR)\vc60.idb"
-@erase "$(INTDIR)\vc60.pdb"
-@erase "$(OUTDIR)\mapitest.exe"
-@erase "$(OUTDIR)\mapitest.ilk"
-@erase "$(OUTDIR)\mapitest.pdb"
-@erase "$(OUTDIR)\mapitest.pch"
"$(OUTDIR)" :
if not exist "$(OUTDIR)/$(NULL)" mkdir "$(OUTDIR)"
CPP=cl.exe
CPP_PROJ=/nologo /MLd /W3 /Gm /GX /ZI /Od /D "WIN32" /D "_DEBUG" /D "_WINDOWS" /D "_MBCS" /Fp"$(INTDIR)\mapitest.pch" /YX /Fo"$(INTDIR)\\" /Fd"$(INTDIR)\\" /FD /GZ /c
.c{$(INTDIR)}.obj::
$(CPP) @<<
$(CPP_PROJ) $<
<<
.cpp{$(INTDIR)}.obj::
$(CPP) @<<
$(CPP_PROJ) $<
<<
.cxx{$(INTDIR)}.obj::
$(CPP) @<<
$(CPP_PROJ) $<
<<
.c{$(INTDIR)}.sbr::
$(CPP) @<<
$(CPP_PROJ) $<
<<
.cpp{$(INTDIR)}.sbr::
$(CPP) @<<
$(CPP_PROJ) $<
<<
.cxx{$(INTDIR)}.sbr::
$(CPP) @<<
$(CPP_PROJ) $<
<<
MTL=midl.exe
MTL_PROJ=/nologo /D "_DEBUG" /mktyplib203 /win32
RSC=rc.exe
RSC_PROJ=/l 0x409 /fo"$(INTDIR)\mtest32.res" /d "_DEBUG"
BSC32=bscmake.exe
BSC32_FLAGS=/nologo /o"$(OUTDIR)\mapitest.bsc"
BSC32_SBRS= \
LINK32=link.exe
LINK32_FLAGS=kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /subsystem:windows /incremental:yes /pdb:"$(OUTDIR)\mapitest.pdb" /debug /machine:I386 /out:"$(OUTDIR)\mapitest.exe" /pdbtype:sept
LINK32_OBJS= \
"$(INTDIR)\main.obj" \
"$(INTDIR)\mapimail.obj" \
"$(INTDIR)\mapiproc.obj" \
"$(INTDIR)\readmail.obj" \
"$(INTDIR)\mtest32.res"
"$(OUTDIR)\mapitest.exe" : "$(OUTDIR)" $(DEF_FILE) $(LINK32_OBJS)
$(LINK32) @<<
$(LINK32_FLAGS) $(LINK32_OBJS)
<<
!ENDIF
!IF "$(NO_EXTERNAL_DEPS)" != "1"
!IF EXISTS("mapitest.dep")
!INCLUDE "mapitest.dep"
!ELSE
!MESSAGE Warning: cannot find "mapitest.dep"
!ENDIF
!ENDIF
!IF "$(CFG)" == "mapitest - Win32 Release" || "$(CFG)" == "mapitest - Win32 Debug"
SOURCE=.\main.cpp
"$(INTDIR)\main.obj" : $(SOURCE) "$(INTDIR)"
SOURCE=.\mapimail.cpp
"$(INTDIR)\mapimail.obj" : $(SOURCE) "$(INTDIR)"
SOURCE=.\mapiproc.cpp
"$(INTDIR)\mapiproc.obj" : $(SOURCE) "$(INTDIR)"
SOURCE=.\mtest32.rc
"$(INTDIR)\mtest32.res" : $(SOURCE) "$(INTDIR)"
$(RSC) $(RSC_PROJ) $(SOURCE)
SOURCE=.\readmail.cpp
"$(INTDIR)\readmail.obj" : $(SOURCE) "$(INTDIR)"
!ENDIF

View File

@@ -0,0 +1,772 @@
/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
/* ***** BEGIN LICENSE BLOCK *****
* Version: NPL 1.1/GPL 2.0/LGPL 2.1
*
* The contents of this file are subject to the Netscape Public License
* Version 1.1 (the "License"); you may not use this file except in
* compliance with the License. You may obtain a copy of the License at
* http://www.mozilla.org/NPL/
*
* Software distributed under the License is distributed on an "AS IS" basis,
* WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
* for the specific language governing rights and limitations under the
* License.
*
* The Original Code is mozilla.org code.
*
* The Initial Developer of the Original Code is
* Netscape Communications Corporation.
* Portions created by the Initial Developer are Copyright (C) 1998
* the Initial Developer. All Rights Reserved.
*
* Contributor(s):
*
* Alternatively, the contents of this file may be used under the terms of
* either the GNU General Public License Version 2 or later (the "GPL"), or
* the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
* in which case the provisions of the GPL or the LGPL are applicable instead
* of those above. If you wish to allow use of your version of this file only
* under the terms of either the GPL or the LGPL, and not to allow others to
* use your version of this file under the terms of the NPL, indicate your
* decision by deleting the provisions above and replace them with the notice
* and other provisions required by the GPL or the LGPL. If you do not delete
* the provisions above, a recipient may use your version of this file under
* the terms of any one of the NPL, the GPL or the LGPL.
*
* ***** END LICENSE BLOCK ***** */
//
#include <windows.h>
#include <windowsx.h>
#include <string.h>
#include <mapi.h>
#include <stdlib.h>
#include "port.h"
#include "resource.h"
//
// Variables...
//
extern HINSTANCE m_hInstMapi;
extern LHANDLE mapiSession;
//
// Forward declarations...
//
void DoMAPIFreeBuffer(HWND hWnd, LPVOID buf, BOOL alert);
extern void ShowMessage(HWND hWnd, LPSTR msg);
void DoMAPISendMail(HWND hWnd);
void DoMAPISendDocuments(HWND hWnd);
void DoMAPISaveMail(HWND hWnd);
void DoMAPIAddress(HWND hWnd);
extern void SetFooter(LPSTR msg);
extern LPSTR GetMAPIError(LONG errorCode);
void
ProcessMailCommand(HWND hWnd, int id, HWND hCtl, UINT codeNotify)
{
switch (id)
{
case IDCANCEL:
EndDialog(hWnd, 0);
break;
case ID_BUTTON_MAPISENDMAIL:
DoMAPISendMail(hWnd);
break;
case ID_BUTTON_MAPISENDDOCUMENTS:
DoMAPISendDocuments(hWnd);
break;
case ID_BUTTON_MAPISAVEMAIL:
DoMAPISaveMail(hWnd);
break;
case ID_BUTTON_MAPIADDRESS:
DoMAPIAddress(hWnd);
break;
default:
break;
}
}
BOOL CALLBACK LOADDS
MailDlgProc(HWND hWndMain, UINT wMsg, WPARAM wParam, LPARAM lParam)
{
switch (wMsg)
{
case WM_INITDIALOG:
break;
case WM_COMMAND:
HANDLE_WM_COMMAND(hWndMain, wParam, lParam, ProcessMailCommand);
break;
default:
return FALSE;
}
return TRUE;
}
static LPSTR lpszDelimChar = ";";
void
TackItOn(LPSTR fileBuf, LPSTR nameBuf, LPSTR addOn)
{
if (addOn[0] != '\0')
{
lstrcat(fileBuf, addOn);
lstrcat(fileBuf, lpszDelimChar);
lstrcat(nameBuf, "NAMEOF.FILE");
lstrcat(nameBuf, lpszDelimChar);
}
}
void
DoMAPISendDocuments(HWND hWnd)
{
ULONG (FAR PASCAL *lpfnMAPISendDocuments) (ULONG ulUIParam,
LPTSTR lpszDelimChar, LPTSTR lpszFullPaths,
LPTSTR lpszFileNames, ULONG ulReserved);
#ifdef WIN16
(FARPROC&) lpfnMAPISendDocuments = GetProcAddress(m_hInstMapi, "MAPISENDDOCUMENTS");
#else
(FARPROC&) lpfnMAPISendDocuments = GetProcAddress(m_hInstMapi, "MAPISendDocuments");
#endif
if (!lpfnMAPISendDocuments)
{
ShowMessage(hWnd, "Unable to locate MAPI function.");
return;
}
char msg[1024];
char tempFileName[_MAX_PATH] = "";
char lpszFullPaths[(_MAX_PATH + 1) * 4] = "";
char lpszFileNames[(_MAX_PATH + 1) * 4] = "";
// Now get the names of the files to attach...
GetDlgItemText(hWnd, ID_EDIT_ATTACH1, tempFileName, sizeof(tempFileName));
TackItOn(lpszFullPaths, lpszFileNames, tempFileName);
GetDlgItemText(hWnd, ID_EDIT_ATTACH2, tempFileName, sizeof(tempFileName));
TackItOn(lpszFullPaths, lpszFileNames, tempFileName);
GetDlgItemText(hWnd, ID_EDIT_ATTACH3, tempFileName, sizeof(tempFileName));
TackItOn(lpszFullPaths, lpszFileNames, tempFileName);
GetDlgItemText(hWnd, ID_EDIT_ATTACH4, tempFileName, sizeof(tempFileName));
TackItOn(lpszFullPaths, lpszFileNames, tempFileName);
LONG rc = (*lpfnMAPISendDocuments)
( (ULONG) hWnd,
lpszDelimChar,
lpszFullPaths,
lpszFileNames,
0);
if (rc == SUCCESS_SUCCESS)
{
ShowMessage(hWnd, "Success with MAPISendDocuments");
SetFooter("MAPISendDocuments success");
}
else
{
wsprintf(msg, "FAILURE: Return code %d from MAPISendDocuments\nError=[%s]",
rc, GetMAPIError(rc));
ShowMessage(hWnd, msg);
SetFooter("MAPISendDocuments failed");
}
}
void
FreeMAPIFile(lpMapiFileDesc pv)
{
if (!pv)
return;
if (pv->lpszPathName != NULL)
free(pv->lpszPathName);
if (pv->lpszFileName != NULL)
free(pv->lpszFileName);
}
void
FreeMAPIRecipient(lpMapiRecipDesc pv)
{
if (!pv)
return;
if (pv->lpszName != NULL)
free(pv->lpszName);
if (pv->lpszAddress != NULL)
free(pv->lpszAddress);
if (pv->lpEntryID != NULL)
free(pv->lpEntryID);
}
void
FreeMAPIMessage(lpMapiMessage pv)
{
ULONG i;
if (!pv)
return;
if (pv->lpszSubject != NULL)
free(pv->lpszSubject);
if (pv->lpszNoteText)
free(pv->lpszNoteText);
if (pv->lpszMessageType)
free(pv->lpszMessageType);
if (pv->lpszDateReceived)
free(pv->lpszDateReceived);
if (pv->lpszConversationID)
free(pv->lpszConversationID);
if (pv->lpOriginator)
FreeMAPIRecipient(pv->lpOriginator);
for (i=0; i<pv->nRecipCount; i++)
{
if (&(pv->lpRecips[i]) != NULL)
{
FreeMAPIRecipient(&(pv->lpRecips[i]));
}
}
if (pv->lpRecips != NULL)
{
free(pv->lpRecips);
}
for (i=0; i<pv->nFileCount; i++)
{
if (&(pv->lpFiles[i]) != NULL)
{
FreeMAPIFile(&(pv->lpFiles[i]));
}
}
if (pv->lpFiles != NULL)
{
free(pv->lpFiles);
}
free(pv);
pv = NULL;
}
void
DoMAPISendMail(HWND hWnd)
{
ULONG (FAR PASCAL *lpfnMAPISendMail) (LHANDLE lhSession, ULONG ulUIParam,
lpMapiMessage lpMessage, FLAGS flFlags, ULONG ulReserved);
#ifdef WIN16
(FARPROC&) lpfnMAPISendMail = GetProcAddress(m_hInstMapi, "MAPISENDMAIL");
#else
(FARPROC&) lpfnMAPISendMail = GetProcAddress(m_hInstMapi, "MAPISendMail");
#endif
if (!lpfnMAPISendMail)
{
ShowMessage(hWnd, "Unable to locate MAPI function.");
return;
}
FLAGS flFlags = 0;
char msg[512];
char file1[_MAX_PATH] = "";
char file2[_MAX_PATH] = "";
char file3[_MAX_PATH] = "";
char file4[_MAX_PATH] = "";
char toAddr[128];
char ccAddr[128];
char bccAddr[128];
char subject[128];
char noteText[4096];
char dateReceived[128] = "N/A";
char threadID[128] = "N/A";;
char origName[128] = "N/A";;
char origAddress[128] = "N/A";;
GetDlgItemText(hWnd, ID_EDIT_TOADDRESS, toAddr, sizeof(toAddr));
GetDlgItemText(hWnd, ID_EDIT_CCADDRESS, ccAddr, sizeof(ccAddr));
GetDlgItemText(hWnd, ID_EDIT_BCCADDRESS, bccAddr, sizeof(bccAddr));
GetDlgItemText(hWnd, ID_EDIT_SUBJECT, subject, sizeof(subject));
GetDlgItemText(hWnd, ID_EDIT_NOTETEXT, noteText, sizeof(noteText));
// Do the one flag we support for this call...
if (BST_CHECKED == Button_GetCheck(GetDlgItem(hWnd, ID_CHECK_SHOWDIALOG)))
{
flFlags |= MAPI_DIALOG;
}
// Build the message to send off...
lpMapiMessage msgPtr = (MapiMessage *)malloc(sizeof(MapiMessage));
if (msgPtr == NULL)
{
return;
}
memset(msgPtr, 0, sizeof(MapiMessage));
//
// At this point, we need to populate the structure of information
// we are passing in via the *lppMessage
//
// Set all of the general information first!
msgPtr->lpszSubject = strdup(subject);
msgPtr->lpszNoteText = strdup(noteText);
msgPtr->lpszDateReceived = strdup(dateReceived);
msgPtr->lpszConversationID = strdup(threadID);
msgPtr->flFlags = flFlags;
// Now deal with the recipients of this message
DWORD realRecips = 0;
if (toAddr[0] != '\0') ++realRecips;
if (ccAddr[0] != '\0') ++realRecips;
if (bccAddr[0] != '\0') ++realRecips;
msgPtr->lpRecips = (lpMapiRecipDesc) malloc((size_t) (sizeof(MapiRecipDesc) * realRecips));
if (!msgPtr->lpRecips)
{
FreeMAPIMessage(msgPtr);
return;
}
msgPtr->nRecipCount = realRecips;
memset(msgPtr->lpRecips, 0, (size_t) (sizeof(MapiRecipDesc) * msgPtr->nRecipCount));
DWORD rCount = 0;
if (toAddr[0] != '\0')
{
msgPtr->lpRecips[rCount].lpszName = strdup(toAddr);
msgPtr->lpRecips[rCount].lpszAddress = strdup(toAddr);
msgPtr->lpRecips[rCount].ulRecipClass = MAPI_TO;
rCount++;
}
if (ccAddr[0] != '\0')
{
msgPtr->lpRecips[rCount].lpszName = strdup(ccAddr);
msgPtr->lpRecips[rCount].lpszAddress = strdup(ccAddr);
msgPtr->lpRecips[rCount].ulRecipClass = MAPI_CC;
rCount++;
}
if (bccAddr[0] != '\0')
{
msgPtr->lpRecips[rCount].lpszName = strdup(bccAddr);
msgPtr->lpRecips[rCount].lpszAddress = strdup(bccAddr);
msgPtr->lpRecips[rCount].ulRecipClass = MAPI_BCC;
rCount++;
}
// Now get the names of the files to attach...
GetDlgItemText(hWnd, ID_EDIT_ATTACH1, file1, sizeof(file1));
GetDlgItemText(hWnd, ID_EDIT_ATTACH2, file2, sizeof(file2));
GetDlgItemText(hWnd, ID_EDIT_ATTACH3, file3, sizeof(file3));
GetDlgItemText(hWnd, ID_EDIT_ATTACH4, file4, sizeof(file4));
DWORD realFiles = 0;
if (file1[0] != '\0') ++realFiles;
if (file2[0] != '\0') ++realFiles;
if (file3[0] != '\0') ++realFiles;
if (file4[0] != '\0') ++realFiles;
// Now deal with the list of attachments! Since the nFileCount should be set
// correctly, this loop will automagically be correct
//
msgPtr->nFileCount = realFiles;
if (realFiles > 0)
{
msgPtr->lpFiles = (lpMapiFileDesc) malloc((size_t) (sizeof(MapiFileDesc) * realFiles));
if (!msgPtr->lpFiles)
{
FreeMAPIMessage(msgPtr);
return;
}
memset(msgPtr->lpFiles, 0, (size_t) (sizeof(MapiFileDesc) * msgPtr->nFileCount));
}
rCount = 0;
if (file1[0] != '\0')
{
msgPtr->lpFiles[rCount].lpszPathName = strdup((LPSTR)file1);
msgPtr->lpFiles[rCount].lpszFileName = strdup((LPSTR)file1);
++rCount;
}
if (file2[0] != '\0')
{
msgPtr->lpFiles[rCount].lpszPathName = strdup((LPSTR)file2);
msgPtr->lpFiles[rCount].lpszFileName = strdup((LPSTR)file2);
++rCount;
}
if (file3[0] != '\0')
{
msgPtr->lpFiles[rCount].lpszPathName = strdup((LPSTR)file3);
msgPtr->lpFiles[rCount].lpszFileName = strdup((LPSTR)file3);
++rCount;
}
if (file4[0] != '\0')
{
msgPtr->lpFiles[rCount].lpszPathName = strdup((LPSTR)file4);
msgPtr->lpFiles[rCount].lpszFileName = strdup((LPSTR)file4);
++rCount;
}
// Finally, make the call...
LONG rc = (*lpfnMAPISendMail)
(mapiSession,
(ULONG) hWnd,
msgPtr,
flFlags,
0);
if (rc == SUCCESS_SUCCESS)
{
ShowMessage(hWnd, "Success with MAPISendMail");
SetFooter("MAPISendMail success");
}
else
{
wsprintf(msg, "FAILURE: Return code %d from MAPISendMail\nError=[%s]",
rc, GetMAPIError(rc));
ShowMessage(hWnd, msg);
SetFooter("MAPISendMail failed");
}
// Now cleanup and move on...
FreeMAPIMessage(msgPtr);
}
void
DoMAPISaveMail(HWND hWnd)
{
ULONG (FAR PASCAL *lpfnMAPISaveMail) (LHANDLE lhSession, ULONG ulUIParam,
lpMapiMessage lpMessage, FLAGS flFlags, ULONG ulReserved,
LPTSTR lpszMessageID);
#ifdef WIN16
(FARPROC&) lpfnMAPISaveMail = GetProcAddress(m_hInstMapi, "MAPISAVEMAIL");
#else
(FARPROC&) lpfnMAPISaveMail = GetProcAddress(m_hInstMapi, "MAPISaveMail");
#endif
if (!lpfnMAPISaveMail)
{
ShowMessage(hWnd, "Unable to locate MAPI function.");
return;
}
FLAGS flFlags = 0;
char msg[512];
char file1[_MAX_PATH] = "";
char file2[_MAX_PATH] = "";
char file3[_MAX_PATH] = "";
char file4[_MAX_PATH] = "";
char toAddr[128];
char ccAddr[128];
char bccAddr[128];
char subject[128];
char noteText[4096];
char dateReceived[128] = "N/A";
char threadID[128] = "N/A";;
char origName[128] = "N/A";;
char origAddress[128] = "N/A";;
GetDlgItemText(hWnd, ID_EDIT_TOADDRESS, toAddr, sizeof(toAddr));
GetDlgItemText(hWnd, ID_EDIT_CCADDRESS, ccAddr, sizeof(ccAddr));
GetDlgItemText(hWnd, ID_EDIT_BCCADDRESS, bccAddr, sizeof(bccAddr));
GetDlgItemText(hWnd, ID_EDIT_SUBJECT, subject, sizeof(subject));
GetDlgItemText(hWnd, ID_EDIT_NOTETEXT, noteText, sizeof(noteText));
// Build the message to send off...
lpMapiMessage msgPtr = (MapiMessage *)malloc(sizeof(MapiMessage));
if (msgPtr == NULL)
{
return;
}
memset(msgPtr, 0, sizeof(MapiMessage));
//
// At this point, we need to populate the structure of information
// we are passing in via the *lppMessage
//
// Set all of the general information first!
msgPtr->lpszSubject = strdup(subject);
msgPtr->lpszNoteText = strdup(noteText);
msgPtr->lpszDateReceived = strdup(dateReceived);
msgPtr->lpszConversationID = strdup(threadID);
msgPtr->flFlags = flFlags;
// Now deal with the recipients of this message
DWORD realRecips = 0;
if (toAddr[0] != '\0') ++realRecips;
if (ccAddr[0] != '\0') ++realRecips;
if (bccAddr[0] != '\0') ++realRecips;
msgPtr->lpRecips = (lpMapiRecipDesc) malloc((size_t) (sizeof(MapiRecipDesc) * realRecips));
if (!msgPtr->lpRecips)
{
FreeMAPIMessage(msgPtr);
return;
}
msgPtr->nRecipCount = realRecips;
memset(msgPtr->lpRecips, 0, (size_t) (sizeof(MapiRecipDesc) * msgPtr->nRecipCount));
DWORD rCount = 0;
if (toAddr[0] != '\0')
{
msgPtr->lpRecips[rCount].lpszName = strdup(toAddr);
msgPtr->lpRecips[rCount].lpszAddress = strdup(toAddr);
msgPtr->lpRecips[rCount].ulRecipClass = MAPI_TO;
rCount++;
}
if (ccAddr[0] != '\0')
{
msgPtr->lpRecips[rCount].lpszName = strdup(ccAddr);
msgPtr->lpRecips[rCount].lpszAddress = strdup(ccAddr);
msgPtr->lpRecips[rCount].ulRecipClass = MAPI_CC;
rCount++;
}
if (bccAddr[0] != '\0')
{
msgPtr->lpRecips[rCount].lpszName = strdup(bccAddr);
msgPtr->lpRecips[rCount].lpszAddress = strdup(bccAddr);
msgPtr->lpRecips[rCount].ulRecipClass = MAPI_BCC;
rCount++;
}
// Now get the names of the files to attach...
GetDlgItemText(hWnd, ID_EDIT_ATTACH1, file1, sizeof(file1));
GetDlgItemText(hWnd, ID_EDIT_ATTACH2, file2, sizeof(file2));
GetDlgItemText(hWnd, ID_EDIT_ATTACH3, file3, sizeof(file3));
GetDlgItemText(hWnd, ID_EDIT_ATTACH4, file4, sizeof(file4));
DWORD realFiles = 0;
if (file1[0] != '\0') ++realFiles;
if (file2[0] != '\0') ++realFiles;
if (file3[0] != '\0') ++realFiles;
if (file4[0] != '\0') ++realFiles;
// Now deal with the list of attachments! Since the nFileCount should be set
// correctly, this loop will automagically be correct
//
msgPtr->nFileCount = realFiles;
if (realFiles > 0)
{
msgPtr->lpFiles = (lpMapiFileDesc) malloc((size_t) (sizeof(MapiFileDesc) * realFiles));
if (!msgPtr->lpFiles)
{
FreeMAPIMessage(msgPtr);
return;
}
memset(msgPtr->lpFiles, 0, (size_t) (sizeof(MapiFileDesc) * msgPtr->nFileCount));
}
rCount = 0;
if (file1[0] != '\0')
{
msgPtr->lpFiles[rCount].lpszPathName = strdup((LPSTR)file1);
msgPtr->lpFiles[rCount].lpszFileName = strdup((LPSTR)file1);
++rCount;
}
if (file2[0] != '\0')
{
msgPtr->lpFiles[rCount].lpszPathName = strdup((LPSTR)file2);
msgPtr->lpFiles[rCount].lpszFileName = strdup((LPSTR)file2);
++rCount;
}
if (file3[0] != '\0')
{
msgPtr->lpFiles[rCount].lpszPathName = strdup((LPSTR)file3);
msgPtr->lpFiles[rCount].lpszFileName = strdup((LPSTR)file3);
++rCount;
}
if (file4[0] != '\0')
{
msgPtr->lpFiles[rCount].lpszPathName = strdup((LPSTR)file4);
msgPtr->lpFiles[rCount].lpszFileName = strdup((LPSTR)file4);
++rCount;
}
// Finally, make the call...
LONG rc = (*lpfnMAPISaveMail)
(mapiSession,
(ULONG) hWnd,
msgPtr,
flFlags,
0, NULL);
if (rc == SUCCESS_SUCCESS)
{
ShowMessage(hWnd, "Success with MAPISaveMail");
SetFooter("MAPISaveMail success");
}
else
{
wsprintf(msg, "FAILURE: Return code %d from MAPISaveMail\nError=[%s]",
rc, GetMAPIError(rc));
ShowMessage(hWnd, msg);
SetFooter("MAPISaveMail failed");
}
// Now cleanup and move on...
FreeMAPIMessage(msgPtr);
}
void
DoMAPIAddress(HWND hWnd)
{
ULONG (FAR PASCAL *lpfnMAPIAddress)
(LHANDLE lhSession,
ULONG ulUIParam,
LPSTR lpszCaption,
ULONG nEditFields,
LPSTR lpszLabels,
ULONG nRecips,
lpMapiRecipDesc lpRecips,
FLAGS flFlags,
ULONG ulReserved,
LPULONG lpnNewRecips,
lpMapiRecipDesc FAR *lppNewRecips);
#ifdef WIN16
(FARPROC&) lpfnMAPIAddress = GetProcAddress(m_hInstMapi, "MAPIADDRESS");
#else
(FARPROC&) lpfnMAPIAddress = GetProcAddress(m_hInstMapi, "MAPIAddress");
#endif
if (!lpfnMAPIAddress)
{
ShowMessage(hWnd, "Unable to locate MAPI function.");
return;
}
DWORD i;
FLAGS flFlags = 0;
DWORD addrCount = 0;
char msg[512];
char toAddr[128];
char ccAddr[128];
char bccAddr[128];
GetDlgItemText(hWnd, ID_EDIT_TOADDRESS, toAddr, sizeof(toAddr));
GetDlgItemText(hWnd, ID_EDIT_CCADDRESS, ccAddr, sizeof(ccAddr));
GetDlgItemText(hWnd, ID_EDIT_BCCADDRESS, bccAddr, sizeof(bccAddr));
if (toAddr[0]) ++addrCount;
if (ccAddr[0]) ++addrCount;
if (bccAddr[0]) ++addrCount;
lpMapiRecipDesc lpRecips = (lpMapiRecipDesc) malloc((size_t) (sizeof(MapiRecipDesc) * addrCount));
if (!lpRecips)
{
return;
}
memset(lpRecips, 0, (size_t) (sizeof(MapiRecipDesc) * addrCount));
DWORD rCount = 0;
if (toAddr[0] != '\0')
{
lpRecips[rCount].lpszName = strdup("To Address Name");
lpRecips[rCount].lpszAddress = strdup(toAddr);
lpRecips[rCount].ulRecipClass = MAPI_TO;
rCount++;
}
if (ccAddr[0] != '\0')
{
lpRecips[rCount].lpszName = strdup("CC Address Name");
lpRecips[rCount].lpszAddress = strdup(ccAddr);
lpRecips[rCount].ulRecipClass = MAPI_CC;
rCount++;
}
if (bccAddr[0] != '\0')
{
lpRecips[rCount].lpszName = strdup("BCC Address Name");
lpRecips[rCount].lpszAddress = strdup(bccAddr);
lpRecips[rCount].ulRecipClass = MAPI_BCC;
rCount++;
}
ULONG newRecips;
lpMapiRecipDesc lpNewRecips;
// Finally, make the call...
LONG rc = (*lpfnMAPIAddress)
(mapiSession,
0,
"MAPI Test Address Picker",
0,
NULL,
rCount,
lpRecips,
0,
0,
&newRecips,
&lpNewRecips);
if (rc == SUCCESS_SUCCESS)
{
for (i=0; i<newRecips; i++)
{
char tMsg[512];
wsprintf(tMsg, "User %d\nName=[%s]\nEmail=[%s]\nType=[%d]",
i,
lpNewRecips[i].lpszName,
lpNewRecips[i].lpszAddress,
lpNewRecips[i].ulRecipClass);
ShowMessage(hWnd, tMsg);
}
SetFooter("MAPIAddress success");
DoMAPIFreeBuffer(hWnd, lpNewRecips, TRUE);
}
else
{
wsprintf(msg, "FAILURE: Return code %d from MAPIAddress\nError=[%s]",
rc, GetMAPIError(rc));
ShowMessage(hWnd, msg);
SetFooter("MAPIAddress failed");
}
// Now cleanup and move on...
for (i=0; i<rCount; i++)
{
FreeMAPIRecipient(&(lpRecips[i]));
}
}

View File

@@ -0,0 +1,832 @@
/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
/* ***** BEGIN LICENSE BLOCK *****
* Version: NPL 1.1/GPL 2.0/LGPL 2.1
*
* The contents of this file are subject to the Netscape Public License
* Version 1.1 (the "License"); you may not use this file except in
* compliance with the License. You may obtain a copy of the License at
* http://www.mozilla.org/NPL/
*
* Software distributed under the License is distributed on an "AS IS" basis,
* WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
* for the specific language governing rights and limitations under the
* License.
*
* The Original Code is mozilla.org code.
*
* The Initial Developer of the Original Code is
* Netscape Communications Corporation.
* Portions created by the Initial Developer are Copyright (C) 1998
* the Initial Developer. All Rights Reserved.
*
* Contributor(s):
*
* Alternatively, the contents of this file may be used under the terms of
* either the GNU General Public License Version 2 or later (the "GPL"), or
* the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
* in which case the provisions of the GPL or the LGPL are applicable instead
* of those above. If you wish to allow use of your version of this file only
* under the terms of either the GPL or the LGPL, and not to allow others to
* use your version of this file under the terms of the NPL, indicate your
* decision by deleting the provisions above and replace them with the notice
* and other provisions required by the GPL or the LGPL. If you do not delete
* the provisions above, a recipient may use your version of this file under
* the terms of any one of the NPL, the GPL or the LGPL.
*
* ***** END LICENSE BLOCK ***** */
//
#include <windows.h>
#include <windowsx.h>
#include <string.h>
#ifndef MAPI_OLE // Because MSFT doesn't do this for us :-(
#include <mapi.h>
#endif
#include "port.h"
#include "resource.h"
//
// Variables...
//
extern HINSTANCE hInst;
HINSTANCE m_hInstMapi;
LHANDLE mapiSession = 0;
//
// Forward declarations...
//
void LoadNSCPVersionFunc(HWND hWnd);
void DoMAPILogon(HWND hWnd);
void DoMAPILogoff(HWND hWnd);
void DoMAPIFreeBuffer(HWND hWnd, LPVOID buf, BOOL alert);
void DoMAPISendMail(HWND hWnd);
void DoMAPISendDocuments(HWND hWnd);
void DoMAPIFindNext(HWND hWnd);
void DoMAPIReadMail(HWND hWnd);
void DoMAPIDeleteMail(HWND hWnd);
void DoMAPIDetails(HWND hWnd);
void DoMAPIResolveName(HWND hWnd);
void DoMAPIResolveNameFreeBuffer(HWND hWnd);
void SetFooter(LPSTR msg);
void DoMAPI_NSCP_Sync(HWND hWnd);
LPSTR GetMAPIError(LONG errorCode);
extern void DisplayMAPIReadMail(HWND hWnd, lpMapiMessage msgPtr);
lpMapiMessage GetMessage(HWND hWnd, LPSTR id);
void
SetFooter(LPSTR msg)
{
extern HWND hWnd;
SetDlgItemText(hWnd, ID_STATIC_RESULT, msg);
}
char FAR *
GetMAPIError(LONG errorCode)
{
static char FAR msg[128];
switch (errorCode) {
case MAPI_E_FAILURE:
lstrcpy(msg, "General MAPI Failure");
break;
case MAPI_E_INSUFFICIENT_MEMORY:
strcpy(msg, "Insufficient Memory");
break;
case MAPI_E_LOGIN_FAILURE:
strcpy(msg, "Login Failure");
break;
case MAPI_E_TOO_MANY_SESSIONS:
strcpy(msg, "Too many MAPI sessions");
break;
case MAPI_E_INVALID_SESSION:
strcpy(msg, "Invalid Session!");
break;
case MAPI_E_INVALID_MESSAGE:
strcpy(msg, "Message identifier was bad!");
break;
case MAPI_E_NO_MESSAGES:
strcpy(msg, "No messages were found!");
break;
case MAPI_E_ATTACHMENT_WRITE_FAILURE:
strcpy(msg, "Attachment write failure!");
break;
case MAPI_E_DISK_FULL:
strcpy(msg, "Attachment write failure! DISK FULL");
break;
case MAPI_E_AMBIGUOUS_RECIPIENT:
strcpy(msg, "Recipient requested is not a unique address list entry.");
break;
case MAPI_E_UNKNOWN_RECIPIENT:
strcpy(msg, "Recipient requested does not exist.");
break;
case MAPI_E_NOT_SUPPORTED:
strcpy(msg, "Not supported by messaging system");
break;
case SUCCESS_SUCCESS:
strcpy(msg, "Success on MAPI operation");
break;
case MAPI_E_INVALID_RECIPS:
strcpy(msg, "Recipient specified in the lpRecip parameter was\nunknown. No dialog box was displayed.");
break;
case MAPI_E_ATTACHMENT_OPEN_FAILURE:
strcpy(msg, "One or more files could not be located. No message was sent.");
break;
case MAPI_E_ATTACHMENT_NOT_FOUND:
strcpy(msg, "The specified attachment was not found. No message was sent.");
break;
case MAPI_E_BAD_RECIPTYPE:
strcpy(msg, "The type of a recipient was not MAPI_TO, MAPI_CC, or MAPI_BCC. No message was sent.");
break;
default:
strcpy(msg, "Unknown MAPI Return Code");
break;
}
return((LPSTR) &(msg[0]));
}
void
ShowMessage(HWND hWnd, LPSTR msg)
{
MessageBox(hWnd, msg, "Info Message", MB_ICONINFORMATION);
}
BOOL
OpenMAPI(void)
{
#ifdef WIN16
m_hInstMapi = LoadLibrary("Y:\\ns\\cmd\\winfe\\mapi\\MAPI.DLL");
#else
m_hInstMapi = LoadLibrary(".\\COMPONENTS\\MAPI32.DLL");
#endif
if (!m_hInstMapi)
{
ShowMessage(NULL, "Error Loading the MAPI DLL...Probably not found!");
return(FALSE);
}
return(TRUE);
}
void
CloseMAPI(void)
{
if(m_hInstMapi)
{
FreeLibrary(m_hInstMapi);
}
}
void
ProcessCommand(HWND hWnd, int id, HWND hCtl, UINT codeNotify)
{
switch (id)
{
case ID_BUTTON_SYNC:
DoMAPI_NSCP_Sync(hWnd);
break;
case ID_BUTTON_NSCPVERSION:
LoadNSCPVersionFunc(hWnd);
break;
case ID_BUTTON_LOGON:
DoMAPILogon(hWnd);
break;
case ID_BUTTON_LOGOFF:
DoMAPILogoff(hWnd);
break;
case ID_BUTTON_FINDNEXT:
case ID_MENU_MAPIFINDNEXT:
DoMAPIFindNext(hWnd);
break;
case ID_BUTTON_READMAIL:
case ID_MENU_MAPIREADMAIL:
DoMAPIReadMail(hWnd);
break;
case ID_BUTTON_MAIL:
{
extern CALLBACK LOADDS
MailDlgProc(HWND hWndMain, UINT wMsg, WPARAM wParam, LPARAM lParam);
DialogBox(hInst, MAKEINTRESOURCE(ID_DIALOG_MAIL), hWnd,
(DLGPROC)MailDlgProc);
}
break;
case ID_BUTTON_DELETEMAIL:
case ID_MENU_MAPIDELETEMAIL:
DoMAPIDeleteMail(hWnd);
break;
case ID_MENU_MYEXIT:
DestroyWindow(hWnd);
break;
case ID_BUTTON_CLEAR:
case ID_MENU_CLEARRESULTS:
ListBox_ResetContent(GetDlgItem(hWnd, ID_LIST_RESULT));
break;
case ID_BUTTON_FREEBUFFER:
DoMAPIResolveNameFreeBuffer(hWnd);
break;
case ID_BUTTON_RESOLVENAME:
DoMAPIResolveName(hWnd);
break;
case ID_BUTTON_DETAILS:
DoMAPIDetails(hWnd);
break;
case ID_MENU_MYABOUT:
MessageBox(hWnd,
"Netscape MAPI Test Harness\nWritten by: Rich Pizzarro (rhp@netscape.com)",
"About",
MB_ICONINFORMATION);
break;
default:
break;
}
}
void
DoMAPILogon(HWND hWnd)
{
char msg[1024];
char user[128] = "";
char pw[128] = "";
// Get Address of MAPI function...
ULONG (FAR PASCAL *lpfnMAPILogon)(ULONG, LPSTR, LPSTR, FLAGS, ULONG, LPLHANDLE);
#ifdef WIN16
(FARPROC&) lpfnMAPILogon = GetProcAddress(m_hInstMapi, "MAPILOGON");
#else
(FARPROC&) lpfnMAPILogon = GetProcAddress(m_hInstMapi, "MAPILogon");
#endif
if (!lpfnMAPILogon)
{
ShowMessage(hWnd, "Unable to locate MAPI function.");
return;
}
GetDlgItemText(hWnd, ID_EDIT_USERNAME, user, sizeof(user));
GetDlgItemText(hWnd, ID_EDIT_PW, pw, sizeof(pw));
LONG rc = (*lpfnMAPILogon)((ULONG) hWnd, user, pw,
MAPI_FORCE_DOWNLOAD | MAPI_NEW_SESSION, 0, &mapiSession);
if (rc == SUCCESS_SUCCESS)
{
wsprintf(msg, "Success with session = %d", mapiSession);
ShowMessage(hWnd, msg);
SetFooter("Logon success");
}
else
{
wsprintf(msg, "FAILURE: Return code %d from Logon\nError=[%s]",
rc, GetMAPIError(rc));
ShowMessage(hWnd, msg);
SetFooter("Logon failed");
}
}
void
DoMAPILogoff(HWND hWnd)
{
ULONG (FAR PASCAL *lpfnMAPILogoff) ( LHANDLE lhSession, ULONG ulUIParam,
FLAGS flFlags, ULONG ulReserved);
#ifdef WIN16
(FARPROC&) lpfnMAPILogoff = GetProcAddress(m_hInstMapi, "MAPILOGOFF");
#else
(FARPROC&) lpfnMAPILogoff = GetProcAddress(m_hInstMapi, "MAPILogoff");
#endif
if (!lpfnMAPILogoff)
{
ShowMessage(hWnd, "Unable to locate MAPI function.");
return;
}
char msg[1024];
LONG rc = (*lpfnMAPILogoff)(mapiSession, (ULONG) hWnd, 0, 0);
if (rc == SUCCESS_SUCCESS)
{
wsprintf(msg, "Successful logoff");
ShowMessage(hWnd, msg);
SetFooter(msg);
}
else
{
wsprintf(msg, "FAILURE: Return code %d from Logoff\nError=[%s]",
rc, GetMAPIError(rc));
ShowMessage(hWnd, msg);
SetFooter("Logoff failed");
}
mapiSession = 0;
}
void
DoMAPIFreeBuffer(HWND hWnd, LPVOID buf, BOOL alert)
{
ULONG (FAR PASCAL *lpfnMAPIFreeBuffer) (LPVOID lpBuffer);
#ifdef WIN16
(FARPROC&) lpfnMAPIFreeBuffer = GetProcAddress(m_hInstMapi, "MAPIFREEBUFFER");
#else
(FARPROC&) lpfnMAPIFreeBuffer = GetProcAddress(m_hInstMapi, "MAPIFreeBuffer");
#endif
if (!lpfnMAPIFreeBuffer)
{
ShowMessage(hWnd, "Unable to locate MAPI function.");
return;
}
char msg[1024];
LONG rc = (*lpfnMAPIFreeBuffer)(buf);
#ifdef WIN32
if (rc == S_OK)
#else
if (rc == SUCCESS_SUCCESS)
#endif
{
wsprintf(msg, "Successful Free Buffer Operation");
if (alert)
ShowMessage(hWnd, msg);
}
else
{
wsprintf(msg, "FAILURE: Return code %d from Logoff", rc);
ShowMessage(hWnd, msg);
}
}
void
DoMAPIFindNext(HWND hWnd)
{
ULONG (FAR PASCAL *lpfnMAPIFindNext) (LHANDLE lhSession, ULONG ulUIParam,
LPTSTR lpszMessageType, LPTSTR lpszSeedMessageID, FLAGS flFlags,
ULONG ulReserved, LPTSTR lpszMessageID);
#ifdef WIN16
(FARPROC&) lpfnMAPIFindNext = GetProcAddress(m_hInstMapi, "MAPIFINDNEXT");
#else
(FARPROC&) lpfnMAPIFindNext = GetProcAddress(m_hInstMapi, "MAPIFindNext");
#endif
if (!lpfnMAPIFindNext)
{
ShowMessage(hWnd, "Unable to locate MAPI function.");
return;
}
// Clear the list before we start...
ListBox_ResetContent(GetDlgItem(hWnd, ID_LIST_RESULT));
char msg[1024];
char messageID[512];
LONG rc;
#ifdef WIN32
FLAGS flags = MAPI_GUARANTEE_FIFO | MAPI_LONG_MSGID | MAPI_UNREAD_ONLY;
#else
FLAGS flags = MAPI_GUARANTEE_FIFO | MAPI_UNREAD_ONLY;
#endif
while ( (rc = (*lpfnMAPIFindNext) (mapiSession,
(ULONG) hWnd,
NULL,
NULL,
flags,
0,
messageID)) == SUCCESS_SUCCESS)
{
//
lpMapiMessage mapiMsg = GetMessage(hWnd, messageID);
if (mapiMsg != NULL)
{
wsprintf(msg, "%s: \"%s\" Sender: %s",
messageID,
mapiMsg->lpszSubject,
mapiMsg->lpOriginator->lpszName);
DoMAPIFreeBuffer(hWnd, mapiMsg, FALSE);
}
else
{
lstrcpy(msg, messageID);
}
ListBox_InsertString(GetDlgItem(hWnd, ID_LIST_RESULT), 0, msg);
}
wsprintf(msg, "Enumeration ended: Return code %d from MAPIFindNext\nCondition=[%s]",
rc, GetMAPIError(rc));
ShowMessage(hWnd, msg);
SetFooter("Enumeration ended");
}
void
DoMAPIReadMail(HWND hWnd)
{
ULONG (FAR PASCAL *lpfnMAPIReadMail) (LHANDLE lhSession, ULONG ulUIParam,
LPTSTR lpszMessageID, FLAGS flFlags, ULONG ulReserved,
lpMapiMessage FAR * lppMessage);
#ifdef WIN16
(FARPROC&) lpfnMAPIReadMail = GetProcAddress(m_hInstMapi, "MAPIREADMAIL");
#else
(FARPROC&) lpfnMAPIReadMail = GetProcAddress(m_hInstMapi, "MAPIReadMail");
#endif
if (!lpfnMAPIReadMail)
{
ShowMessage(hWnd, "Unable to locate MAPI function.");
return;
}
char msg[1024];
char lpszMessageID[512];
lpMapiMessage lpMessage = NULL;
FLAGS flFlags = 0;
DWORD selected = ListBox_GetCurSel(GetDlgItem(hWnd, ID_LIST_RESULT));
if (selected == LB_ERR)
{
ShowMessage(hWnd, "You need to select a valid message. Make sure\nyou have done a MAPIFindNext and selected\none of the resulting messages.");
return;
}
ListBox_GetText(GetDlgItem(hWnd, ID_LIST_RESULT), selected, lpszMessageID);
// Do the various flags for this call...
if (BST_CHECKED == Button_GetCheck(GetDlgItem(hWnd, IDC_CHECK_BODYASFILE)))
{
flFlags |= MAPI_BODY_AS_FILE;
}
if (BST_CHECKED == Button_GetCheck(GetDlgItem(hWnd, IDC_CHECK_ENVELOPEONLY)))
{
flFlags |= MAPI_ENVELOPE_ONLY;
}
if (BST_CHECKED == Button_GetCheck(GetDlgItem(hWnd, IDC_CHECK_PEEK)))
{
flFlags |= MAPI_PEEK;
}
if (BST_CHECKED == Button_GetCheck(GetDlgItem(hWnd, IDC_CHECK_SUPPRESSATTACH)))
{
flFlags |= MAPI_SUPPRESS_ATTACH;
}
char *ptr = strchr( (const char *) lpszMessageID, ':');
if (ptr) *ptr = '\0';
LONG rc = (*lpfnMAPIReadMail)
(mapiSession,
(ULONG) hWnd,
lpszMessageID,
flFlags,
0,
&lpMessage);
// Deal with error up front and return if need be...
if (rc != SUCCESS_SUCCESS)
{
wsprintf(msg, "FAILURE: Return code %d from MAPIReadMail\nError=[%s]",
rc, GetMAPIError(rc));
ShowMessage(hWnd, msg);
SetFooter("ReadMail failed");
return;
}
// Now display the message and then return...
DisplayMAPIReadMail(hWnd, lpMessage);
DoMAPIFreeBuffer(hWnd, lpMessage, TRUE);
}
void
DoMAPIDeleteMail(HWND hWnd)
{
ULONG (FAR PASCAL *lpfnMAPIDeleteMail) (LHANDLE lhSession, ULONG ulUIParam,
LPTSTR lpszMessageID, FLAGS flFlags, ULONG ulReserved);
#ifdef WIN16
(FARPROC&) lpfnMAPIDeleteMail = GetProcAddress(m_hInstMapi, "MAPIDELETEMAIL");
#else
(FARPROC&) lpfnMAPIDeleteMail = GetProcAddress(m_hInstMapi, "MAPIDeleteMail");
#endif
if (!lpfnMAPIDeleteMail)
{
ShowMessage(hWnd, "Unable to locate MAPI function.");
return;
}
char msg[1024];
char lpszMessageID[512];
lpMapiMessage lpMessage = NULL;
DWORD selected = ListBox_GetCurSel(GetDlgItem(hWnd, ID_LIST_RESULT));
if (selected == LB_ERR)
{
ShowMessage(hWnd, "You need to select a valid message. Make sure\nyou have done a MAPIFindNext and selected\none of the resulting messages.");
return;
}
ListBox_GetText(GetDlgItem(hWnd, ID_LIST_RESULT), selected, lpszMessageID);
char *ptr = strchr( (const char *) lpszMessageID, ':');
if (ptr) *ptr = '\0';
LONG rc = (*lpfnMAPIDeleteMail)
(mapiSession,
(ULONG) hWnd,
lpszMessageID,
0,
0);
// Deal with the return code...
if (rc == SUCCESS_SUCCESS)
{
wsprintf(msg, "Successful deletion");
ShowMessage(hWnd, msg);
SetFooter(msg);
// If it worked, refresh the list...
ShowMessage(hWnd, "The message list will now be refreshed\nsince one message was deleted.");
DoMAPIFindNext(hWnd);
}
else
{
wsprintf(msg, "FAILURE: Return code %d from MAPIDeleteMail\nError=[%s]",
rc, GetMAPIError(rc));
ShowMessage(hWnd, msg);
SetFooter("Logoff failed");
}
}
// This is for the name lookup stuff...
lpMapiRecipDesc lpRecip = NULL;
void
DoMAPIResolveName(HWND hWnd)
{
ULONG (FAR PASCAL *lpfnMAPIResolveName) (LHANDLE lhSession, ULONG ulUIParam,
LPTSTR lpszName, FLAGS flFlags, ULONG ulReserved,
lpMapiRecipDesc FAR * lppRecip);
#ifdef WIN16
(FARPROC&) lpfnMAPIResolveName = GetProcAddress(m_hInstMapi, "MAPIRESOLVENAME");
#else
(FARPROC&) lpfnMAPIResolveName = GetProcAddress(m_hInstMapi, "MAPIResolveName");
#endif
if (!lpfnMAPIResolveName)
{
ShowMessage(hWnd, "Unable to locate MAPI function.");
return;
}
if (lpRecip != NULL)
{
ShowMessage(hWnd, "We need to free memory from a previous call...");
DoMAPIFreeBuffer(hWnd, lpRecip, TRUE);
lpRecip = NULL;
}
char userName[512];
char msg[1024];
FLAGS flFlags = 0; // We support none...
GetDlgItemText(hWnd, IDC_EDIT_RESOLVENAME, userName, sizeof(userName));
LONG rc = (*lpfnMAPIResolveName)
(mapiSession,
(ULONG) hWnd,
userName,
flFlags,
0,
&lpRecip);
// Deal with error up front and return if need be...
if (rc != SUCCESS_SUCCESS)
{
wsprintf(msg, "FAILURE: Return code %d from DoMAPIResolveName\nError=[%s]",
rc, GetMAPIError(rc));
ShowMessage(hWnd, msg);
SetFooter("DoMAPIResolveName failed");
return;
}
// If we get here, we should probably show the information that we
// got back
wsprintf(msg, "Received information for %s\nName=[%s]\nAddress=[%s]\nID=[%s]",
userName, lpRecip->lpszName, lpRecip->lpszAddress, (LPSTR) lpRecip->lpEntryID);
ShowMessage(hWnd, msg);
}
void
DoMAPIResolveNameFreeBuffer(HWND hWnd)
{
if (lpRecip == NULL)
{
ShowMessage(hWnd, "There is no memory allocated from MAPIResolveName()\nto be freed. Request ignored.");
}
else
{
DoMAPIFreeBuffer(hWnd, lpRecip, TRUE);
lpRecip = NULL;
}
}
void
DoMAPIDetails(HWND hWnd)
{
ULONG (FAR PASCAL *lpfnMAPIDetails) (LHANDLE lhSession, ULONG ulUIParam,
lpMapiRecipDesc lpRecip, FLAGS flFlags, ULONG ulReserved);
#ifdef WIN16
(FARPROC&) lpfnMAPIDetails = GetProcAddress(m_hInstMapi, "MAPIDetails");
#else
(FARPROC&) lpfnMAPIDetails = GetProcAddress(m_hInstMapi, "MAPIDetails");
#endif
if (!lpfnMAPIDetails)
{
ShowMessage(hWnd, "Unable to locate MAPI function.");
return;
}
char msg[1024];
FLAGS flFlags = 0; // We really don't support these...
LONG rc = (*lpfnMAPIDetails)
(mapiSession,
(ULONG) hWnd,
lpRecip,
flFlags,
0);
if (rc == SUCCESS_SUCCESS)
{
wsprintf(msg, "MAPIDetails call succeeded");
ShowMessage(hWnd, msg);
SetFooter(msg);
}
else
{
wsprintf(msg, "FAILURE: Return code %d from MAPIDetails\nError=[%s]",
rc, GetMAPIError(rc));
if (lpRecip == NULL)
{
lstrcat(msg, "\nNOTE: There is no valid pointer from a MAPIResolveName()\ncall to show details about.");
}
ShowMessage(hWnd, msg);
SetFooter("MAPIDetails failed");
}
}
lpMapiMessage
GetMessage(HWND hWnd, LPSTR id)
{
ULONG (FAR PASCAL *lpfnMAPIReadMail) (LHANDLE lhSession, ULONG ulUIParam,
LPTSTR lpszMessageID, FLAGS flFlags, ULONG ulReserved,
lpMapiMessage FAR * lppMessage);
#ifdef WIN16
(FARPROC&) lpfnMAPIReadMail = GetProcAddress(m_hInstMapi, "MAPIREADMAIL");
#else
(FARPROC&) lpfnMAPIReadMail = GetProcAddress(m_hInstMapi, "MAPIReadMail");
#endif
if (!lpfnMAPIReadMail)
{
ShowMessage(hWnd, "Unable to locate MAPI function.");
return NULL;
}
char msg[1024];
lpMapiMessage lpMessage = NULL;
FLAGS flFlags = 0;
flFlags |= MAPI_ENVELOPE_ONLY;
LONG rc = (*lpfnMAPIReadMail)
(mapiSession,
(ULONG) hWnd,
id,
flFlags,
0,
&lpMessage);
// Deal with error up front and return if need be...
if (rc != SUCCESS_SUCCESS)
{
wsprintf(msg, "FAILURE: Return code %d from MAPIReadMail\nError=[%s]",
rc, GetMAPIError(rc));
ShowMessage(hWnd, msg);
SetFooter("ReadMail failed");
return NULL;
}
return(lpMessage);
}
void
LoadNSCPVersionFunc(HWND hWnd)
{
ULONG (FAR PASCAL *lpfnLoadNSCPVersion) ( void );
#ifdef WIN16
(FARPROC&) lpfnLoadNSCPVersion = GetProcAddress(m_hInstMapi, "MAPIGETNERSCAPEVERSION");
#else
(FARPROC&) lpfnLoadNSCPVersion = GetProcAddress(m_hInstMapi, "MAPIGetNetscapeVersion");
#endif
if (!lpfnLoadNSCPVersion)
{
ShowMessage(hWnd, "Unable to locate MAPIGetNetscapeVersion() function.");
}
else
{
ShowMessage(hWnd, "MAPIGetNetscapeVersion() function was FOUND!");
}
return;
}
void
DoMAPI_NSCP_Sync(HWND hWnd)
{
ULONG (FAR PASCAL *lpfnNSCPSync) ( LHANDLE lhSession,
ULONG ulReserved );
#ifdef WIN16
(FARPROC&) lpfnNSCPSync = GetProcAddress(m_hInstMapi, "MAPI_NSCP_SYNCHRONIZECLIENT");
#else
(FARPROC&) lpfnNSCPSync = GetProcAddress(m_hInstMapi, "MAPI_NSCP_SynchronizeClient");
#endif
if (!lpfnNSCPSync)
{
ShowMessage(hWnd, "Unable to locate MAPI function.");
return;
}
LONG rc = (*lpfnNSCPSync) (mapiSession, 0);
char msg[256];
// Deal with error up front and return if need be...
if (rc != SUCCESS_SUCCESS)
{
wsprintf(msg, "FAILURE: Return code %d from MAPI_NSCP_SynchronizeClient\nError=[%s]",
rc, GetMAPIError(rc));
ShowMessage(hWnd, msg);
SetFooter("MAPI_NSCP_SynchronizeClient failed");
return;
}
else
{
wsprintf(msg, "Success for MAPI_NSCP_SynchronizeClient");
ShowMessage(hWnd, msg);
SetFooter("MAPI_NSCP_SynchronizeClient success");
}
}

View File

@@ -0,0 +1,25 @@
# Microsoft Developer Studio Generated Dependency File, included by mapitest.mak
.\main.cpp : \
".\port.h"\
"c:\program files\msdev\vc98\include\basetsd.h"\
.\mapimail.cpp : \
".\port.h"\
"c:\program files\msdev\vc98\include\basetsd.h"\
.\mapiproc.cpp : \
".\port.h"\
"c:\program files\msdev\vc98\include\basetsd.h"\
.\mtest32.rc : \
".\nscicon.ico"\
.\readmail.cpp : \
".\port.h"\
"c:\program files\msdev\vc98\include\basetsd.h"\

View File

@@ -0,0 +1,121 @@
# Microsoft Developer Studio Project File - Name="mapitest" - Package Owner=<4>
# Microsoft Developer Studio Generated Build File, Format Version 6.00
# ** DO NOT EDIT **
# TARGTYPE "Win32 (x86) Application" 0x0101
CFG=mapitest - Win32 Debug
!MESSAGE This is not a valid makefile. To build this project using NMAKE,
!MESSAGE use the Export Makefile command and run
!MESSAGE
!MESSAGE NMAKE /f "mapitest.mak".
!MESSAGE
!MESSAGE You can specify a configuration when running NMAKE
!MESSAGE by defining the macro CFG on the command line. For example:
!MESSAGE
!MESSAGE NMAKE /f "mapitest.mak" CFG="mapitest - Win32 Debug"
!MESSAGE
!MESSAGE Possible choices for configuration are:
!MESSAGE
!MESSAGE "mapitest - Win32 Release" (based on "Win32 (x86) Application")
!MESSAGE "mapitest - Win32 Debug" (based on "Win32 (x86) Application")
!MESSAGE
# Begin Project
# PROP AllowPerConfigDependencies 0
# PROP Scc_ProjName ""
# PROP Scc_LocalPath ""
CPP=cl.exe
MTL=midl.exe
RSC=rc.exe
!IF "$(CFG)" == "mapitest - Win32 Release"
# PROP BASE Use_MFC 0
# PROP BASE Use_Debug_Libraries 0
# PROP BASE Output_Dir "Release"
# PROP BASE Intermediate_Dir "Release"
# PROP BASE Target_Dir ""
# PROP Use_MFC 0
# PROP Use_Debug_Libraries 0
# PROP Output_Dir "Release"
# PROP Intermediate_Dir "Release"
# PROP Target_Dir ""
# ADD BASE CPP /nologo /W3 /GX /O2 /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "_MBCS" /YX /FD /c
# ADD CPP /nologo /W3 /GX /O2 /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "_MBCS" /YX /FD /c
# ADD BASE MTL /nologo /D "NDEBUG" /mktyplib203 /win32
# ADD MTL /nologo /D "NDEBUG" /mktyplib203 /win32
# ADD BASE RSC /l 0x409 /d "NDEBUG"
# ADD RSC /l 0x409 /d "NDEBUG"
BSC32=bscmake.exe
# ADD BASE BSC32 /nologo
# ADD BSC32 /nologo
LINK32=link.exe
# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /subsystem:windows /machine:I386
# ADD LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /subsystem:windows /machine:I386
!ELSEIF "$(CFG)" == "mapitest - Win32 Debug"
# PROP BASE Use_MFC 0
# PROP BASE Use_Debug_Libraries 1
# PROP BASE Output_Dir "Debug"
# PROP BASE Intermediate_Dir "Debug"
# PROP BASE Target_Dir ""
# PROP Use_MFC 0
# PROP Use_Debug_Libraries 1
# PROP Output_Dir "Debug"
# PROP Intermediate_Dir "Debug"
# PROP Target_Dir ""
# ADD BASE CPP /nologo /W3 /Gm /GX /ZI /Od /D "WIN32" /D "_DEBUG" /D "_WINDOWS" /D "_MBCS" /YX /FD /GZ /c
# ADD CPP /nologo /W3 /Gm /GX /ZI /Od /D "WIN32" /D "_DEBUG" /D "_WINDOWS" /D "_MBCS" /YX /FD /GZ /c
# ADD BASE MTL /nologo /D "_DEBUG" /mktyplib203 /win32
# ADD MTL /nologo /D "_DEBUG" /mktyplib203 /win32
# ADD BASE RSC /l 0x409 /d "_DEBUG"
# ADD RSC /l 0x409 /d "_DEBUG"
BSC32=bscmake.exe
# ADD BASE BSC32 /nologo
# ADD BSC32 /nologo
LINK32=link.exe
# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /subsystem:windows /debug /machine:I386 /pdbtype:sept
# ADD LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /subsystem:windows /debug /machine:I386 /pdbtype:sept
!ENDIF
# Begin Target
# Name "mapitest - Win32 Release"
# Name "mapitest - Win32 Debug"
# Begin Group "Source Files"
# PROP Default_Filter "cpp;c;cxx;rc;def;r;odl;idl;hpj;bat"
# Begin Source File
SOURCE=.\main.cpp
# End Source File
# Begin Source File
SOURCE=.\mapimail.cpp
# End Source File
# Begin Source File
SOURCE=.\mapiproc.cpp
# End Source File
# Begin Source File
SOURCE=.\mtest32.rc
# End Source File
# Begin Source File
SOURCE=.\readmail.cpp
# End Source File
# End Group
# Begin Group "Header Files"
# PROP Default_Filter "h;hpp;hxx;hm;inl"
# End Group
# Begin Group "Resource Files"
# PROP Default_Filter "ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe"
# End Group
# End Target
# End Project

View File

@@ -0,0 +1,29 @@
Microsoft Developer Studio Workspace File, Format Version 6.00
# WARNING: DO NOT EDIT OR DELETE THIS WORKSPACE FILE!
###############################################################################
Project: "mapitest"=.\mapitest.dsp - Package Owner=<4>
Package=<5>
{{{
}}}
Package=<4>
{{{
}}}
###############################################################################
Global:
Package=<5>
{{{
}}}
Package=<3>
{{{
}}}
###############################################################################

Binary file not shown.

Binary file not shown.

View File

@@ -0,0 +1,44 @@
<html>
<body>
<pre>
<h1>Build Log</h1>
<h3>
--------------------Configuration: mapitest - Win32 Debug--------------------
</h3>
<h3>Command Lines</h3>
Creating command line "rc.exe /l 0x409 /fo"Debug/mtest32.res" /d "_DEBUG" "Y:\mozilla\mailnews\mapi\tests\mapitest\mtest32.rc""
Creating temporary file "C:\TEMP\RSP38A.tmp" with contents
[
/nologo /MLd /W3 /Gm /GX /ZI /Od /D "WIN32" /D "_DEBUG" /D "_WINDOWS" /D "_MBCS" /Fp"Debug/mapitest.pch" /YX /Fo"Debug/" /Fd"Debug/" /FD /GZ /c
"Y:\mozilla\mailnews\mapi\tests\mapitest\readmail.cpp"
"Y:\mozilla\mailnews\mapi\tests\mapitest\mapimail.cpp"
"Y:\mozilla\mailnews\mapi\tests\mapitest\mapiproc.cpp"
"Y:\mozilla\mailnews\mapi\tests\mapitest\main.cpp"
]
Creating command line "cl.exe @C:\TEMP\RSP38A.tmp"
Creating temporary file "C:\TEMP\RSP38B.tmp" with contents
[
kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /subsystem:windows /incremental:yes /pdb:"Debug/mapitest.pdb" /debug /machine:I386 /out:"Debug/mapitest.exe" /pdbtype:sept
.\Debug\readmail.obj
.\Debug\mapimail.obj
.\Debug\mapiproc.obj
.\Debug\mtest32.res
.\Debug\main.obj
]
Creating command line "link.exe @C:\TEMP\RSP38B.tmp"
<h3>Output Window</h3>
Compiling resources...
Compiling...
readmail.cpp
mapimail.cpp
mapiproc.cpp
main.cpp
Linking...
<h3>Results</h3>
mapitest.exe - 0 error(s), 0 warning(s)
</pre>
</body>
</html>

View File

@@ -0,0 +1,245 @@
//Microsoft Developer Studio generated resource script.
//
#include "resource.h"
#define APSTUDIO_READONLY_SYMBOLS
/////////////////////////////////////////////////////////////////////////////
//
// Generated from the TEXTINCLUDE 2 resource.
//
#include "afxres.h"
/////////////////////////////////////////////////////////////////////////////
#undef APSTUDIO_READONLY_SYMBOLS
/////////////////////////////////////////////////////////////////////////////
// English (U.S.) resources
#if !defined(AFX_RESOURCE_DLL) || defined(AFX_TARG_ENU)
#ifdef _WIN32
LANGUAGE LANG_ENGLISH, SUBLANG_ENGLISH_US
#pragma code_page(1252)
#endif //_WIN32
/////////////////////////////////////////////////////////////////////////////
//
// Dialog
//
ID_DIALOG DIALOG DISCARDABLE 0, 0, 344, 229
STYLE DS_MODALFRAME | WS_MINIMIZEBOX | WS_POPUP | WS_CAPTION | WS_SYSMENU
CAPTION "Netscape MAPI Test Harness"
MENU ID_MENU
FONT 8, "MS Sans Serif"
BEGIN
GROUPBOX "Open/Close",IDC_STATIC,4,4,336,27
LTEXT "User:",IDC_STATIC,9,17,18,11
EDITTEXT ID_EDIT_USERNAME,28,15,41,12,ES_AUTOHSCROLL
LTEXT "Password:",IDC_STATIC,74,17,38,11
EDITTEXT ID_EDIT_PW,112,15,41,12,ES_PASSWORD | ES_AUTOHSCROLL
PUSHBUTTON "MAPILogon",ID_BUTTON_LOGON,157,13,46,14
PUSHBUTTON "MAPILogoff",ID_BUTTON_LOGOFF,209,13,46,14
GROUPBOX "Mail Operations",IDC_STATIC,4,36,336,142
PUSHBUTTON "MAPIFindNext",ID_BUTTON_FINDNEXT,17,50,57,14
PUSHBUTTON "MAPIDeleteMail",ID_BUTTON_DELETEMAIL,80,50,57,14
PUSHBUTTON "Clear Results",ID_BUTTON_CLEAR,143,50,57,14
PUSHBUTTON "Send Mail",ID_BUTTON_MAIL,206,50,57,14
LISTBOX ID_LIST_RESULT,9,66,325,56,LBS_SORT |
LBS_NOINTEGRALHEIGHT | WS_VSCROLL | WS_HSCROLL |
WS_TABSTOP
GROUPBOX "User Information",IDC_STATIC,4,181,336,28
PUSHBUTTON "MAPIResolveName",ID_BUTTON_RESOLVENAME,9,192,68,14
EDITTEXT IDC_EDIT_RESOLVENAME,82,192,130,14,ES_AUTOHSCROLL
PUSHBUTTON "MAPIDetails",ID_BUTTON_DETAILS,219,192,48,14
LTEXT "",ID_STATIC_RESULT,4,214,336,13,SS_SUNKEN
PUSHBUTTON "MAPIReadMail",ID_BUTTON_READMAIL,34,142,57,14
CONTROL "MAPI_BODY_AS_FILE - Body as attachment",
IDC_CHECK_BODYASFILE,"Button",BS_AUTOCHECKBOX |
WS_TABSTOP,121,125,188,9
CONTROL "MAPI_ENVELOPE_ONLY - Header information only",
IDC_CHECK_ENVELOPEONLY,"Button",BS_AUTOCHECKBOX |
WS_TABSTOP,121,138,188,9
CONTROL "MAPI_PEEK - Don't mark message as read",IDC_CHECK_PEEK,
"Button",BS_AUTOCHECKBOX | WS_TABSTOP,121,151,188,9
CONTROL "MAPI_SUPPRESS_ATTACH - Suppress attachments",
IDC_CHECK_SUPPRESSATTACH,"Button",BS_AUTOCHECKBOX |
WS_TABSTOP,121,164,188,9
PUSHBUTTON "<- MAPIFreeBuffer",ID_BUTTON_FREEBUFFER,272,192,63,14
PUSHBUTTON "MAPIGetNSCPVersion",ID_BUTTON_NSCPVERSION,261,13,76,14
PUSHBUTTON "Synchronize",ID_BUTTON_SYNC,269,50,57,14
END
ID_DIALOG_MAIL DIALOG DISCARDABLE 0, 0, 285, 246
STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU
CAPTION "Composition"
FONT 8, "MS Sans Serif"
BEGIN
GROUPBOX "Address Information",IDC_STATIC,4,4,275,55
LTEXT "To:",IDC_STATIC,21,19,12,8
EDITTEXT ID_EDIT_TOADDRESS,36,16,239,13,ES_AUTOHSCROLL
EDITTEXT ID_EDIT_CCADDRESS,36,30,239,13,ES_AUTOHSCROLL
EDITTEXT ID_EDIT_BCCADDRESS,36,44,239,13,ES_AUTOHSCROLL
LTEXT "Subject:",IDC_STATIC,5,65,29,9
EDITTEXT ID_EDIT_SUBJECT,36,63,239,13,ES_AUTOHSCROLL
EDITTEXT ID_EDIT_NOTETEXT,4,78,271,72,ES_MULTILINE |
ES_AUTOHSCROLL
GROUPBOX "Attachments",IDC_STATIC,4,153,275,39
EDITTEXT ID_EDIT_ATTACH1,16,162,122,13,ES_AUTOHSCROLL
EDITTEXT ID_EDIT_ATTACH2,16,176,122,13,ES_AUTOHSCROLL
EDITTEXT ID_EDIT_ATTACH3,147,162,122,13,ES_AUTOHSCROLL
EDITTEXT ID_EDIT_ATTACH4,147,175,122,13,ES_AUTOHSCROLL
PUSHBUTTON "MAPISendMail",ID_BUTTON_MAPISENDMAIL,70,204,58,14
PUSHBUTTON "Cancel",IDCANCEL,50,225,84,14
PUSHBUTTON "MAPISendDocuments",ID_BUTTON_MAPISENDDOCUMENTS,132,204,
79,14
CONTROL "Show Dialog",ID_CHECK_SHOWDIALOG,"Button",
BS_AUTOCHECKBOX | WS_TABSTOP,8,207,55,9
LTEXT "cc:",IDC_STATIC,22,32,12,8
LTEXT "bcc:",IDC_STATIC,18,47,15,8
GROUPBOX "Send Operations",IDC_STATIC,4,196,275,26
PUSHBUTTON "MAPISaveMail",ID_BUTTON_MAPISAVEMAIL,215,204,57,14
PUSHBUTTON "MAPIAddress",ID_BUTTON_MAPIADDRESS,150,225,84,14
END
ID_DIALOG_READMAIL DIALOG DISCARDABLE 0, 0, 269, 266
STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU
CAPTION "Mail Message"
FONT 8, "MS Sans Serif"
BEGIN
LTEXT "Subject:",IDC_STATIC,5,71,27,9
EDITTEXT IDC_EDIT_SUBJECT,36,69,229,12,ES_AUTOHSCROLL |
ES_READONLY
LISTBOX IDC_LIST_ATTACHMENTS,4,211,261,37,LBS_SORT |
LBS_NOINTEGRALHEIGHT | WS_VSCROLL | WS_TABSTOP
EDITTEXT IDC_EDIT_BODYTEXT,4,113,261,85,ES_MULTILINE |
ES_AUTOVSCROLL | ES_AUTOHSCROLL | ES_READONLY |
ES_WANTRETURN
LISTBOX IDC_LIST_RECIPIENTS,4,29,261,36,LBS_SORT |
LBS_NOINTEGRALHEIGHT | WS_VSCROLL | WS_TABSTOP
LTEXT "Recipients:",IDC_STATIC,4,19,43,9
LTEXT "Attachments:",IDC_STATIC,4,202,43,9
EDITTEXT IDC_EDIT_DATETIME,36,83,229,12,ES_AUTOHSCROLL |
ES_READONLY
LTEXT "Date:",IDC_STATIC,13,84,19,9
PUSHBUTTON "OK",ID_OK,114,249,42,13
EDITTEXT IDC_EDIT_THREAD,36,97,229,12,ES_AUTOHSCROLL |
ES_READONLY
LTEXT "Thread:",IDC_STATIC,6,99,25,9
LTEXT "From:",IDC_STATIC,4,6,19,9
EDITTEXT IDC_EDIT_FROM,27,4,238,12,ES_AUTOHSCROLL | ES_READONLY
END
/////////////////////////////////////////////////////////////////////////////
//
// DESIGNINFO
//
#ifdef APSTUDIO_INVOKED
GUIDELINES DESIGNINFO DISCARDABLE
BEGIN
ID_DIALOG, DIALOG
BEGIN
LEFTMARGIN, 4
RIGHTMARGIN, 340
VERTGUIDE, 9
VERTGUIDE, 309
TOPMARGIN, 4
BOTTOMMARGIN, 227
HORZGUIDE, 206
END
ID_DIALOG_MAIL, DIALOG
BEGIN
LEFTMARGIN, 4
RIGHTMARGIN, 281
TOPMARGIN, 4
BOTTOMMARGIN, 239
END
ID_DIALOG_READMAIL, DIALOG
BEGIN
LEFTMARGIN, 4
RIGHTMARGIN, 265
TOPMARGIN, 4
BOTTOMMARGIN, 262
END
END
#endif // APSTUDIO_INVOKED
#ifdef APSTUDIO_INVOKED
/////////////////////////////////////////////////////////////////////////////
//
// TEXTINCLUDE
//
1 TEXTINCLUDE DISCARDABLE
BEGIN
"resource.h\0"
END
2 TEXTINCLUDE DISCARDABLE
BEGIN
"#include ""afxres.h""\r\n"
"\0"
END
3 TEXTINCLUDE DISCARDABLE
BEGIN
"\r\n"
"\0"
END
#endif // APSTUDIO_INVOKED
/////////////////////////////////////////////////////////////////////////////
//
// Icon
//
// Icon with lowest ID value placed first to ensure application icon
// remains consistent on all systems.
ID_ICON_APP ICON DISCARDABLE "nscicon.ico"
/////////////////////////////////////////////////////////////////////////////
//
// Menu
//
ID_MENU MENU DISCARDABLE
BEGIN
POPUP "&File"
BEGIN
MENUITEM "MAPI&FindNext", ID_MENU_MAPIFINDNEXT
MENUITEM "MAPI&ReadMail", ID_MENU_MAPIREADMAIL
MENUITEM SEPARATOR
MENUITEM "E&xit", ID_MENU_MYEXIT
END
POPUP "&Edit"
BEGIN
MENUITEM "MAPI&DeleteMail", ID_MENU_MAPIDELETEMAIL
MENUITEM "&Clear Results", ID_MENU_CLEARRESULTS
END
POPUP "&Help"
BEGIN
MENUITEM "&About...", ID_MENU_MYABOUT
END
END
#endif // English (U.S.) resources
/////////////////////////////////////////////////////////////////////////////
#ifndef APSTUDIO_INVOKED
/////////////////////////////////////////////////////////////////////////////
//
// Generated from the TEXTINCLUDE 3 resource.
//
/////////////////////////////////////////////////////////////////////////////
#endif // not APSTUDIO_INVOKED

Binary file not shown.

After

Width:  |  Height:  |  Size: 766 B

View File

@@ -0,0 +1,303 @@
/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
/* ***** BEGIN LICENSE BLOCK *****
* Version: NPL 1.1/GPL 2.0/LGPL 2.1
*
* The contents of this file are subject to the Netscape Public License
* Version 1.1 (the "License"); you may not use this file except in
* compliance with the License. You may obtain a copy of the License at
* http://www.mozilla.org/NPL/
*
* Software distributed under the License is distributed on an "AS IS" basis,
* WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
* for the specific language governing rights and limitations under the
* License.
*
* The Original Code is mozilla.org code.
*
* The Initial Developer of the Original Code is
* Netscape Communications Corporation.
* Portions created by the Initial Developer are Copyright (C) 1998
* the Initial Developer. All Rights Reserved.
*
* Contributor(s):
*
* Alternatively, the contents of this file may be used under the terms of
* either the GNU General Public License Version 2 or later (the "GPL"), or
* the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
* in which case the provisions of the GPL or the LGPL are applicable instead
* of those above. If you wish to allow use of your version of this file only
* under the terms of either the GPL or the LGPL, and not to allow others to
* use your version of this file under the terms of the NPL, indicate your
* decision by deleting the provisions above and replace them with the notice
* and other provisions required by the GPL or the LGPL. If you do not delete
* the provisions above, a recipient may use your version of this file under
* the terms of any one of the NPL, the GPL or the LGPL.
*
* ***** END LICENSE BLOCK ***** */
//
#ifndef PORT_H
#define PORT_H
#ifdef __cplusplus
extern "C" {
#endif
/*****************************************************************\
* *
* PORT.H *
* *
* Win16/Win32 portability stuff *
* *
* A.Sokolsky *
* 3.10.94 distilled into this header *
* *
\*****************************************************************/
/*
* calling conventions
*/
#include <assert.h>
#ifndef CDECL
#define CDECL __cdecl
#endif // CDECL
#ifndef PASCAL
#define PASCAL __pascal
#endif // PASCAL
#ifdef FASTCALL
#error FASTCALL defined
#endif // FASTCALL
#ifdef NDEBUG
#define FASTCALL __fastcall
#else
#define FASTCALL PASCAL
#endif // NDEBUG
#ifndef HWND2DWORD
# ifdef WIN32
# define HWND2DWORD(X_hWnd) ( (DWORD)(X_hWnd) )
# else // WIN16
# define HWND2DWORD(X_hWnd) ( (DWORD)MAKELONG(((WORD)(X_hWnd)), 0) )
# endif
#endif // HWND2DWORD
/*
* WIN16 - WIN32 compatibility stuff
*/
#ifdef WIN32
# define DLLEXPORT __declspec( dllexport )
# define EXPORT
# define LOADDS
# define HUGE
# ifndef FAR
# define FAR
# endif // FAR
# ifndef NEAR
# define NEAR
# endif // NEAR
# ifdef UNICODE
# define SIZEOF(x) (sizeof(x)/sizeof(WCHAR))
# else
# define SIZEOF(x) sizeof(x)
# endif
#else // !WIN32 == WIN16
# define DLLEXPORT
# define EXPORT __export
# define LOADDS __loadds
# define HUGE __huge
# ifndef FAR
# define FAR __far
# define NEAR __near
# endif // FAR
# define CONST const
# define SIZEOF(x) sizeof(x)
# define CHAR char
# define TCHAR char
# define WCHAR char
# ifndef LPTSTR
# define LPTSTR LPSTR
# endif
# ifndef LPCTSTR
# define LPCTSTR LPCSTR
# endif
# define UNREFERENCED_PARAMETER(x) x;
# ifndef TEXT
# define TEXT(x) x
# endif
# define GetWindowTextW GetWindowText
# define lstrcpyW lstrcpy
# define BN_DBLCLK BN_DOUBLECLICKED // ~~MRJ needed for custom control.
// ~~MRJ begin Win95 backward compat section
# define LPWSTR LPSTR
# define LPCWSTR LPCSTR
// button check state for WIN16
#ifndef BST_UNCHECKED
#define BST_UNCHECKED 0x0000
#endif
#ifndef BST_CHECKED
#define BST_CHECKED 0x0001
#endif
#ifndef WIN95_COMPAT
# define WIN95_COMPAT
#endif
// ~~MRJ end Win95 compat section.
// critical section API stubs
typedef DWORD CRITICAL_SECTION;
typedef CRITICAL_SECTION FAR * LPCRITICAL_SECTION;
#ifdef __cplusplus
inline void InitializeCriticalSection(LPCRITICAL_SECTION lpSection) {}
inline void DeleteCriticalSection(LPCRITICAL_SECTION lpSection) {}
inline void EnterCriticalSection(LPCRITICAL_SECTION lpSection) {}
inline void LeaveCriticalSection(LPCRITICAL_SECTION lpSection) {}
#endif // __cplusplus
// Added for nssock16 ---Neeti
#ifndef ZeroMemory
#include <memory.h>
#define ZeroMemory(PTR, SIZE) memset(PTR, 0, SIZE)
#endif // ZeroMemory
#endif // WIN16
/*
* unix - windows compatibility stuff
*/
typedef DWORD u_int32;
typedef WORD u_int16;
typedef BYTE u_int8;
#ifdef WIN32
typedef short int Bool16;
#else // WIN16
typedef BOOL Bool16;
#endif // WIN16
/*
* Cross Platform Compatibility
*/
#ifndef UNALIGNED
# ifdef _M_ALPHA
# define UNALIGNED __unaligned
# else // !_M_ALPHA
# define UNALIGNED
# endif // !_M_ALPHA
#endif // UNALIGNED
//
// RICHIE - for the Alpha port
//
#ifdef _M_ALPHA
# undef pascal
# undef PASCAL
# if (_MSC_VER >= 800) || defined(_STDCALL_SUPPORTED)
# define pascal __stdcall
# define PASCAL __stdcall
# else
# define PASCAL
# endif
#endif
/*
* Useful Types
*/
typedef char HUGE *HPSTR;
typedef const char HUGE *HPCSTR;
typedef unsigned char HUGE *HPBYTE;
typedef WORD HUGE *HPWORD;
typedef UINT FAR *LPUINT;
typedef BOOL (CALLBACK *USERABORTPROC)();
typedef BOOL (CALLBACK *PROGRESSPROC)(UINT uPos, UINT uRange);
typedef int INT; // ~~MRJ a function needed this defined.
typedef MINMAXINFO FAR *LPMINMAXINFO; // ~~MRJ
//
// stuff missing from windows.h
//
#ifndef MAKEWORD
#define MAKEWORD(low, high) ((WORD)(((BYTE)(low)) | (((WORD)((BYTE)(high))) << 8)))
#endif // MAKEWORD
#ifdef WIN32
# ifndef hmemcpy
# define hmemcpy memcpy
# endif // !defined(hmemcpy)
# define _fmemset memset
# include <malloc.h>
#ifdef __cplusplus
inline BOOL IsGDIObject(HGDIOBJ hObj) { return (hObj != 0); }
inline void *_halloc(long num, unsigned int size) { return malloc(num * size); }
inline void _hfree( void *memblock ) { free(memblock); }
/*
inline BOOL IsInstance(HINSTANCE hInst) {
# ifdef WIN32
return (hInst != 0);
# else // WIN16
return (hInst > HINSTANCE_ERROR);
# endif
}
*/
#endif // __cplusplus
WINUSERAPI HANDLE WINAPI LoadImageA(HINSTANCE, LPCSTR, UINT, int, int, UINT);
#endif // WIN32
#ifdef __cplusplus
inline BOOL IsInstance(HINSTANCE hInst) {
# ifdef WIN32
return (hInst != 0);
# else // WIN16
return (hInst > HINSTANCE_ERROR);
# endif
}
inline void SetWindowSmallIcon(HINSTANCE hInst, HWND hWnd, UINT uIconResourceId) {
#ifdef WIN32
# ifndef WM_SETICON
# define WM_SETICON 0x0080
# endif // WM_SETICON
# ifndef IMAGE_ICON
# define IMAGE_ICON 1
# endif
assert(IsWindow(hWnd));
HICON hIcon = (HICON)LoadImageA(hInst, MAKEINTRESOURCE(uIconResourceId), IMAGE_ICON,
16, 16, 0);
if(NULL != hIcon) {
SendMessage(hWnd, WM_SETICON, FALSE, (LPARAM)hIcon);
} else {
HICON hIcon = LoadIcon(hInst, MAKEINTRESOURCE(uIconResourceId));
assert(hIcon != 0);
SendMessage(hWnd, WM_SETICON, FALSE, (LPARAM)hIcon);
}
#endif // WIN32
}
#endif // __cplusplus
#ifdef __cplusplus
}
#endif /* __cplusplus */
#endif /* PORT_H */

View File

@@ -0,0 +1,137 @@
/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
/* ***** BEGIN LICENSE BLOCK *****
* Version: NPL 1.1/GPL 2.0/LGPL 2.1
*
* The contents of this file are subject to the Netscape Public License
* Version 1.1 (the "License"); you may not use this file except in
* compliance with the License. You may obtain a copy of the License at
* http://www.mozilla.org/NPL/
*
* Software distributed under the License is distributed on an "AS IS" basis,
* WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
* for the specific language governing rights and limitations under the
* License.
*
* The Original Code is mozilla.org code.
*
* The Initial Developer of the Original Code is
* Netscape Communications Corporation.
* Portions created by the Initial Developer are Copyright (C) 1998
* the Initial Developer. All Rights Reserved.
*
* Contributor(s):
*
* Alternatively, the contents of this file may be used under the terms of
* either the GNU General Public License Version 2 or later (the "GPL"), or
* the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
* in which case the provisions of the GPL or the LGPL are applicable instead
* of those above. If you wish to allow use of your version of this file only
* under the terms of either the GPL or the LGPL, and not to allow others to
* use your version of this file under the terms of the NPL, indicate your
* decision by deleting the provisions above and replace them with the notice
* and other provisions required by the GPL or the LGPL. If you do not delete
* the provisions above, a recipient may use your version of this file under
* the terms of any one of the NPL, the GPL or the LGPL.
*
* ***** END LICENSE BLOCK ***** */
//
#include <windows.h>
#include <windowsx.h>
#ifndef MAPI_OLE // Because MSFT doesn't do this for us :-(
#include <mapi.h>
#endif
#include "port.h"
#include "resource.h"
//
// Variables...
//
extern HINSTANCE hInst;
extern HINSTANCE m_hInstMapi;
extern LHANDLE mapiSession;
//
// Forward declarations...
//
extern void ShowMessage(HWND hWnd, LPSTR msg);
extern void SetFooter(LPSTR msg);
extern LPSTR GetMAPIError(LONG errorCode);
lpMapiMessage mailPtr = NULL;
void
ProcessReadMailCommand(HWND hWnd, int id, HWND hCtl, UINT codeNotify)
{
switch (id)
{
case ID_OK:
case IDCANCEL:
EndDialog(hWnd, 0);
break;
default:
break;
}
}
BOOL CALLBACK LOADDS
ReadMailDlgProc(HWND hWndMail, UINT wMsg, WPARAM wParam, LPARAM lParam)
{
switch (wMsg)
{
case WM_INITDIALOG:
{
DWORD i;
// Do everything we need to display the message pointed to by
// mailPtr
if (!mailPtr)
break;
// Start with the basics...
SetDlgItemText(hWndMail, IDC_EDIT_SUBJECT, mailPtr->lpszSubject);
SetDlgItemText(hWndMail, IDC_EDIT_DATETIME, mailPtr->lpszDateReceived);
SetDlgItemText(hWndMail, IDC_EDIT_THREAD, mailPtr->lpszConversationID);
SetDlgItemText(hWndMail, IDC_EDIT_BODYTEXT, mailPtr->lpszNoteText);
char buf[1024];
wsprintf(buf, "%s (%s)", mailPtr->lpOriginator->lpszName,
mailPtr->lpOriginator->lpszAddress);
SetDlgItemText(hWndMail, IDC_EDIT_FROM, buf);
for (i=0; i<mailPtr->nRecipCount; i++)
{
wsprintf(buf, "%s (%s)", mailPtr->lpRecips[i].lpszName,
mailPtr->lpRecips[i].lpszAddress);
ListBox_InsertString(GetDlgItem(hWndMail, IDC_LIST_RECIPIENTS),
ListBox_GetCount(GetDlgItem(hWndMail, IDC_LIST_RECIPIENTS)),
buf);
}
for (i=0; i<mailPtr->nFileCount; i++)
{
ListBox_InsertString(GetDlgItem(hWndMail, IDC_LIST_ATTACHMENTS),
ListBox_GetCount(GetDlgItem(hWndMail, IDC_LIST_ATTACHMENTS)),
mailPtr->lpFiles[i].lpszPathName);
}
}
break;
case WM_COMMAND:
HANDLE_WM_COMMAND(hWndMail, wParam, lParam, ProcessReadMailCommand);
break;
default:
return FALSE;
}
return TRUE;
}
void
DisplayMAPIReadMail(HWND hWnd, lpMapiMessage msgPtr)
{
mailPtr = msgPtr;
DialogBox(hInst, MAKEINTRESOURCE(ID_DIALOG_READMAIL), hWnd,
(DLGPROC)ReadMailDlgProc);
}

View File

@@ -0,0 +1,108 @@
//{{NO_DEPENDENCIES}}
// Microsoft Developer Studio generated include file.
// Used by mtest32.rc
//
/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 2 -*-
*
* The contents of this file are subject to the Netscape Public
* License Version 1.1 (the "License"); you may not use this file
* except in compliance with the License. You may obtain a copy of
* the License at http://www.mozilla.org/NPL/
*
* Software distributed under the License is distributed on an "AS
* IS" basis, WITHOUT WARRANTY OF ANY KIND, either express or
* implied. See the License for the specific language governing
* rights and limitations under the License.
*
* The Original Code is mozilla.org code.
*
* The Initial Developer of the Original Code is Netscape
* Communications Corporation. Portions created by Netscape are
* Copyright (C) 1998 Netscape Communications Corporation. All
* Rights Reserved.
*
* Contributor(s):
*/
#define ID_GUI_MESSAGE1 1
#define ID_BUTTON_MAPIADDRESS 3
#define ID_DIALOG 101
#define ID_ICON_APP 102
#define ID_MENU 104
#define ID_DIALOG_MAIL 105
#define ID_DIALOG_READMAIL 106
#define ID_SETFROMEDIT 1000
#define ID_SETTEXT 1001
#define ID_GETROWS 1001
#define ID_EDIT 1002
#define ID_EDIT_HWND 1002
#define ID_RESOURCETEXT 1003
#define ID_GETTEXT 1003
#define ID_STATIC_RESULT 1004
#define ID_GETVISROWS 1005
#define ID_GETWINID 1006
#define ID_SETROWFOCUS 1007
#define ID_GETROWFOCUS 1008
#define ID_EDIT_ROW 1009
#define ID_LIST_RESULT 1010
#define ID_GETCOLCOUNT 1011
#define ID_BUTTON_LOGON 1011
#define ID_SETROWINVIEW 1012
#define ID_BUTTON_LOGOFF 1012
#define ID_GETNUMCHILDREN 1013
#define ID_EDIT_USERNAME 1013
#define ID_CLEARRESULTS 1014
#define ID_EDIT_PW 1014
#define ID_BUTTON_FINDNEXT 1015
#define ID_BUTTON_CLEAR 1016
#define ID_BUTTON_READMAIL 1017
#define ID_BUTTON_DELETEMAIL 1018
#define IDC_EDIT_RESOLVENAME 1019
#define ID_BUTTON_MAPISENDMAIL 1020
#define ID_BUTTON_NSCPVERSION 1020
#define ID_BUTTON_RESOLVENAME 1021
#define ID_BUTTON_MAPISENDDOCUMENTS 1021
#define ID_EDIT_TOADDRESS 1022
#define ID_EDIT_CCADDRESS 1023
#define ID_BUTTON_DETAILS 1024
#define ID_EDIT_BCCADDRESS 1024
#define ID_EDIT_SUBJECT 1025
#define ID_BUTTON_MAIL 1025
#define ID_BUTTON_FREEBUFFER 1026
#define ID_EDIT_NOTETEXT 1026
#define ID_EDIT_ATTACH1 1027
#define ID_BUTTON_SYNC 1027
#define ID_EDIT_ATTACH2 1028
#define IDC_CHECK_BODYASFILE 1028
#define ID_EDIT_ATTACH3 1029
#define IDC_CHECK_ENVELOPEONLY 1029
#define IDC_LIST_ATTACHMENTS 1029
#define ID_EDIT_ATTACH4 1030
#define IDC_CHECK_PEEK 1030
#define IDC_EDIT_BODYTEXT 1030
#define IDC_CHECK_SUPPRESSATTACH 1031
#define IDC_LIST_RECIPIENTS 1031
#define ID_BUTTON_MAPISAVEMAIL 1031
#define IDC_EDIT_SUBJECT 1032
#define IDC_EDIT_DATETIME 1033
#define ID_OK 1034
#define IDC_EDIT_THREAD 1035
#define ID_CHECK_SHOWDIALOG 1035
#define IDC_EDIT_FROM 1036
#define ID_MENU_MYEXIT 30001
#define ID_MENU_CLEAR 30002
#define ID_MENU_MYABOUT 30003
#define ID_MENU_CLEARRESULTS 30004
#define ID_MENU_MAPIDELETEMAIL 30005
#define ID_MENU_MAPIFINDNEXT 30006
#define ID_MENU_MAPIREADMAIL 30007
// Next default values for new objects
//
#ifdef APSTUDIO_INVOKED
#ifndef APSTUDIO_READONLY_SYMBOLS
#define _APS_NEXT_RESOURCE_VALUE 107
#define _APS_NEXT_COMMAND_VALUE 30008
#define _APS_NEXT_CONTROL_VALUE 1036
#define _APS_NEXT_SYMED_VALUE 101
#endif
#endif

View File

@@ -1,42 +0,0 @@
# ***** BEGIN LICENSE BLOCK *****
# Version: MPL 1.1/GPL 2.0/LGPL 2.1
#
# The contents of this file are subject to the Mozilla Public License Version
# 1.1 (the "License"); you may not use this file except in compliance with
# the License. You may obtain a copy of the License at
# http://www.mozilla.org/MPL/
#
# Software distributed under the License is distributed on an "AS IS" basis,
# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
# for the specific language governing rights and limitations under the
# License.
#
# The Original Code is mozilla.org code.
#
# The Initial Developer of the Original Code is
# Netscape Communications Corporation.
# Portions created by the Initial Developer are Copyright (C) 2001
# the Initial Developer. All Rights Reserved.
#
# Contributor(s):
# Srilatha Moturi <srilatha@netscape.com>
#
# Alternatively, the contents of this file may be used under the terms of
# either the GNU General Public License Version 2 or later (the "GPL"), or
# the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
# in which case the provisions of the GPL or the LGPL are applicable instead
# of those above. If you wish to allow use of your version of this file only
# under the terms of either the GPL or the LGPL, and not to allow others to
# use your version of this file under the terms of the MPL, indicate your
# decision by deleting the provisions above and replace them with the notice
# and other provisions required by the GPL or the LGPL. If you do not delete
# the provisions above, a recipient may use your version of this file under
# the terms of any one of the MPL, the GPL or the LGPL.
#
# ***** END LICENSE BLOCK *****
DEPTH=..\..\..
DIRS=public src
include <$(DEPTH)\config\rules.mak>

View File

@@ -1,48 +0,0 @@
# ***** BEGIN LICENSE BLOCK *****
# Version: MPL 1.1/GPL 2.0/LGPL 2.1
#
# The contents of this file are subject to the Mozilla Public License Version
# 1.1 (the "License"); you may not use this file except in compliance with
# the License. You may obtain a copy of the License at
# http://www.mozilla.org/MPL/
#
# Software distributed under the License is distributed on an "AS IS" basis,
# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
# for the specific language governing rights and limitations under the
# License.
#
# The Original Code is mozilla.org code.
#
# The Initial Developer of the Original Code is
# Netscape Communications Corporation.
# Portions created by the Initial Developer are Copyright (C) 2001
# the Initial Developer. All Rights Reserved.
#
# Contributor(s):
# Srilatha Moturi <srilatha@netscape.com>
#
# Alternatively, the contents of this file may be used under the terms of
# either the GNU General Public License Version 2 or later (the "GPL"), or
# the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
# in which case the provisions of the GPL or the LGPL are applicable instead
# of those above. If you wish to allow use of your version of this file only
# under the terms of either the GPL or the LGPL, and not to allow others to
# use your version of this file under the terms of the MPL, indicate your
# decision by deleting the provisions above and replace them with the notice
# and other provisions required by the GPL or the LGPL. If you do not delete
# the provisions above, a recipient may use your version of this file under
# the terms of any one of the MPL, the GPL or the LGPL.
#
# ***** END LICENSE BLOCK *****
DEPTH=..\..\..\..
MODULE=nsMapiRegistry
XPIDL_MODULE=mapiregistry
XPIDLSRCS = \
.\nsIMapiRegistry.idl \
$(NULL)
include <$(DEPTH)\config\rules.mak>

View File

@@ -1,78 +0,0 @@
/* ***** BEGIN LICENSE BLOCK *****
* Version: MPL 1.1/GPL 2.0/LGPL 2.1
*
* The contents of this file are subject to the Mozilla Public License Version
* 1.1 (the "License"); you may not use this file except in compliance with
* the License. You may obtain a copy of the License at
* http://www.mozilla.org/MPL/
*
* Software distributed under the License is distributed on an "AS IS" basis,
* WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
* for the specific language governing rights and limitations under the
* License.
*
* The Original Code is mozilla.org code.
*
* The Initial Developer of the Original Code is
* Netscape Communications Corporation.
* Portions created by the Initial Developer are Copyright (C) 2001
* the Initial Developer. All Rights Reserved.
*
* Contributor(s):
* Srilatha Moturi <srilatha@netscape.com>
*
* Alternatively, the contents of this file may be used under the terms of
* either the GNU General Public License Version 2 or later (the "GPL"), or
* the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
* in which case the provisions of the GPL or the LGPL are applicable instead
* of those above. If you wish to allow use of your version of this file only
* under the terms of either the GPL or the LGPL, and not to allow others to
* use your version of this file under the terms of the MPL, indicate your
* decision by deleting the provisions above and replace them with the notice
* and other provisions required by the GPL or the LGPL. If you do not delete
* the provisions above, a recipient may use your version of this file under
* the terms of any one of the MPL, the GPL or the LGPL.
*
* ***** END LICENSE BLOCK ***** */
#include "nsISupports.idl"
interface nsIDOMWindow;
/**
* This interface provides support for registering Mozilla as the default
* Mail Client. This interface can also be used to get/set the user preference
* for the default Mail Client.
*
*/
[scriptable, uuid(c5be14ba-4e0a-4eec-a1b8-04363761d63c)]
interface nsIMapiRegistry: nsISupports {
/** This is set to TRUE if Mozilla is the default Application
*/
readonly attribute boolean isDefaultMailClient;
/** This is set TRUE only once per session.
*/
readonly attribute boolean showDialog;
/** This will update the registry keys to set Mozilla as default Mail Client.
*/
void setDefaultMailClient();
/** This will reset the registry keys for the default Mail Client.
*/
void unsetDefaultMailClient();
/** This will bring the dialog asking the user if he/she wants to set
* Mozilla as default Mail Client.
* Call this only if Mozilla is not the default Mail client
*/
void showMailIntegrationDialog(in nsIDOMWindow parentWindow);
};
%{C++
#define NS_IMAPIWINHOOK_CONTRACTID "@mozilla.org/mapiregistry;1"
#define NS_IMAPIWINHOOK_CLASSNAME "Mozilla MAPI Registry"
%}

View File

@@ -1,321 +0,0 @@
/* ***** BEGIN LICENSE BLOCK *****
* Version: MPL 1.1/GPL 2.0/LGPL 2.1
*
* The contents of this file are subject to the Mozilla Public License Version
* 1.1 (the "License"); you may not use this file except in compliance with
* the License. You may obtain a copy of the License at
* http://www.mozilla.org/MPL/
*
* Software distributed under the License is distributed on an "AS IS" basis,
* WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
* for the specific language governing rights and limitations under the
* License.
*
* The Original Code is Mozilla
*
* The Initial Developer of the Original Code is
* Netscape Communications Corp.
* Portions created by the Initial Developer are Copyright (C) 2001
* the Initial Developer. All Rights Reserved.
*
* Contributor(s): Krishna Mohan Khandrika <kkhandrika@netscape.com>
*
* Alternatively, the contents of this file may be used under the terms of
* either the GNU General Public License Version 2 or later (the "GPL"), or
* the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
* in which case the provisions of the GPL or the LGPL are applicable instead
* of those above. If you wish to allow use of your version of this file only
* under the terms of either the GPL or the LGPL, and not to allow others to
* use your version of this file under the terms of the MPL, indicate your
* decision by deleting the provisions above and replace them with the notice
* and other provisions required by the GPL or the LGPL. If you do not delete
* the provisions above, a recipient may use your version of this file under
* the terms of any one of the MPL, the GPL or the LGPL.
*
* ***** END LICENSE BLOCK ***** */
#include <objbase.h>
#include <assert.h>
#include "nsString.h"
#include "Registry.h"
#define MAPI_PROXY_DLL_NAME "MapiProxy.dll"
#define MAPI_STARTUP_ARG " /MAPIStartUp"
#define MAX_SIZE 2048
// Size of a CLSID as a string
const int CLSID_STRING_SIZE = 39;
// Proxy/Stub Dll Routines
typedef HRESULT (__stdcall ProxyServer)();
// Convert a CLSID to a char string.
BOOL CLSIDtochar(const CLSID& clsid, char* szCLSID,
int length)
{
LPOLESTR wszCLSID = NULL;
// Get CLSID
HRESULT hr = StringFromCLSID(clsid, &wszCLSID);
if (FAILED(hr))
return FALSE;
// Covert from wide characters to non-wide.
wcstombs(szCLSID, wszCLSID, length);
// Free memory.
CoTaskMemFree(wszCLSID);
return TRUE;
}
// Create a key and set its value.
BOOL setKeyAndValue(nsCAutoString keyName, const char* subKey,
const char* theValue)
{
HKEY hKey;
BOOL retValue = TRUE;
nsCAutoString theKey(keyName);
if (subKey != NULL)
{
theKey += "\\";
theKey += subKey;
}
// Create and open key and subkey.
long lResult = RegCreateKeyEx(HKEY_CLASSES_ROOT, theKey.get(),
0, NULL, REG_OPTION_NON_VOLATILE,
KEY_ALL_ACCESS, NULL, &hKey, NULL);
if (lResult != ERROR_SUCCESS)
return FALSE ;
// Set the Value.
if (theValue != NULL)
{
lResult = RegSetValueEx(hKey, NULL, 0, REG_SZ, (BYTE *)theValue,
strlen(theValue)+1);
if (lResult != ERROR_SUCCESS)
retValue = FALSE;
}
RegCloseKey(hKey);
return TRUE;
}
// Delete a key and all of its descendents.
LONG recursiveDeleteKey(HKEY hKeyParent, // Parent of key to delete
const char* lpszKeyChild) // Key to delete
{
// Open the child.
HKEY hKeyChild ;
LONG lRes = RegOpenKeyEx(hKeyParent, lpszKeyChild, 0,
KEY_ALL_ACCESS, &hKeyChild) ;
if (lRes != ERROR_SUCCESS)
{
return lRes ;
}
// Enumerate all of the decendents of this child.
FILETIME time ;
char szBuffer[MAX_SIZE] ;
DWORD dwSize = MAX_SIZE ;
while (RegEnumKeyEx(hKeyChild, 0, szBuffer, &dwSize, NULL,
NULL, NULL, &time) == S_OK)
{
// Delete the decendents of this child.
lRes = recursiveDeleteKey(hKeyChild, szBuffer) ;
if (lRes != ERROR_SUCCESS)
{
// Cleanup before exiting.
RegCloseKey(hKeyChild) ;
return lRes;
}
dwSize = MAX_SIZE;
}
// Close the child.
RegCloseKey(hKeyChild) ;
// Delete this child.
return RegDeleteKey(hKeyParent, lpszKeyChild) ;
}
void RegisterProxy()
{
HINSTANCE h = NULL;
ProxyServer *RegisterFunc = NULL;
char szModule[MAX_SIZE];
char *pTemp = NULL;
HMODULE hModule = GetModuleHandle(NULL);
DWORD dwResult = ::GetModuleFileName(hModule, szModule,
sizeof(szModule)/sizeof(char));
if (dwResult == 0)
return;
pTemp = strrchr(szModule, '\\');
if (pTemp == NULL)
return;
*pTemp = '\0';
nsCAutoString proxyPath(szModule);
proxyPath += "\\";
proxyPath += MAPI_PROXY_DLL_NAME;
h = LoadLibrary(proxyPath.get());
if (h == NULL)
return;
RegisterFunc = (ProxyServer *) GetProcAddress(h, "DllRegisterServer");
if (RegisterFunc)
RegisterFunc();
FreeLibrary(h);
}
void UnRegisterProxy()
{
HINSTANCE h = NULL;
ProxyServer *UnRegisterFunc = NULL;
char szModule[MAX_SIZE];
char *pTemp = NULL;
HMODULE hModule = GetModuleHandle(NULL);
DWORD dwResult = ::GetModuleFileName(hModule, szModule,
sizeof(szModule)/sizeof(char));
if (dwResult == 0)
return;
pTemp = strrchr(szModule, '\\');
if (pTemp == NULL)
return;
*pTemp = '\0';
nsCAutoString proxyPath(szModule);
proxyPath += "\\";
proxyPath += MAPI_PROXY_DLL_NAME;
h = LoadLibrary(proxyPath.get());
if (h == NULL)
return;
UnRegisterFunc = (ProxyServer *) GetProcAddress(h, "DllUnregisterServer");
if (UnRegisterFunc)
UnRegisterFunc();
FreeLibrary(h);
}
// Register the component in the registry.
HRESULT RegisterServer(const CLSID& clsid, // Class ID
const char* szFriendlyName, // Friendly Name
const char* szVerIndProgID, // Programmatic
const char* szProgID) // IDs
{
HMODULE hModule = GetModuleHandle(NULL);
char szModuleName[MAX_SIZE];
char szCLSID[CLSID_STRING_SIZE];
nsCAutoString independentProgId(szVerIndProgID);
nsCAutoString progId(szProgID);
DWORD dwResult = ::GetModuleFileName(hModule, szModuleName,
sizeof(szModuleName)/sizeof(char));
if (dwResult == 0)
return S_FALSE;
nsCAutoString moduleName(szModuleName);
nsCAutoString registryKey("CLSID\\");
moduleName += MAPI_STARTUP_ARG;
// Convert the CLSID into a char.
if (!CLSIDtochar(clsid, szCLSID, sizeof(szCLSID)))
return S_FALSE;
registryKey += szCLSID;
// Add the CLSID to the registry.
if (!setKeyAndValue(registryKey, NULL, szFriendlyName))
return S_FALSE;
if (!setKeyAndValue(registryKey, "LocalServer32", moduleName.get()))
return S_FALSE;
// Add the ProgID subkey under the CLSID key.
if (!setKeyAndValue(registryKey, "ProgID", szProgID))
return S_FALSE;
// Add the version-independent ProgID subkey under CLSID key.
if (!setKeyAndValue(registryKey, "VersionIndependentProgID", szVerIndProgID))
return S_FALSE;
// Add the version-independent ProgID subkey under HKEY_CLASSES_ROOT.
if (!setKeyAndValue(independentProgId, NULL, szFriendlyName))
return S_FALSE;
if (!setKeyAndValue(independentProgId, "CLSID", szCLSID))
return S_FALSE;
if (!setKeyAndValue(independentProgId, "CurVer", szProgID))
return S_FALSE;
// Add the versioned ProgID subkey under HKEY_CLASSES_ROOT.
if (!setKeyAndValue(progId, NULL, szFriendlyName))
return S_FALSE;
if (!setKeyAndValue(progId, "CLSID", szCLSID))
return S_FALSE;
RegisterProxy();
return S_OK;
}
LONG UnregisterServer(const CLSID& clsid, // Class ID
const char* szVerIndProgID, // Programmatic
const char* szProgID) // IDs
{
LONG lResult = S_OK;
// Convert the CLSID into a char.
char szCLSID[CLSID_STRING_SIZE];
if (!CLSIDtochar(clsid, szCLSID, sizeof(szCLSID)))
return S_FALSE;
UnRegisterProxy();
nsCAutoString registryKey("CLSID\\");
registryKey += szCLSID;
lResult = recursiveDeleteKey(HKEY_CLASSES_ROOT, registryKey.get());
if (lResult == ERROR_SUCCESS || lResult == ERROR_FILE_NOT_FOUND)
return lResult;
registryKey += "\\LocalServer32";
// Delete only the path for this server.
lResult = recursiveDeleteKey(HKEY_CLASSES_ROOT, registryKey.get());
if (lResult != ERROR_SUCCESS && lResult != ERROR_FILE_NOT_FOUND)
return lResult;
// Delete the version-independent ProgID Key.
lResult = recursiveDeleteKey(HKEY_CLASSES_ROOT, szVerIndProgID);
if (lResult != ERROR_SUCCESS && lResult != ERROR_FILE_NOT_FOUND)
return lResult;
lResult = recursiveDeleteKey(HKEY_CLASSES_ROOT, szProgID);
return lResult;
}

View File

@@ -1,72 +0,0 @@
# ***** BEGIN LICENSE BLOCK *****
# Version: MPL 1.1/GPL 2.0/LGPL 2.1
#
# The contents of this file are subject to the Mozilla Public License Version
# 1.1 (the "License"); you may not use this file except in compliance with
# the License. You may obtain a copy of the License at
# http://www.mozilla.org/MPL/
#
# Software distributed under the License is distributed on an "AS IS" basis,
# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
# for the specific language governing rights and limitations under the
# License.
#
# The Original Code is mozilla.org code.
#
# The Initial Developer of the Original Code is
# Netscape Communications Corporation.
# Portions created by the Initial Developer are Copyright (C) 2001
# the Initial Developer. All Rights Reserved.
#
# Contributor(s):
# Srilatha Moturi <srilatha@netscape.com>
#
# Alternatively, the contents of this file may be used under the terms of
# either the GNU General Public License Version 2 or later (the "GPL"), or
# the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
# in which case the provisions of the GPL or the LGPL are applicable instead
# of those above. If you wish to allow use of your version of this file only
# under the terms of either the GPL or the LGPL, and not to allow others to
# use your version of this file under the terms of the MPL, indicate your
# decision by deleting the provisions above and replace them with the notice
# and other provisions required by the GPL or the LGPL. If you do not delete
# the provisions above, a recipient may use your version of this file under
# the terms of any one of the MPL, the GPL or the LGPL.
#
# ***** END LICENSE BLOCK *****
DEPTH=..\..\..\..
MODULE=nsMapiRegistry
MAKE_OBJ_TYPE = DLL
LIBRARY_NAME=$(MODULE)
MODULE_NAME=nsMapiRegistry
CPPSRCS= \
nsMapiRegistry.cpp \
Registry.cpp \
nsMapiRegistryUtils.cpp \
$(NULL)
CPP_OBJS= \
.\$(OBJDIR)\nsMapiRegistry.obj \
.\$(OBJDIR)\Registry.obj \
.\$(OBJDIR)\nsMapiRegistryUtils.obj \
$(NULL)
LLIBS= \
$(DIST)\lib\xpcom.lib \
$(LIBNSPR) \
$(NULL)
WIN_LIBS= \
ole32.lib \
$(NULL)
EXPORTS= \
nsMapiRegistry.h \
Registry.h \
nsMapiRegistryUtils.h \
$(NULL)
include <$(DEPTH)\config\rules.mak>

View File

@@ -1,252 +0,0 @@
/* ***** BEGIN LICENSE BLOCK *****
* Version: MPL 1.1/GPL 2.0/LGPL 2.1
*
* The contents of this file are subject to the Mozilla Public License Version
* 1.1 (the "License"); you may not use this file except in compliance with
* the License. You may obtain a copy of the License at
* http://www.mozilla.org/MPL/
*
* Software distributed under the License is distributed on an "AS IS" basis,
* WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
* for the specific language governing rights and limitations under the
* License.
*
* The Original Code is mozilla.org code.
*
* The Initial Developer of the Original Code is
* Netscape Communications Corporation.
* Portions created by the Initial Developer are Copyright (C) 2001
* the Initial Developer. All Rights Reserved.
*
* Contributor(s):
* Srilatha Moturi <srilatha@netscape.com>
*
* Alternatively, the contents of this file may be used under the terms of
* either the GNU General Public License Version 2 or later (the "GPL"), or
* the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
* in which case the provisions of the GPL or the LGPL are applicable instead
* of those above. If you wish to allow use of your version of this file only
* under the terms of either the GPL or the LGPL, and not to allow others to
* use your version of this file under the terms of the MPL, indicate your
* decision by deleting the provisions above and replace them with the notice
* and other provisions required by the GPL or the LGPL. If you do not delete
* the provisions above, a recipient may use your version of this file under
* the terms of any one of the MPL, the GPL or the LGPL.
*
* ***** END LICENSE BLOCK ***** */
#include "nsIServiceManager.h"
#include "nsMapiRegistry.h"
#include "nsIGenericFactory.h"
#include "nsXPIDLString.h"
#include "nsIPromptService.h"
#include "nsIStringBundle.h"
#include "nsIProxyObjectManager.h"
#include "nsProxiedService.h"
#include "nsMapiRegistryUtils.h"
#include "nsString.h"
static NS_DEFINE_CID(kStringBundleServiceCID, NS_STRINGBUNDLESERVICE_CID);
nsresult ShowMapiErrorDialog();
/** Implementation of the nsIMapiRegistry interface.
* Use standard implementation of nsISupports stuff.
*/
NS_IMPL_ISUPPORTS1(nsMapiRegistry, nsIMapiRegistry);
nsMapiRegistry::nsMapiRegistry() {
NS_INIT_ISUPPORTS();
m_ShowDialog = !verifyRestrictedAccess();
m_DefaultMailClient = IsDefaultMailClient();
}
nsMapiRegistry::~nsMapiRegistry() {
}
NS_IMETHODIMP
nsMapiRegistry::GetIsDefaultMailClient(PRBool * retval) {
// we need to get the value from registry everytime
// because the registry settings can be changed from
// other mail applications.
*retval = IsDefaultMailClient();
return NS_OK;
}
NS_IMETHODIMP
nsMapiRegistry::GetShowDialog(PRBool * retval) {
*retval = m_ShowDialog;
return NS_OK;
}
NS_IMETHODIMP
nsMapiRegistry::SetDefaultMailClient() {
nsresult rv = setDefaultMailClient();
if (NS_SUCCEEDED(rv))
m_DefaultMailClient = PR_TRUE;
else
rv = ShowMapiErrorDialog();
return NS_OK;
}
NS_IMETHODIMP
nsMapiRegistry::UnsetDefaultMailClient() {
nsresult rv = unsetDefaultMailClient();
if (NS_SUCCEEDED(rv))
m_DefaultMailClient = PR_FALSE;
else
ShowMapiErrorDialog();
return NS_OK;
}
/** This will bring up the dialog box only once per session and
* only if the current app is not default Mail Client.
* This also checks the registry if the registry key
* showMapiDialog is set
*/
NS_IMETHODIMP
nsMapiRegistry::ShowMailIntegrationDialog(nsIDOMWindow *aParentWindow) {
nsresult rv;
if (!m_ShowDialog || !getShowDialog()) return NS_OK;
nsCOMPtr<nsIPromptService> promptService(do_GetService(
"@mozilla.org/embedcomp/prompt-service;1", &rv));
if (NS_SUCCEEDED(rv) && promptService)
{
nsCOMPtr<nsIStringBundleService> bundleService(do_GetService(
kStringBundleServiceCID, &rv));
if (NS_FAILED(rv) || !bundleService) return NS_ERROR_FAILURE;
nsCOMPtr<nsIStringBundle> bundle;
rv = bundleService->CreateBundle(
"chrome://messenger/locale/mapi.properties",
getter_AddRefs(bundle));
if (NS_FAILED(rv)) return NS_ERROR_FAILURE;
nsCOMPtr<nsIStringBundle> brandBundle;
rv = bundleService->CreateBundle(
"chrome://global/locale/brand.properties",
getter_AddRefs(brandBundle));
if (NS_FAILED(rv)) return NS_ERROR_FAILURE;
nsXPIDLString brandName;
rv = brandBundle->GetStringFromName(
NS_LITERAL_STRING("brandShortName").get(),
getter_Copies(brandName));
if (NS_FAILED(rv)) return NS_ERROR_FAILURE;
nsXPIDLString dialogTitle;
const PRUnichar *brandStrings[] = { brandName.get() };
NS_NAMED_LITERAL_STRING(dialogTitlePropertyTag, "dialogTitle");
const PRUnichar *dTitlepropertyTag = dialogTitlePropertyTag.get();
rv = bundle->FormatStringFromName(dTitlepropertyTag,
brandStrings, 1,
getter_Copies(dialogTitle));
if (NS_FAILED(rv)) return NS_ERROR_FAILURE;
nsXPIDLString dialogText;
NS_NAMED_LITERAL_STRING(dialogTextPropertyTag, "dialogText");
const PRUnichar *dpropertyTag = dialogTextPropertyTag.get();
rv = bundle->FormatStringFromName(dpropertyTag,
brandStrings, 1,
getter_Copies(dialogText));
if (NS_FAILED(rv)) return NS_ERROR_FAILURE;
nsXPIDLString checkboxText;
rv = bundle->GetStringFromName(
NS_LITERAL_STRING("checkboxText").get(),
getter_Copies(checkboxText));
if (NS_FAILED(rv)) return NS_ERROR_FAILURE;
PRBool checkValue = PR_FALSE;
PRInt32 buttonPressed = 0;
rv = promptService->ConfirmEx(aParentWindow,
dialogTitle,
dialogText.get(),
(nsIPromptService::BUTTON_TITLE_YES *
nsIPromptService::BUTTON_POS_0) +
(nsIPromptService::BUTTON_TITLE_NO *
nsIPromptService::BUTTON_POS_1),
nsnull,
nsnull,
nsnull,
checkboxText,
&checkValue,
&buttonPressed);
if (NS_FAILED(rv)) return NS_ERROR_FAILURE;
rv = SetRegistryKey(HKEY_LOCAL_MACHINE, "Software\\Mozilla\\Desktop",
"showMapiDialog", (checkValue) ? "0" : "1");
if (NS_FAILED(rv)) return NS_ERROR_FAILURE;
m_ShowDialog = PR_FALSE;
if (!buttonPressed)
rv = SetDefaultMailClient();
}
return rv;
}
nsresult ShowMapiErrorDialog() {
nsresult rv;
nsCOMPtr<nsIPromptService> promptService(do_GetService(
"@mozilla.org/embedcomp/prompt-service;1", &rv));
if (NS_SUCCEEDED(rv) && promptService)
{
nsCOMPtr<nsIStringBundleService> bundleService(do_GetService(
kStringBundleServiceCID, &rv));
if (NS_FAILED(rv) || !bundleService) return NS_ERROR_FAILURE;
nsCOMPtr<nsIStringBundle> bundle;
rv = bundleService->CreateBundle(
"chrome://messenger/locale/mapi.properties",
getter_AddRefs(bundle));
if (NS_FAILED(rv)) return NS_ERROR_FAILURE;
nsCOMPtr<nsIStringBundle> brandBundle;
rv = bundleService->CreateBundle(
"chrome://global/locale/brand.properties",
getter_AddRefs(brandBundle));
if (NS_FAILED(rv)) return NS_ERROR_FAILURE;
nsXPIDLString brandName;
rv = brandBundle->GetStringFromName(
NS_LITERAL_STRING("brandShortName").get(),
getter_Copies(brandName));
if (NS_FAILED(rv)) return NS_ERROR_FAILURE;
nsXPIDLString dialogTitle;
const PRUnichar *brandStrings[] = { brandName.get() };
NS_NAMED_LITERAL_STRING(dialogTitlePropertyTag, "errorMessageTitle");
const PRUnichar *dTitlepropertyTag = dialogTitlePropertyTag.get();
rv = bundle->FormatStringFromName(dTitlepropertyTag,
brandStrings, 1,
getter_Copies(dialogTitle));
if (NS_FAILED(rv)) return NS_ERROR_FAILURE;
nsXPIDLString dialogText;
NS_NAMED_LITERAL_STRING(dialogTextPropertyTag, "errorMessage");
const PRUnichar *dpropertyTag = dialogTextPropertyTag.get();
rv = bundle->FormatStringFromName(dpropertyTag,
brandStrings, 1,
getter_Copies(dialogText));
if (NS_FAILED(rv)) return NS_ERROR_FAILURE;
rv = promptService->Alert(nsnull, dialogTitle,
dialogText);
}
return rv;
}
NS_GENERIC_FACTORY_CONSTRUCTOR(nsMapiRegistry);
// The list of components we register
static nsModuleComponentInfo components[] =
{
{
NS_IMAPIREGISTRY_CLASSNAME,
NS_IMAPIREGISTRY_CID,
NS_IMAPIWINHOOK_CONTRACTID,
nsMapiRegistryConstructor
}
};
NS_IMPL_NSGETMODULE(nsMapiRegistryModule, components);

View File

@@ -1,73 +0,0 @@
/* ***** BEGIN LICENSE BLOCK *****
* Version: MPL 1.1/GPL 2.0/LGPL 2.1
*
* The contents of this file are subject to the Mozilla Public License Version
* 1.1 (the "License"); you may not use this file except in compliance with
* the License. You may obtain a copy of the License at
* http://www.mozilla.org/MPL/
*
* Software distributed under the License is distributed on an "AS IS" basis,
* WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
* for the specific language governing rights and limitations under the
* License.
*
* The Original Code is mozilla.org code.
*
* The Initial Developer of the Original Code is
* Netscape Communications Corporation.
* Portions created by the Initial Developer are Copyright (C) 2001
* the Initial Developer. All Rights Reserved.
*
* Contributor(s):
* Srilatha Moturi <srilatha@netscape.com>
*
* Alternatively, the contents of this file may be used under the terms of
* either the GNU General Public License Version 2 or later (the "GPL"), or
* the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
* in which case the provisions of the GPL or the LGPL are applicable instead
* of those above. If you wish to allow use of your version of this file only
* under the terms of either the GPL or the LGPL, and not to allow others to
* use your version of this file under the terms of the MPL, indicate your
* decision by deleting the provisions above and replace them with the notice
* and other provisions required by the GPL or the LGPL. If you do not delete
* the provisions above, a recipient may use your version of this file under
* the terms of any one of the MPL, the GPL or the LGPL.
*
* ***** END LICENSE BLOCK ***** */
#ifndef nsmapiregistry_h____
#define nsmapiregistry_h____
#include "nsIMapiRegistry.h"
#ifndef MAX_BUF
#define MAX_BUF 4096
#endif
/* c5be14ba-4e0a-4eec-a1b8-04363761d63c */
#define NS_IMAPIREGISTRY_CID \
{ 0xc5be14ba, 0x4e0a, 0x4eec, {0xa1, 0xb8, 0x04, 0x36, 0x37, 0x61, 0xd6, 0x3c} }
#define NS_IMAPIREGISTRY_CONTRACTID "@mozilla.org/mapiregistry;1"
#define NS_IMAPIREGISTRY_CLASSNAME "Mozilla MAPI Registry"
class nsMapiRegistry : public nsIMapiRegistry {
public:
// ctor/dtor
nsMapiRegistry();
virtual ~nsMapiRegistry();
// Declare all interface methods we must implement.
NS_DECL_ISUPPORTS
NS_DECL_NSIMAPIREGISTRY
protected:
PRBool m_DefaultMailClient;
PRBool m_ShowDialog;
private:
// Special member to handle initialization.
PRBool mHaveBeenSet;
}; // nsMapiRegistry
#endif // nsmapiregistry_h____

View File

@@ -1,652 +0,0 @@
/* ***** BEGIN LICENSE BLOCK *****
* Version: MPL 1.1/GPL 2.0/LGPL 2.1
*
* The contents of this file are subject to the Mozilla Public License Version
* 1.1 (the "License"); you may not use this file except in compliance with
* the License. You may obtain a copy of the License at
* http://www.mozilla.org/MPL/
*
* Software distributed under the License is distributed on an "AS IS" basis,
* WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
* for the specific language governing rights and limitations under the
* License.
*
* The Original Code is mozilla.org code.
*
* The Initial Developer of the Original Code is
* Netscape Communications Corporation.
* Portions created by the Initial Developer are Copyright (C) 2001
* the Initial Developer. All Rights Reserved.
*
* Contributor(s):
* Srilatha Moturi <srilatha@netscape.com>
*
* Alternatively, the contents of this file may be used under the terms of
* either the GNU General Public License Version 2 or later (the "GPL"), or
* the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
* in which case the provisions of the GPL or the LGPL are applicable instead
* of those above. If you wish to allow use of your version of this file only
* under the terms of either the GPL or the LGPL, and not to allow others to
* use your version of this file under the terms of the MPL, indicate your
* decision by deleting the provisions above and replace them with the notice
* and other provisions required by the GPL or the LGPL. If you do not delete
* the provisions above, a recipient may use your version of this file under
* the terms of any one of the MPL, the GPL or the LGPL.
*
* ***** END LICENSE BLOCK ***** */
#undef UNICODE
#undef _UNICODE
#include "nsIServiceManager.h"
#include "nsMapiRegistryUtils.h"
#include "nsString.h"
#include "nsIStringBundle.h"
#include "nsXPIDLString.h"
#include "nsSpecialSystemDirectory.h"
#include "nsDirectoryService.h"
#include "nsDirectoryServiceDefs.h"
#include "nsAppDirectoryServiceDefs.h"
// returns TRUE if the Mapi32.dll is smart dll.
static PRBool isSmartDll();
// returns TRUE if the Mapi32.dll is a Mozilla dll.
static PRBool isMozDll();
static NS_DEFINE_CID(kStringBundleServiceCID, NS_STRINGBUNDLESERVICE_CID);
const CLSID CLSID_nsMapiImp = {0x29f458be, 0x8866, 0x11d5, {0xa3, 0xdd, 0x0, 0xb0, 0xd0, 0xf3, 0xba, 0xa7}};
// Returns the (fully-qualified) name of this executable.
static nsCString thisApplication() {
static nsCAutoString result;
if (result.IsEmpty()) {
char buffer[MAX_PATH] = {0};
DWORD len = ::GetModuleFileName(NULL, buffer, sizeof buffer);
len = ::GetShortPathName(buffer, buffer, sizeof buffer);
result = buffer;
result.ToUpperCase();
}
return result;
}
/** This returns the brand name for this application
*/
static nsCString brandName() {
static nsCAutoString brand;
nsresult rv;
if (brand.IsEmpty()) {
nsCOMPtr<nsIStringBundleService> bundleService(do_GetService(
kStringBundleServiceCID, &rv));
if (NS_SUCCEEDED(rv) && bundleService) {
nsCOMPtr<nsIStringBundle> brandBundle;
rv = bundleService->CreateBundle(
"chrome://global/locale/brand.properties",
getter_AddRefs(brandBundle));
if (NS_SUCCEEDED(rv)) {
nsXPIDLString brandName;
rv = brandBundle->GetStringFromName(
NS_LITERAL_STRING("brandShortName").get(),
getter_Copies(brandName));
if (NS_SUCCEEDED(rv)) {
brand.AssignWithConversion(brandName.get());
}
}
}
}
return brand;
}
// verifyRestrictedAccess - Returns PR_TRUE if this user only has restricted access
// to the registry keys we need to modify.
PRBool verifyRestrictedAccess() {
char subKey[] = "Software\\Mozilla - Test Key";
PRBool result = PR_FALSE;
DWORD dwDisp = 0;
HKEY key;
// Try to create/open a subkey under HKLM.
DWORD rc = ::RegCreateKeyEx(HKEY_LOCAL_MACHINE,
subKey,
0,
NULL,
REG_OPTION_NON_VOLATILE,
KEY_WRITE,
NULL,
&key,
&dwDisp);
if (rc == ERROR_SUCCESS) {
// Key was opened; first close it.
::RegCloseKey(key);
// Delete it if we just created it.
switch(dwDisp) {
case REG_CREATED_NEW_KEY:
::RegDeleteKey(HKEY_LOCAL_MACHINE, subKey);
break;
case REG_OPENED_EXISTING_KEY:
break;
}
} else {
// Can't create/open it; we don't have access.
result = PR_TRUE;
}
return result;
}
nsresult SetRegistryKey(HKEY baseKey, const char * keyName,
const char * valueName, char * value)
{
nsresult result = NS_ERROR_FAILURE;
HKEY key;
LONG rc = ::RegCreateKey(baseKey, keyName, &key);
if (rc == ERROR_SUCCESS) {
rc = ::RegSetValueEx(key, valueName, NULL, REG_SZ,
(LPBYTE)(const char*)value, strlen(value));
if (rc == ERROR_SUCCESS) {
result = NS_OK;
}
::RegCloseKey(key);
}
return result;
}
nsresult DeleteRegistryValue(HKEY baseKey, const char * keyName,
const char * valueName)
{
nsresult result = NS_ERROR_FAILURE;
HKEY key;
LONG rc = ::RegOpenKey(baseKey, keyName, &key);
if (rc == ERROR_SUCCESS) {
rc = ::RegDeleteValue(key, valueName);
if (rc == ERROR_SUCCESS)
result = NS_OK;
::RegCloseKey(key);
}
return result;
}
nsCString GetRegistryKey(HKEY baseKey, const char * keyName,
const char * valueName)
{
nsCAutoString value;
HKEY key;
LONG rc = ::RegOpenKey(baseKey, keyName, &key);
if (rc == ERROR_SUCCESS) {
char buffer[MAX_PATH] = {0};
DWORD len = sizeof buffer;
rc = ::RegQueryValueEx(key, valueName, NULL, NULL,
(LPBYTE)buffer, &len);
if (rc == ERROR_SUCCESS) {
if (len)
value = buffer;
}
::RegCloseKey(key);
}
return value;
}
#define EXE_EXTENSION ".exe"
/** Returns TRUE if the current application is default mail client.
*/
PRBool IsDefaultMailClient()
{
if (!isSmartDll() && !isMozDll())
return PR_FALSE;
nsCAutoString name(GetRegistryKey(HKEY_LOCAL_MACHINE,
"Software\\Clients\\Mail", ""));
if (!name.IsEmpty()) {
nsCString keyName("Software\\Clients\\Mail\\");
keyName += name.get();
keyName += "\\protocols\\mailto\\shell\\open\\command";
nsCAutoString result(GetRegistryKey(HKEY_LOCAL_MACHINE,
keyName.get(), ""));
if (!result.IsEmpty()) {
nsCAutoString strExtension;
strExtension.Assign(EXE_EXTENSION);
result.ToUpperCase();
strExtension.ToUpperCase();
PRInt32 index = result.RFind(strExtension.get());
if (index != kNotFound) {
result.Truncate(index + strExtension.Length());
}
return (result == thisApplication());
}
}
return PR_FALSE;
}
/** Saves the current setting of the default Mail Client in
* HKEY_LOCAL_MACHINE\\Software\\Mozilla\\Desktop
*/
nsresult saveDefaultMailClient()
{
nsresult rv;
nsCAutoString name(GetRegistryKey(HKEY_LOCAL_MACHINE,
"Software\\Clients\\Mail", ""));
if (!name.IsEmpty()) {
rv = SetRegistryKey(HKEY_LOCAL_MACHINE,
"Software\\Mozilla\\Desktop",
"HKEY_LOCAL_MACHINE\\Software\\Clients\\Mail",
(char *)name.get());
if (NS_SUCCEEDED(rv)) {
nsCString keyName("Software\\Clients\\Mail\\");
keyName += name.get();
keyName += "\\protocols\\mailto\\shell\\open\\command";
nsCAutoString appPath(GetRegistryKey(HKEY_LOCAL_MACHINE,
keyName.get(), ""));
if (!appPath.IsEmpty()) {
nsCString stringName("HKEY_LOCAL_MACHINE\\");
stringName += keyName.get();
rv = SetRegistryKey(HKEY_LOCAL_MACHINE,
"Software\\Mozilla\\Desktop",
stringName.get(), (char *)appPath.get());
}
}
}
else
rv = SetRegistryKey(HKEY_LOCAL_MACHINE,
"Software\\Mozilla\\Desktop",
"HKEY_LOCAL_MACHINE\\Software\\Clients\\Mail",
"");
return rv;
}
/** Saves the current user setting of the default Mail Client in
* HKEY_LOCAL_MACHINE\\Software\\Mozilla\\Desktop
*/
nsresult saveUserDefaultMailClient()
{
nsresult rv;
nsCAutoString name(GetRegistryKey(HKEY_CURRENT_USER,
"Software\\Clients\\Mail", ""));
if (!name.IsEmpty()) {
rv = SetRegistryKey(HKEY_LOCAL_MACHINE,
"Software\\Mozilla\\Desktop",
"HKEY_CURRENT_USER\\Software\\Clients\\Mail",
(char *)name.get());
}
else {
rv = SetRegistryKey(HKEY_LOCAL_MACHINE,
"Software\\Mozilla\\Desktop",
"HKEY_CURRENT_USER\\Software\\Clients\\Mail",
"");
}
return rv;
}
/**
* Check whether it is a smart dll or not. Smart dll is the one installed by
* IE5 or Outlook Express which forwards the MAPI calls to the dll based on the
* registry key setttings.
* Returns TRUE if is a smart dll.
*/
typedef HRESULT (FAR PASCAL GetOutlookVersionFunc)();
static PRBool isSmartDll()
{
char buffer[MAX_PATH] = {0};
if (GetSystemDirectory(buffer, sizeof(buffer)) == 0)
return PR_FALSE;
PL_strcatn(buffer, sizeof(buffer), "\\Mapi32.dll");
HINSTANCE hInst;
GetOutlookVersionFunc *doesExist = nsnull;
hInst = LoadLibrary(buffer);
if (hInst == nsnull)
return PR_FALSE;
doesExist = (GetOutlookVersionFunc *) GetProcAddress (hInst, "GetOutlookVersion");
FreeLibrary(hInst);
return (doesExist != nsnull);
}
typedef HRESULT (FAR PASCAL GetMapiDllVersion)();
/**
* Checks whether mapi32.dll is installed by this app.
* Returns TRUE if it is.
*/
static PRBool isMozDll()
{
char buffer[MAX_PATH] = {0};
if (GetSystemDirectory(buffer, sizeof(buffer)) == 0)
return PR_FALSE;
PL_strcatn(buffer, sizeof(buffer), "\\Mapi32.dll");
HINSTANCE hInst;
GetMapiDllVersion *doesExist = nsnull;
hInst = LoadLibrary(buffer);
if (hInst == nsnull)
return PR_FALSE;
doesExist = (GetMapiDllVersion *) GetProcAddress (hInst, "GetMapiDllVersion");
FreeLibrary(hInst);
return (doesExist != nsnull);
}
/** Renames Mapi32.dl in system directory to Mapi32_moz_bak.dll
* copies the mozMapi32.dll from bin directory to the system directory
*/
nsresult CopyMozMapiToWinSysDir()
{
nsresult rv;
char buffer[MAX_PATH] = {0};
if (GetSystemDirectory(buffer, sizeof(buffer)) == 0)
return NS_ERROR_FAILURE;
nsCAutoString filePath(buffer);
filePath.Append("\\Mapi32_moz_bak.dll");
nsCOMPtr<nsILocalFile> pCurrentMapiFile = do_CreateInstance (NS_LOCAL_FILE_CONTRACTID, &rv);
if (NS_FAILED(rv) || !pCurrentMapiFile) return rv;
pCurrentMapiFile->InitWithPath(filePath.get());
nsCOMPtr<nsIFile> pMozMapiFile;
nsCOMPtr<nsIProperties> directoryService =
do_GetService(NS_DIRECTORY_SERVICE_CONTRACTID, &rv);
if (!directoryService) return NS_ERROR_FAILURE;
rv = directoryService->Get(NS_OS_CURRENT_PROCESS_DIR,
NS_GET_IID(nsIFile),
getter_AddRefs(pMozMapiFile));
if (NS_FAILED(rv)) return rv;
pMozMapiFile->Append("mozMapi32.dll");
PRBool bExist;
rv = pMozMapiFile->Exists(&bExist);
if (NS_FAILED(rv) || !bExist) return rv;
rv = pCurrentMapiFile->Exists(&bExist);
if (NS_SUCCEEDED(rv) && bExist)
{
rv = pCurrentMapiFile->Remove(PR_FALSE);
}
if (NS_FAILED(rv)) return rv;
filePath.Assign(buffer);
filePath.Append("\\Mapi32.dll");
pCurrentMapiFile->InitWithPath(filePath.get());
rv = pCurrentMapiFile->Exists(&bExist);
if (NS_SUCCEEDED(rv) && bExist)
{
rv = pCurrentMapiFile->MoveTo(nsnull, "Mapi32_moz_bak.dll");
if (NS_FAILED(rv)) return rv;
nsCAutoString fullFilePath(buffer);
fullFilePath.Append("\\Mapi32_moz_bak.dll");
rv = SetRegistryKey(HKEY_LOCAL_MACHINE,
"Software\\Mozilla\\Desktop",
"Mapi_backup_dll",
(char *)fullFilePath.get());
if (NS_FAILED(rv)) {
RestoreBackedUpMapiDll();
return rv;
}
}
nsAutoString fileName;
fileName.AssignWithConversion("Mapi32.dll");
filePath.Assign(buffer);
pCurrentMapiFile->InitWithPath(filePath.get());
rv = pMozMapiFile->CopyToUnicode(pCurrentMapiFile, fileName.get());
if (NS_FAILED(rv))
RestoreBackedUpMapiDll();
return rv;
}
/** deletes the Mapi32.dll in system directory and renames Mapi32_moz_bak.dll
* to Mapi32.dll
*/
nsresult RestoreBackedUpMapiDll()
{
nsresult rv;
char buffer[MAX_PATH] = {0};
if (GetSystemDirectory(buffer, sizeof(buffer)) == 0)
return NS_ERROR_FAILURE;
nsCAutoString filePath(buffer);
nsCAutoString previousFileName(buffer);
filePath.Append("\\Mapi32.dll");
previousFileName.Append("\\Mapi32_moz_bak.dll");
nsCOMPtr <nsILocalFile> pCurrentMapiFile = do_CreateInstance(NS_LOCAL_FILE_CONTRACTID, &rv);
if (NS_FAILED(rv) || !pCurrentMapiFile) return NS_ERROR_FAILURE;
pCurrentMapiFile->InitWithPath(filePath);
nsCOMPtr<nsILocalFile> pPreviousMapiFile = do_CreateInstance (NS_LOCAL_FILE_CONTRACTID, &rv);
if (NS_FAILED(rv) || !pPreviousMapiFile) return NS_ERROR_FAILURE;
pPreviousMapiFile->InitWithPath(previousFileName);
PRBool bExist;
rv = pCurrentMapiFile->Exists(&bExist);
if (NS_SUCCEEDED(rv) && bExist) {
rv = pCurrentMapiFile->Remove(PR_FALSE);
if (NS_FAILED(rv)) return rv;
}
rv = pPreviousMapiFile->Exists(&bExist);
if (NS_SUCCEEDED(rv) && bExist)
rv = pPreviousMapiFile->MoveTo(nsnull, "Mapi32.dll");
if (NS_SUCCEEDED(rv))
DeleteRegistryValue(HKEY_LOCAL_MACHINE,
"Software\\Mozilla\\Desktop",
"Mapi_backup_dll");
return rv;
}
/** Sets Mozilla as default Mail Client
*/
nsresult setDefaultMailClient()
{
nsresult rv;
nsresult mailKeySet=NS_ERROR_FAILURE;
if (verifyRestrictedAccess()) return NS_ERROR_FAILURE;
if (!isSmartDll()) {
if (NS_FAILED(CopyMozMapiToWinSysDir())) return NS_ERROR_FAILURE;
}
rv = saveDefaultMailClient();
if (NS_FAILED(saveUserDefaultMailClient()) ||
NS_FAILED(rv)) return NS_ERROR_FAILURE;
nsCAutoString keyName("Software\\Clients\\Mail\\");
nsCAutoString appName(brandName());
if (!appName.IsEmpty()) {
keyName.Append(appName.get());
// hardcoding this for 0.9.4 branch
// need to change it before merging into the trunk
rv = SetRegistryKey(HKEY_LOCAL_MACHINE,
(char *)keyName.get(),
"", "Netscape 6.2 Mail");
}
else
rv = NS_ERROR_FAILURE;
if (NS_SUCCEEDED(rv)) {
nsCAutoString dllPath(thisApplication());
PRInt32 index = dllPath.RFind("\\");
if (index != kNotFound)
dllPath.Truncate(index + 1);
dllPath += "mozMapi32.dll";
rv = SetRegistryKey(HKEY_LOCAL_MACHINE,
(char *)keyName.get(), "DLLPath",
(char *)dllPath.get());
if (NS_SUCCEEDED(rv)) {
keyName.Append("\\protocols\\mailto");
rv = SetRegistryKey(HKEY_LOCAL_MACHINE,
(char *)keyName.get(),
"", "URL:MailTo Protocol");
if (NS_SUCCEEDED(rv)) {
nsCAutoString appPath(thisApplication());
appPath += " \"%1\"";
keyName.Append("\\shell\\open\\command");
rv = SetRegistryKey(HKEY_LOCAL_MACHINE,
(char *)keyName.get(),
"", (char *)appPath.get());
if (NS_SUCCEEDED(rv)) {
rv = SetRegistryKey(HKEY_LOCAL_MACHINE,
"Software\\Clients\\Mail",
"", (char *)appName.get());
}
if (NS_SUCCEEDED(rv)) {
nsCAutoString mailAppPath(thisApplication());
mailAppPath += " -mail";
nsCAutoString appKeyName ("Software\\Clients\\Mail\\");
appKeyName.Append(appName.get());
appKeyName.Append("\\shell\\open\\command");
rv = SetRegistryKey(HKEY_LOCAL_MACHINE,
(char *)appKeyName.get(),
"", (char *)mailAppPath.get());
}
if (NS_SUCCEEDED(rv)) {
nsCAutoString iconPath(thisApplication());
iconPath += ",0";
nsCAutoString iconKeyName ("Software\\Clients\\Mail\\");
iconKeyName.Append(appName.get());
iconKeyName.Append("\\DefaultIcon");
mailKeySet = SetRegistryKey(HKEY_LOCAL_MACHINE,
(char *)iconKeyName.get(),
"", (char *)iconPath.get());
}
}
}
}
if (NS_SUCCEEDED(mailKeySet)) {
nsresult desktopKeySet = SetRegistryKey(HKEY_CURRENT_USER,
"Software\\Clients\\Mail",
"", (char *)appName.get());
if (NS_SUCCEEDED(desktopKeySet)) {
desktopKeySet = SetRegistryKey(HKEY_LOCAL_MACHINE,
"Software\\Mozilla\\Desktop",
"defaultMailHasBeenSet", "1");
}
::SendMessage(HWND_BROADCAST, WM_SETTINGCHANGE, 0,
(LPARAM)"Software\\Clients\\Mail");
RegisterServer(CLSID_nsMapiImp, "Mozilla MAPI", "mozMapi", "mozMapi.1");
return desktopKeySet;
}
return mailKeySet;
}
/** Removes Mozilla as the default Mail client and restores the previous setting
*/
nsresult unsetDefaultMailClient() {
nsresult result = NS_OK;
nsresult mailKeySet = NS_ERROR_FAILURE;
if (verifyRestrictedAccess()) return NS_ERROR_FAILURE;
if (!isSmartDll()) {
if (NS_FAILED(RestoreBackedUpMapiDll())) return NS_ERROR_FAILURE;
}
nsCAutoString name(GetRegistryKey(HKEY_LOCAL_MACHINE,
"Software\\Mozilla\\Desktop",
"HKEY_LOCAL_MACHINE\\Software\\Clients\\Mail"));
nsCAutoString appName(brandName());
if (!name.IsEmpty() && !appName.IsEmpty() && name.Equals(appName)) {
nsCAutoString keyName("HKEY_LOCAL_MACHINE\\Software\\Clients\\Mail\\");
keyName.Append(appName.get());
keyName.Append("\\protocols\\mailto\\shell\\open\\command");
nsCAutoString appPath(GetRegistryKey(HKEY_LOCAL_MACHINE,
"Software\\Mozilla\\Desktop",
(char *)keyName.get()));
if (!appPath.IsEmpty()) {
keyName.Assign("Software\\Clients\\Mail\\");
keyName.Append(appName.get());
keyName.Append("\\protocols\\mailto\\shell\\open\\command");
result = SetRegistryKey(HKEY_LOCAL_MACHINE,
(char *) keyName.get(),
"", (char *)appPath.get());
if (NS_SUCCEEDED(result)) {
PRInt32 index = appPath.RFind("\\");
if (index != kNotFound)
appPath.Truncate(index + 1);
appPath += "mozMapi32.dll";
keyName.Assign("Software\\Clients\\Mail\\");
keyName.Append(appName.get());
result = SetRegistryKey(HKEY_LOCAL_MACHINE,
(char *)keyName.get(),
"DLLPath", (char *) appPath.get());
}
}
}
if (!name.IsEmpty()) {
if (NS_SUCCEEDED(result)) {
mailKeySet = SetRegistryKey(HKEY_LOCAL_MACHINE,
"Software\\Clients\\Mail",
"", (char *)name.get());
}
}
else
mailKeySet = SetRegistryKey(HKEY_LOCAL_MACHINE,
"Software\\Clients\\Mail",
"", "");
if (NS_SUCCEEDED(mailKeySet)) {
nsCAutoString userAppName(GetRegistryKey(HKEY_LOCAL_MACHINE,
"Software\\Mozilla\\Desktop",
"HKEY_CURRENT_USER\\Software\\Clients\\Mail"));
nsresult desktopKeySet = NS_OK;
if (!userAppName.IsEmpty()) {
desktopKeySet = SetRegistryKey(HKEY_CURRENT_USER,
"Software\\Clients\\Mail",
"", (char *)userAppName.get());
}
else {
DeleteRegistryValue(HKEY_CURRENT_USER, "Software\\Clients\\Mail", "");
}
if (NS_SUCCEEDED(desktopKeySet)) {
desktopKeySet = SetRegistryKey(HKEY_LOCAL_MACHINE,
"Software\\Mozilla\\Desktop",
"defaultMailHasBeenSet", "0");
}
::SendMessage(HWND_BROADCAST, WM_SETTINGCHANGE, 0,
(LPARAM)"Software\\Clients\\Mail");
UnregisterServer(CLSID_nsMapiImp, "mozMapi", "mozMapi.1");
return desktopKeySet;
}
return mailKeySet;
}
/** Returns FALSE if showMapiDialog is set to 0.
* Returns TRUE otherwise
* Also returns TRUE if the Mozilla has been set as the default mail client
* and some other application has changed that setting.
* This function gets called only if the current app is not the default mail
* client
*/
PRBool getShowDialog() {
PRBool rv = PR_FALSE;
nsCString showDialog(GetRegistryKey(HKEY_LOCAL_MACHINE,
"Software\\Mozilla\\Desktop",
"showMapiDialog"));
// if the user has not selected the checkbox, show dialog
if (showDialog.IsEmpty() || showDialog.Equals("1"))
rv = PR_TRUE;
if (!rv) {
// even if the user has selected the checkbox
// show it if some other application has changed the
// default setting.
nsCAutoString setMailDefault(GetRegistryKey(HKEY_LOCAL_MACHINE,
"Software\\Mozilla\\Desktop",
"defaultMailHasBeenSet"));
if (setMailDefault.Equals("1")) {
// need to reset the defaultMailHasBeenSet to "0"
// so that after the dialog is displayed once,
// we do not keep displaying this dialog after the user has
// selected the checkbox
rv = SetRegistryKey(HKEY_LOCAL_MACHINE,
"Software\\Mozilla\\Desktop",
"defaultMailHasBeenSet", "0");
rv = PR_TRUE;
}
}
return rv;
}

View File

@@ -1,90 +0,0 @@
/* ***** BEGIN LICENSE BLOCK *****
* Version: MPL 1.1/GPL 2.0/LGPL 2.1
*
* The contents of this file are subject to the Mozilla Public License Version
* 1.1 (the "License"); you may not use this file except in compliance with
* the License. You may obtain a copy of the License at
* http://www.mozilla.org/MPL/
*
* Software distributed under the License is distributed on an "AS IS" basis,
* WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
* for the specific language governing rights and limitations under the
* License.
*
* The Original Code is mozilla.org code.
*
* The Initial Developer of the Original Code is
* Netscape Communications Corporation.
* Portions created by the Initial Developer are Copyright (C) 2001
* the Initial Developer. All Rights Reserved.
*
* Contributor(s):
* Srilatha Moturi <srilatha@netscape.com>
*
* Alternatively, the contents of this file may be used under the terms of
* either the GNU General Public License Version 2 or later (the "GPL"), or
* the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
* in which case the provisions of the GPL or the LGPL are applicable instead
* of those above. If you wish to allow use of your version of this file only
* under the terms of either the GPL or the LGPL, and not to allow others to
* use your version of this file under the terms of the MPL, indicate your
* decision by deleting the provisions above and replace them with the notice
* and other provisions required by the GPL or the LGPL. If you do not delete
* the provisions above, a recipient may use your version of this file under
* the terms of any one of the MPL, the GPL or the LGPL.
*
* ***** END LICENSE BLOCK ***** */
#ifndef nsmapiregistryutils_h____
#define nsmapiregistryutils_h____
#include <windows.h>
#include <string.h>
#include <winreg.h>
#include "Registry.h"
#include "nsString.h"
//Sets the registry key for basekey/keyname valuename.
nsresult SetRegistryKey(HKEY baseKey, const char * keyName,
const char * valueName, char * value);
// Deletes the registry key for base/keyname/valuename
nsresult DeleteRegistryValue(HKEY baseKey, const char * keyName,
const char * valueName);
// Gets the current regiistry setting for the key.
nsCString GetRegistryKey(HKEY baseKey, const char * keyName,
const char * valueName);
// Returns PR_TRUE if this user only has restricted access
// to the registry keys we need to modify.
PRBool verifyRestrictedAccess();
// Returns true if mozilla is the default mail client
// by checking the registry.
PRBool IsDefaultMailClient();
// Save the current setting for the default mail client.
nsresult saveDefaultMailClient();
// Saves the current user setting for the default mail client.
nsresult saveUserDefaultMailClient();
// Renames Mapi32.dl in system directory to Mapi32_moz_bak.dll
// copies the mozMapi32.dll from bin directory to the system directory
nsresult CopyMozMapiToWinSysDir();
// deletes the Mapi32.dll in system directory and renames Mapi32_moz_bak.dll
// to Mapi32.dll
nsresult RestoreBackedUpMapiDll();
// Sets mozilla as the default mail client
nsresult setDefaultMailClient();
// unsets mozilla and resets the default mail client setting to previous one
nsresult unsetDefaultMailClient();
// returns true if we need to show the mail integration dialog.
PRBool getShowDialog();
#endif

View File

@@ -100,5 +100,5 @@ function onOK()
mapiRegistry.setDefaultMailClient();
else
mapiRegistry.unsetDefaultMailClient();
}
}
}