Closed Bug 794957 Opened 13 years ago Closed 13 years ago

Use imgLoader instead of imgILoader

Categories

(Core :: Graphics: ImageLib, defect)

x86
macOS
defect
Not set
normal

Tracking

()

RESOLVED FIXED
mozilla19

People

(Reporter: jrmuizel, Assigned: jrmuizel)

References

Details

(Keywords: addon-compat)

Attachments

(1 file, 1 obsolete file)

This changes all the c++ callers of imgILoader to use the concrete type imgLoader.
Attachment #665475 - Flags: review?(joe)
Depends on: 794884
Keywords: addon-compat
I remember checking mxr.mozilla.org/addons and not finding anybody using imgILoader, but this should still be noted for the validator.
Comment on attachment 665475 [details] [diff] [review] Change the c++ callers of imgILoader to use imgLoader. Review of attachment 665475 [details] [diff] [review]: ----------------------------------------------------------------- ::: content/base/src/nsContentUtils.cpp @@ +520,5 @@ > > // Ignore failure and just don't load images > + sImgLoader = new imgLoader(); > + rv = sImgLoader->Init(); > + if (rv) if (NS_FAILED(rv)) @@ +521,5 @@ > // Ignore failure and just don't load images > + sImgLoader = new imgLoader(); > + rv = sImgLoader->Init(); > + if (rv) > + delete sImgLoader; sImgLoader = nullptr; @@ +526,5 @@ > NS_ABORT_IF_FALSE(NS_SUCCEEDED(rv), "Creation should have succeeded"); > + > + sPrivateImgLoader = new imgLoader(); > + rv = sPrivateImgLoader->Init(); > + if (rv) if (NS_FAILED(rv)) @@ +527,5 @@ > + > + sPrivateImgLoader = new imgLoader(); > + rv = sPrivateImgLoader->Init(); > + if (rv) > + delete sImgLoader; delete sPrivateImgLoader; sPrivateImgLoader = nullptr;
Attachment #665475 - Flags: review?(joe) → review-
Attachment #665475 - Attachment is obsolete: true
Attachment #670773 - Flags: review?
Attachment #670773 - Flags: review? → review?(joe)
Comment on attachment 670773 [details] [diff] [review] Change the c++ callers of imgILoader to use imgLoader. v2 Review of attachment 670773 [details] [diff] [review]: ----------------------------------------------------------------- ::: image/src/imgLoader.h @@ +227,5 @@ > > + static imgLoader* Create() > + { > + imgLoader *loader = new imgLoader(); > + if (NS_FAILED(loader->Init())) { Looks like Init() actually can't fail... It should return void (followup, I guess).
Attachment #670773 - Flags: review?(joe) → review+
Assignee: nobody → jmuizelaar
Status: NEW → RESOLVED
Closed: 13 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla19
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: