[code clean up] refactor parallel arrays into array of structs in nsAutoCompleteSimpleResult.h

NEW
Unassigned

Status

()

Core
XUL
11 years ago
10 years ago

People

(Reporter: (not reading, please use seth@sspitzer.org instead), Unassigned)

Tracking

Trunk
x86
Windows XP
Points:
---

Firefox Tracking Flags

(Not tracked)

Details

spun off from bug #373353

See http://lxr.mozilla.org/seamonkey/source/toolkit/components/autocomplete/src/nsAutoCompleteSimpleResult.h#63

We now have:

  // What we really want is an array of structs with value/comment/image/style contents.
  // But then we'd either have to use COM or manage object lifetimes ourselves.
  // Having four arrays of string simplifies this, but is stupid.
  nsStringArray mValues;
  nsStringArray mComments;
  nsStringArray mImages;
  nsStringArray mStyles;

Mano writes:  We should start using a struct at this point IMO.  For the sake of making some progress, I'm fine with leaving the re-factoring to
a follow up.

Updated

10 years ago
Assignee: jag → nobody
You need to log in before you can comment on or make changes to this bug.