The default bug view has changed. See this FAQ.

Ephemeral message: Does not support src and displays both inline and binding text

RESOLVED DUPLICATE of bug 338135

Status

Core Graveyard
XForms
RESOLVED DUPLICATE of bug 338135
12 years ago
8 months ago

People

(Reporter: aaronr, Assigned: Merle Sterling)

Tracking

Dependency tree / graph

Firefox Tracking Flags

(Not tracked)

Details

Attachments

(2 attachments)

(Reporter)

Description

12 years ago
Right now if you have an ephemeral message with both a single node bind and
inline text, both will show.  Also, an ephemeral message will not link to an
external resource (via @src).
(Reporter)

Comment 1

12 years ago
Created attachment 189388 [details]
external resource file for testcase
(Reporter)

Comment 2

12 years ago
Created attachment 189389 [details]
testcase
(Reporter)

Comment 3

12 years ago
As part of https://bugzilla.mozilla.org/show_bug.cgi?id=300255 I'll be checking
in code that will sniff the external resource (value of the @src) to make sure
that it exists before going off to do all of the work that
nsXFormsMessageElement does when it displays a message.  For ephemeral messages,
it would make sense not to sniff, but rather grab the resource and cache its
contents to later be used in: nsXFormsMessageElement::HandleEphemeralMessage().
 Please consider this while fixing this bug.

Updated

12 years ago
Summary: ephemeral message problems → Ephemeral message: Does not support src and displays both inline and binding text

Comment 4

12 years ago
*** Bug 301607 has been marked as a duplicate of this bug. ***

Updated

11 years ago
Blocks: 322255
(Reporter)

Updated

11 years ago
Blocks: 326372
(Reporter)

Updated

11 years ago
Blocks: 326373
(Reporter)

Updated

11 years ago
Assignee: aaronr → doronr

Comment 5

11 years ago
So here is what is happening:

NS_IMETHODIMP
nsXFormsMessageElement::GetInsertionPoint(nsIDOMElement **aElement)
{
  NS_IF_ADDREF(*aElement = mVisualElement);
  return NS_OK;
}

GetInsertionPoint returns the visual element that we show/hide, so the text content of the xforms:message is added.

However, DOM3NODE->SetTextContent() does not overwrite that value, so we end up with this bug.  Returning null for GetInsertionPoint makes the testcase work, but obviously won't display inline text anymore.

Any ideas how we should handle this?  Aaron says we have crashers in repeat if we return null in GetInsertionPoint, so not sure if that is safe for message or not.

Comment 6

11 years ago
(In reply to comment #5)
> Any ideas how we should handle this?  Aaron says we have crashers in repeat if
> we return null in GetInsertionPoint, so not sure if that is safe for message 
> or not.

We definately have some problems with that. I think XTF is to blame somehow, and I think it is related to (if not the same as) the crash in bug 330903.

Comment 7

11 years ago
This fails testsuite testcase: 8.3.5.c
(Reporter)

Updated

11 years ago
Assignee: doronr → msterlin
(Assignee)

Updated

11 years ago
Status: NEW → ASSIGNED
(Assignee)

Comment 8

11 years ago
Linking to an external resource via @src is fixed by the initial patch for bug 338135, but single node binding was not implemented. Because the two bugs are closely related and the fix must work for both, I am duping this bug to 338135.
 

*** This bug has been marked as a duplicate of 338135 ***
Status: ASSIGNED → RESOLVED
Last Resolved: 11 years ago
Resolution: --- → DUPLICATE
Product: Core → Core Graveyard
You need to log in before you can comment on or make changes to this bug.