Closed
Bug 330825
Opened 19 years ago
Closed 19 years ago
select1 doesn't suppress value changed event sequence when incremental != true
Categories
(Core Graveyard :: XForms, defect)
Tracking
(Not tracked)
RESOLVED
FIXED
People
(Reporter: sspeiche, Assigned: sspeiche)
References
Details
(Keywords: fixed1.8.0.4, fixed1.8.1)
Attachments
(2 files, 2 obsolete files)
(deleted),
application/xhtml+xml
|
Details | |
(deleted),
patch
|
Details | Diff | Splinter Review |
User-Agent: Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.1) Opera 7.55 [en] (IBM EVV/3.8/EAK01AGF/LE)
Build Identifier:
1.0 Test suite case 4.6.3.b
When incremental != true the value changed events shouldn't be dispatched.
Also, the logic is backwards for the default for incremental (for both select and select1).
'incremental' should be treated as false, unless explicitly set to true or not present.
Reproducible: Always
Steps to Reproduce:
1. Load supplied test cases and observer results
I have a patch for this already, will attach after a little more testing/work.
Assignee | ||
Comment 1•19 years ago
|
||
Assignee | ||
Comment 2•19 years ago
|
||
Comment 3•19 years ago
|
||
> Also, the logic is backwards for the default for incremental (for both select
> and select1).
> 'incremental' should be treated as false, unless explicitly set to true or not
> present.
Why this way? Why not treating it false only if it is really 'false'. Otherwise
'true', since it is the default value.
Assignee | ||
Comment 4•19 years ago
|
||
(In reply to comment #3)
> Why this way? Why not treating it false only if it is really 'false'. Otherwise
> 'true', since it is the default value.
>
http://www.w3.org/TR/2006/REC-xforms-20060314/slice4.html#sequence-for-select says (2nd bullet):
"the form control does not have the incremental="true" setting"
therefore, if not explicity set to "true" (or not set at all), it should only do: 4.6.6 Sequence: Selection Without Value Change
Actually, I can't find anywhere in the spec that says incremental = 'true' is the default. If I read the 2nd bullet literally, then the default is 'false'.
Comment 5•19 years ago
|
||
http://www.w3.org/TR/xforms/slice8.html#ui-selectOne
"incremental
When true, this form control will generate additional xforms-value-changed events. The default for this form control is true."
Comment 6•19 years ago
|
||
Also in the schema:
<xsd:attribute name="incremental" type="xsd:boolean" use="optional" default="true"/>
Assignee: aaronr → sspeiche
Status: UNCONFIRMED → NEW
Ever confirmed: true
Assignee | ||
Comment 7•19 years ago
|
||
Comment on attachment 215409 [details]
test case that shows incremental = junk
since the type is really, xsd:boolean this is invalid. section 4.6.3 was not clear on that but section 8 is very clear
Attachment #215409 -
Attachment is obsolete: true
Assignee | ||
Comment 8•19 years ago
|
||
It also appears that the event sequencing is wrong for select1. Should be 'Selection without value change' followed by 'Value change', the 'value change' is happening first. Will attempt to fix both.
Assignee | ||
Comment 9•19 years ago
|
||
Opened bug 332242 for the sequence for select/deselect events before value change
Attachment #216757 -
Flags: review?(allan)
Assignee | ||
Updated•19 years ago
|
Attachment #216757 -
Flags: review?(doronr)
Comment 10•19 years ago
|
||
Comment on attachment 216757 [details] [diff] [review]
patch, only handles incremental='false'..not sequence of events
looks good, I'll let allan deal with the spec concerns if any are left.
Attachment #216757 -
Flags: review?(doronr) → review+
Comment 11•19 years ago
|
||
Comment on attachment 216757 [details] [diff] [review]
patch, only handles incremental='false'..not sequence of events
>Index: resources/content/select1.xml
>===================================================================
>+ <property name="incremental">
As this is a readonly property, please use readonly="true".
>+ <getter>
>+ <![CDATA[
>+ // default is true
>+ var incremental = true;
>+
>+ if (this.hasAttribute("incremental")) {
>+ if (this.getAttribute("incremental") == "false")
>+ incremental = false;
>+ }
>+
>+ return incremental;
No need to check for the attribute presence first, the get() call will return the empty string if the attribute is not there. So the entire function is just:
return this.getAttribute("incremental") != "false";
With that fixed, r=me
Attachment #216757 -
Flags: review?(allan) → review+
Assignee | ||
Comment 12•19 years ago
|
||
Attachment #216757 -
Attachment is obsolete: true
Comment 13•19 years ago
|
||
checked in to trunk for sspecihe
Status: NEW → RESOLVED
Closed: 19 years ago
Resolution: --- → FIXED
Whiteboard: xf-to-branch
Updated•19 years ago
|
Keywords: fixed1.8.0.3,
fixed1.8.1
Updated•19 years ago
|
Whiteboard: xf-to-branch
Updated•8 years ago
|
Product: Core → Core Graveyard
You need to log in
before you can comment on or make changes to this bug.
Description
•