As a part of bug 100214: We are removing case-insensitive comparisons on PRUnichar strings from XPCOM. This means that nsStringArray needs to get rid of the three methods that require this capability: IndexOfIgnoreCase() RemoveStringIgnoreCase() SortIgnoreCase() Fortunately, the only consumer of any of these routines, namely IndexOfIgnoreCase, is nsPresShell, for case-insensitively identifying alternate style sheets. I looked at the w3c spec, and it gives no indication about if case matters in the name of an alternate style sheet, so I would like to propose a simple solution whereby we simply make alternate-stylesheet selection case-sensitive. The routines in question are: GetActiveAlternateStyleSheet() SelectAlternateStyleSheet() ListAlternateStyleSheets() Of these, only SelectAlternateStyleSheet and ListAlternateStyleSheet are affected by this change, and both of these routines are ONLY used by the viewer test application. The patch I'm about to attach removes the aforementioned routines and changes behavior such that: - ListAlternateStyleSheets() no longer attempts uses case-insensitive compares to prune the list - SelectAlternateStyleSheet() uses IndexOf() rather than IndexOfIgnoreCase() This way we have symmetry with respect to the list and selection of style sheets.
If everyone is ok with this, can I get an r=jag and an sr=attinasi?
There is the ability to select alternate style sheets int eh Mozill aUI - are you sure it is not using those methods? Regardless, I doubt they need to be case-insensitive.
Comment on attachment 52988 [details] [diff] [review] fix up the nsStringArray API sr=attinasi - (I'm assuming that you tested to be sure that the alternate stylesheet UI in Mozilla still works)
Comment on attachment 52988 [details] [diff] [review] fix up the nsStringArray API r=jag
actually the alternate style sheet ui in the browser is not hooked up to anything.. it will always say "None", believe it or not. the only place it's used is in viewer....thanks folks.
Use http://www.w3.org/Style/CSS/ as a testcase for alternate stylesheets.
Alternate stylesheet UI works fine for me (20011003) and CVS build from 10-10 Alec, please recheck using the URL jag posted you should get a bunch of alternate sheets, like 10 or 11.
hey, you're right! good news is that they still show up and work in today's build :)