Closed Bug 1339609 Opened 3 years ago Closed 3 years ago

Code that calls gfxPrefs APIs should #include gfxPrefs.h

Categories

(Core :: Graphics, defect)

defect
Not set

Tracking

()

RESOLVED FIXED
mozilla54
Tracking Status
firefox54 --- fixed

People

(Reporter: dholbert, Assigned: dholbert)

References

Details

Attachments

(1 file)

I hit several instances of build bustage for things failing to include gfxPrefs.h today.

The bustage was basically caused by source files that *use* a gfxPrefs API, but do not include gfxPrefs.h.  (And up until bug 1338426 landed, these files were indirectly getting the header from another one.)

We should just have gfxPrefs users reliably #include gfxPrefs.h. I've got a patch to do that.

Marking this as blocking bug 1338426 because I suspect that can re-land after we've fixed this.
This patch...
 - *only* adds new #includes (and blank lines in a few cases, to separate Foo.cpp's own Foo.h include from the other includes).
 - *only* touches files that have "gfxPrefs::Whatever()" calls inside of them.  (Some of these are .h files themselves. Since these files call into gfxPrefs, they really need to include gfxPrefs.h themselves or else they're not safe [build-bustage-wise] for arbitrary other .cpp files to include.)

In general, I'm trying to insert the new #include in sorted order, or in what-would-be-sorted-order-if-the-existing-include-block-were-already-sorted.  In some cases the include block was already badly sorted so I just did best-guess at a place to insert.  If you have strong feelings that any of these should go somewhere else in the list, I'm happy to move htem.
Comment on attachment 8837334 [details]
Bug 1339609: Add #include for gfxPrefs.h to all source code that calls gfxPrefs APIs.

https://reviewboard.mozilla.org/r/112488/#review113888
Attachment #8837334 - Flags: review?(jgilbert) → review+
Pushed by dholbert@mozilla.com:
https://hg.mozilla.org/integration/autoland/rev/b35fd9bd12a5
Add #include for gfxPrefs.h to all source code that calls gfxPrefs APIs. r=jgilbert
https://hg.mozilla.org/mozilla-central/rev/b35fd9bd12a5
Status: ASSIGNED → RESOLVED
Closed: 3 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla54
You need to log in before you can comment on or make changes to this bug.