Opened 11 years ago

Closed 11 years ago

Last modified 8 years ago

#7740 closed defect (fixed)

Textarea: onChange does not work in Iceweasel

Reported by: Jonathan Bowers Owned by:
Priority: high Milestone: 1.3
Component: Dijit - Form Version: 1.2beta
Keywords: dijit.form.Textarea Cc:
Blocked By: Blocking:

Description

Due to some calls in dijit.form.Textarea to dojo.isFF, the text area does not render properly in Iceweasel resulting in onChange not being accurate.

Test:

http://download.dojotoolkit.org/release-1.2.0rc1/dojo-release-1.2.0rc1/dijit/tests/form/test_Textarea.html

Using Iceweasel (you can fake this by changing your general.useragent.extra.firefox setting in about:config in Firefox from "Firefox" to "Iceweasel") if you type in the text area, then change focus somewhere outside the textarea widget, the onChange is not called correctly.

If in Iceweasel, setting your useragent to "Firefox" causes everything to work fine.

Systems affected:

Iceweasel 2.0.0.x/3.0.x on Debian

Related ticket:

ticket:3974 This ticket discusses the use of dojo.isFF and indicates that the problem is NOT in an incorrect definition of dojo.isFF for Iceweasel browers.

Workaround:

A simple work around is to redefine the dojo.isFF value somewhere after the dojocore has been loaded:

// Fix detection of Iceweasel.
if(dojo.isMoz)
{
   dojo.isFF = parseFloat(navigator.userAgent.split("Firefox/")[1]) || parseFloat(navigator.userAgent.split("Iceweasel/")[1]) || 0;
}

In looking at ticket:3974, this workaround is an incorrect solution

Change History (7)

comment:1 Changed 11 years ago by bill

Milestone: tbdfuture
Summary: dijit.form.Textarea onChange does not work in IceweaselTextarea: onChange does not work in Iceweasel

Well, dijit doesn't support Iceweasel, just FF2 and FF3. I guess the text on http://dojotoolkit.org/support/faq/what-browsers-does-dojo-support is somewhat ambiguous but that's our policy.... I'm not sure if this ticket is really about Iceweasel or it's about FF on linux with the weird version string, as per #3974.

If you'd like to file a CLA and submit patches for Iceweasel we can probably integrate them. Perhaps it's just a question of changing dojo.isFF to dojo.isMoz in some places, but given that we are branching based on FF2 vs FF3 (specifically whether contentEditableDiv is available), it seems more complicated.

comment:2 Changed 11 years ago by Douglas Hays

(In [16090]) Fixes #2178, #4988, #7383, #8063, #8211, #8222, #8274, #8276. References #7740. Refactor the Textarea widget to use a native TEXTAREA element. IE8 beta 2 in strict mode will not auto-resize.

comment:3 Changed 11 years ago by Douglas Hays

Is this defect fixed by [16090]?

comment:4 Changed 11 years ago by Jonathan Bowers

This appears to be fixed after testing on http://archive.dojotoolkit.org/nightly/dojotoolkit/dijit/tests/form/test_Textarea.html (2008-01-13)

onChange box updates properly.

comment:5 Changed 11 years ago by bill

Resolution: fixed
Status: newclosed

Great.

comment:6 Changed 11 years ago by bill

Milestone: future1.3

comment:7 Changed 8 years ago by bill

Component: DijitDijit - Form
Note: See TracTickets for help on using tickets.