Closed Bug 1667600 Opened 5 years ago Closed 5 years ago

View Image error on canvas

Categories

(SeaMonkey :: General, defect)

defect

Tracking

(seamonkey2.53+ fixed, seamonkey2.57esr? affected)

RESOLVED FIXED
seamonkey 2.80
Tracking Status
seamonkey2.53 + fixed
seamonkey2.57esr ? affected

People

(Reporter: buc, Assigned: buc)

References

()

Details

(Whiteboard: SM2.53.5)

Attachments

(1 file, 1 obsolete file)

Clicking "View Image" on a Canvas (which probably the same time is a frame) produces an error:

Error: TypeError: Argument 1 is not valid for any of the 1-argument overloads of URL.createObjectURL.
Source File: chrome://communicator/content/nsContextMenu.js
Line: 1127

The problem is
let blobUrl = URL.createObjectURL(this.target);
because this.target.toBlob() must be used rather then just this.target .
(And toBlob() canvas method is async).

Note, the correspond Fx part has toBlob()

Preliminary patch attached (fixed the issue).

Flags: needinfo?(frgrahl)

Was introduced by the patch from the bug #1234651

Assignee: nobody → dmitry
Status: UNCONFIRMED → ASSIGNED
Ever confirmed: true
Flags: needinfo?(frgrahl)
Whiteboard: SM2.53.5
Version: SeaMonkey 2.53 Branch → Trunk

Reformatted as hg patch for checkin and using arrow function. Tested with 2.53.5.
r/a+ from me. Thanks++

Attachment #9178047 - Attachment is obsolete: true
Attachment #9180389 - Flags: review+
Attachment #9180389 - Flags: approval-comm-release+
Attachment #9180389 - Flags: approval-comm-esr60+

Pushed by frgrahl@gmx.net:
https://hg.mozilla.org/comm-central/rev/a1f2a0bfff8d
Use toBlob for viewing media files on a canvas. r=frg

Status: ASSIGNED → RESOLVED
Closed: 5 years ago
Resolution: --- → FIXED
Target Milestone: --- → seamonkey 2.80
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: