Remove NFC_GECKO_ERROR_NOT_ENABLED error from Nfc.js

RESOLVED FIXED

Status

Firefox OS
NFC
RESOLVED FIXED
3 years ago
3 years ago

People

(Reporter: allstars, Assigned: dimi)

Tracking

Firefox Tracking Flags

(Not tracked)

Details

(Whiteboard: [p=1])

Attachments

(1 attachment, 3 obsolete attachments)

(Reporter)

Description

3 years ago
If an app calls NFC API (power API excluded, like startPoll, stopPoll or powerOff) when NFC HW is not enabled, this API should throw, right now we treat it as onerror in DOMRequest.
(Reporter)

Updated

3 years ago
No longer blocks: 1042851
(Assignee)

Updated

3 years ago
Assignee: nobody → dlee
(Reporter)

Updated

3 years ago
Depends on: 1095322
(Reporter)

Updated

3 years ago
Blocks: 1042851
(Assignee)

Comment 1

3 years ago
Created attachment 8528239 [details] [diff] [review]
Patch v1

In this patch I treat |enable| as discovery mode because in listen mode NFC API should not be allowed.
Attachment #8528239 - Flags: review?(allstars.chh)
(Assignee)

Updated

3 years ago
Attachment #8528239 - Attachment is obsolete: true
Attachment #8528239 - Flags: review?(allstars.chh)
(Assignee)

Updated

3 years ago
Summary: Calling NFC API when NFC is not enabled should throw → Remove NOT_ENABLED error from Nfc.js
(Assignee)

Updated

3 years ago
Summary: Remove NOT_ENABLED error from Nfc.js → Remove NFC_GECKO_ERROR_NOT_ENABLED error from Nfc.js
(Assignee)

Comment 2

3 years ago
In child process we will check |isLost| attribute to determine if tag/peer API is callable.
So check is enable in Nfc.js is not necessary
(Assignee)

Comment 3

3 years ago
Created attachment 8528274 [details] [diff] [review]
Patch v2
Attachment #8528274 - Flags: review?(allstars.chh)
(Reporter)

Updated

3 years ago
No longer blocks: 1042851
(Reporter)

Updated

3 years ago
No longer depends on: 1095322
(Reporter)

Updated

3 years ago
Attachment #8528274 - Flags: review?(allstars.chh) → review+
(Assignee)

Updated

3 years ago
Keywords: checkin-needed
Whiteboard: [p=1]
(Reporter)

Comment 4

3 years ago
need to rebase since Bug 1085296 is landed.
Keywords: checkin-needed
(Assignee)

Comment 5

3 years ago
Created attachment 8528978 [details] [diff] [review]
Patch v3

rebase to latest code
Attachment #8528274 - Attachment is obsolete: true
Attachment #8528978 - Flags: review+
(Assignee)

Updated

3 years ago
Keywords: checkin-needed
Try link? :)
Keywords: checkin-needed
(Assignee)

Comment 7

3 years ago
try link : https://tbpl.mozilla.org/?tree=Try&rev=f6c8af7ddb18
(Assignee)

Comment 8

3 years ago
Created attachment 8529661 [details] [diff] [review]
patch v4

rebase to latest code again.
Attachment #8528978 - Attachment is obsolete: true
Attachment #8529661 - Flags: review+
(Assignee)

Updated

3 years ago
Keywords: checkin-needed
(Reporter)

Comment 9

3 years ago
https://hg.mozilla.org/integration/b2g-inbound/rev/5bbffe503f7b
Keywords: checkin-needed
https://hg.mozilla.org/mozilla-central/rev/5bbffe503f7b
Status: NEW → RESOLVED
Last Resolved: 3 years ago
Resolution: --- → FIXED
You need to log in before you can comment on or make changes to this bug.