Closed Bug 279405 Opened 20 years ago Closed 18 years ago

Change nsIAbCard.idl from wstring to AString to save code-size

Categories

(MailNews Core :: Address Book, defect)

defect
Not set
normal

Tracking

(Not tracked)

RESOLVED FIXED

People

(Reporter: mikael, Assigned: standard8)

References

(Blocks 1 open bug)

Details

(Keywords: helpwanted, memory-footprint)

Attachments

(2 files, 1 obsolete file)

A proposal to change all wstring to AString in nsIAbCard.idl. This removes lots of conversions and getter_Copies and saves about 10k on my optimized Suite-build
Attached patch proposed changes (obsolete) — Splinter Review
Attachment #172120 - Flags: superreview?(dmose)
Attachment #172120 - Flags: review?(bienvenu)
Comment on attachment 172120 [details] [diff] [review] proposed changes this will break the palm sync code, won't it? mailnews/extensions/palmsync. I'm worried there might be other extensions out there that this will break as well but at minimum, we'd need to fix the palm sync code.
Once you sort out the palmsync question, could you generate a patch with "diff -w" for reviewing purposes? That'd make it easier to eyeball the changes and be sure that nothing is inadvertantly missed.
Attachment #172120 - Flags: superreview?(dmose)
Attachment #172120 - Flags: review?(bienvenu)
Attachment #172120 - Attachment is obsolete: true
I know it's not the original problem of this bug, but I noticed this and the changes you were going to make which will probably duplicate(ish) a set of changes I need to make. David & Dan both mention about the palmsync extension - one of the palmsync classes (nsAbIPCCard) inherits from nsAbMDBCardProperty (see link below), which I believe is wrong. http://lxr.mozilla.org/seamonkey/source/mailnews/extensions/palmsync/src/nsAbIPCCard.h#56 From what I understand, if possible, this should really inherit from nsIAbCard as that is the proper interface. I was going to change this in Bug 131849 as part of it's subsequent tidy up from the build bustages, such that address book wouldn't need to export the nsAbCardPropery.h and nsAbMDBCardProperty.h internal headers. If I am right,then these changes are obviously going to affect one another perhaps we could co-ordinate them? David, can you confirm whether or not I am right about the inheritance structure for the nsAbIPCCard class and whether you agree that the changes should be made, or do you know of a possible problem?
Blocks: 131849
Mikael isn't able to do patches for us currently, moving to core address book & reassigning to default owner.
Assignee: mikael → nobody
Component: Address Book → MailNews: Address Book
Keywords: helpwanted
Product: Mozilla Application Suite → Core
QA Contact: addressbook
Version: unspecified → Trunk
Attached patch Updated patchSplinter Review
I've taken Mikael's original patch and updated it to latest trunk and to cover the windows side of things as well (though I've only compiled on linux). I think this would nice to get in now while we're doing lots of changes to interfaces etc on trunk, and it should cut down on the amount of string copying we're doing...
Assignee: nobody → bugzilla
Status: NEW → ASSIGNED
Attachment #261847 - Flags: review?(bienvenu)
Opps, almost forgot, here's the -w version as there's some extra whitespace fixups as well.
Comment on attachment 261847 [details] [diff] [review] Updated patch thx, Mark, this looks good. Does it affect palmsync, I wonder?
Attachment #261847 - Flags: review?(bienvenu) → review+
(In reply to comment #8) > (From update of attachment 261847 [details] [diff] [review]) > thx, Mark, this looks good. Does it affect palmsync, I wonder? David: Index: mailnews/extensions/palmsync/src/nsAbIPCCard.cpp =================================================================== RCS file: /cvsroot/mozilla/mailnews/extensions/palmsync/src/nsAbIPCCard.cpp,v It's in there already. I think those changes are the only ones that are required.
Attachment #261847 - Flags: superreview?(mscott)
Comment on attachment 261847 [details] [diff] [review] Updated patch Nice change.
Attachment #261847 - Flags: superreview?(mscott) → superreview+
Patch checked in -> fixed.
Status: ASSIGNED → RESOLVED
Closed: 18 years ago
Resolution: --- → FIXED
(oh and depending on which SeaMonkey build you looked at it saved 8480 bytes or 10648 bytes) :-)
Product: Core → MailNews Core
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: