Closed
Bug 381005
Opened 18 years ago
Closed 8 years ago
Return NS_ERROR_DOM_NOT_FOUND_ERR when DOM node has been removed from document
Categories
(Core :: Disability Access APIs, enhancement)
Core
Disability Access APIs
Tracking
()
RESOLVED
WONTFIX
People
(Reporter: MatsPalmgren_bugz, Unassigned)
References
(Blocks 1 open bug)
Details
(Whiteboard: [bk1])
I think it would add to the overall quality of the API if we could
return more specific error codes rather than using NS_ERROR_FAILURE.
One specific and common error is when API methods are called after the
corresponding DOM node has been removed from the document (eg. bug 379872),
for this error I suggest using NS_ERROR_DOM_NOT_FOUND_ERR, which prints as:
Exception... "Node was not found" code: "8" nsresult: "0x80530008
(NS_ERROR_DOM_NOT_FOUND_ERR)" ...
I think this is more informative than the generic NS_ERROR_FAILURE.
Comment 1•18 years ago
|
||
Looks reasonable for cross platform part since in gecko accessible objects and DOM nodes are close bound things. I don't know how to map it to HRESULT and I guess it doesn't makes a sense at all.
Updated•14 years ago
|
Status: UNCONFIRMED → NEW
Ever confirmed: true
Updated•13 years ago
|
Whiteboard: [bk1]
Comment 2•8 years ago
|
||
Are we planning to do anything with this, or is our defunct state enough to handle this case?
Flags: needinfo?(surkov.alexander)
Comment 3•8 years ago
|
||
An accessible object may be dead for different reasons, it may be defunct even if its related DOM node is in DOM still. Also that affect our XPCOM API, which I wouldn't make much attention on it, as I'm not sure how long it will be kept alive. Suggesting to close this one as wontfix.
Status: NEW → RESOLVED
Closed: 8 years ago
Flags: needinfo?(surkov.alexander)
Resolution: --- → WONTFIX
You need to log in
before you can comment on or make changes to this bug.
Description
•