Closed Bug 599657 Opened 14 years ago Closed 14 years ago

"WARNING: Ignoring duplicate observer." due to duplicate metrics in nsXPLookAndFeel.cpp

Categories

(Core :: Widget, defect)

defect
Not set
normal

Tracking

()

RESOLVED FIXED
mozilla2.0b7

People

(Reporter: dbaron, Assigned: dbaron)

References

Details

Attachments

(1 file)

I decided to see what was causing the first warning printed to the console when starting Firefox.  It turns out to be that nsXPLookAndFeel.cpp has two different metrics that are the same thing:

one is an int:
  { "ui.listVerticalInsidePadding", eMetric_ListVerticalInsidePadding,
    PR_FALSE, nsLookAndFeelTypeInt, 0 },

and the other is a float:  { "ui.listVerticalInsidePadding",
    eMetricFloat_ListVerticalInsidePadding, PR_FALSE, nsLookAndFeelTypeFloat, 0 },
This seems like a mistake.


Furthermore, I think they're both unused.
A large number of system metrics are dead code.  We should remove them.  It saves code size and pref observers.
Attachment #478582 - Flags: review?(roc)
Assignee: nobody → dbaron
Comment on attachment 478582 [details] [diff] [review]
remove unused system metrics

Low risk patch to remove unused code (which is in our startup path).
Attachment #478582 - Flags: approval2.0?
Comment on attachment 478582 [details] [diff] [review]
remove unused system metrics

post-b7
Attachment #478582 - Flags: approval2.0? → approval2.0+
http://hg.mozilla.org/mozilla-central/rev/1aab37daf3bc
Status: NEW → RESOLVED
Closed: 14 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla2.0b8
Target Milestone: mozilla2.0b8 → mozilla2.0b7
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: