Closed
Bug 1334554
Opened 9 years ago
Closed 9 years ago
Handle return value of nsFilterInstance::PaintFilteredFrame
Categories
(Core :: Web Painting, defect)
Core
Web Painting
Tracking
()
RESOLVED
FIXED
mozilla54
| Tracking | Status | |
|---|---|---|
| firefox54 | --- | fixed |
People
(Reporter: u459114, Assigned: u459114)
Details
Attachments
(1 file)
We should either handle the return value of this function or change it to void if we don't want to.
| Comment hidden (mozreview-request) |
| Comment hidden (mozreview-request) |
Attachment #8831240 -
Flags: review?(mstange)
Comment 3•9 years ago
|
||
| mozreview-review | ||
Comment on attachment 8831240 [details]
Bug 1334554 - Handle the return value of nsFilterInstance::PaintFilteredFrame
https://reviewboard.mozilla.org/r/107804/#review109164
::: layout/svg/nsFilterInstance.cpp:520
(Diff revision 2)
> - if (NS_FAILED(rv))
> - return rv;
> + if (NS_FAILED(rv)) {
> + return NSResultToDrawResult(rv);
> + }
> rv = BuildSourcePaints(aDrawTarget);
> - if (NS_FAILED(rv))
> - return rv;
> + if (NS_FAILED(rv)){
> + return NSResultToDrawResult(rv);
> + }
Can you make BuildSourceImage and BuildSourcePaints return a DrawResult instead?
| Comment hidden (mozreview-request) |
| Comment hidden (mozreview-request) |
Comment 6•9 years ago
|
||
| mozreview-review | ||
Comment on attachment 8831240 [details]
Bug 1334554 - Handle the return value of nsFilterInstance::PaintFilteredFrame
https://reviewboard.mozilla.org/r/107804/#review111284
Sorry for the delay; I missed the bugmail and mozreview doesn't email me when the review request is updated. Maybe I should have clicked r-.
::: layout/svg/nsFilterInstance.cpp:417
(Diff revision 4)
> {
> - nsresult rv = NS_OK;
> -
> if (!mFillPaint.mNeededBounds.IsEmpty()) {
> - rv = BuildSourcePaint(&mFillPaint, aTargetDT);
> - NS_ENSURE_SUCCESS(rv, rv);
> + DrawResult result = BuildSourcePaint(&mFillPaint, aTargetDT);
> + if (result != DrawResult::SUCCESS){
There should be a space between ) and {. This happens in a bunch of places in this patch.
::: layout/svg/nsFilterInstance.cpp:515
(Diff revision 4)
> aDrawTarget->GetTransform();
> aDrawTarget->SetTransform(newTM);
>
> ComputeNeededBoxes();
> + DrawResult result = BuildSourceImage(aDrawTarget);
> + if (DrawResult::SUCCESS != result){
Please make this "result != DrawResult::SUCCESS" (no Yoda conditions), here and below.
Attachment #8831240 -
Flags: review?(mstange) → review+
| Comment hidden (mozreview-request) |
Pushed by cku@mozilla.com:
https://hg.mozilla.org/integration/autoland/rev/ddceecc1921e
Handle the return value of nsFilterInstance::PaintFilteredFrame r=mstange
Comment 9•9 years ago
|
||
| bugherder | ||
Status: NEW → RESOLVED
Closed: 9 years ago
status-firefox54:
--- → fixed
Resolution: --- → FIXED
Target Milestone: --- → mozilla54
Updated•7 years ago
|
Component: Layout: View Rendering → Layout: Web Painting
You need to log in
before you can comment on or make changes to this bug.
Description
•