Closed Bug 292915 Opened 20 years ago Closed 20 years ago

Invalid controls not initialized as invalid

Categories

(Core Graveyard :: XForms, defect)

x86
Windows 2000
defect
Not set
normal

Tracking

(Not tracked)

RESOLVED FIXED

People

(Reporter: aaronr, Assigned: aaronr)

Details

Attachments

(2 files)

We've regressed something somewhere.  We aren't running through node validation
anymore during form load.  We still call nsXFormsMDGEngine::Revalidate, but
mChangedNodes in nsXFormsModelElement::Revalidate is empty.  The result is that
if we initialize a field with a value from an invalid type, the control is not
marked invalid.
Attached file testcase
This testcase initializes the input field with the character "a" but the type
on the bind is "xsd:integer".  I put style in the testcase so that the input
should turn red if invalid.
It has been a while since that has worked I think. The problem comes from bug
284101 I think.

The problem is that validation is never triggered if type information is the
only MIP on the instance node.
Status: NEW → ASSIGNED
Attached patch PatchSplinter Review
This patch triggers type validation after a rebuild.

(it also does adds null check but it's debug-only)
Attachment #183155 - Flags: review?(aaronr)
Comment on attachment 183155 [details] [diff] [review]
Patch

dandy!
Attachment #183155 - Flags: review?(aaronr) → review+
Attachment #183155 - Flags: review?(smaug)
Attachment #183155 - Flags: review?(smaug) → review+
Checked in.
Status: ASSIGNED → RESOLVED
Closed: 20 years ago
Resolution: --- → FIXED
Product: Core → Core Graveyard
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: