textarea/textfield can only select all, partial selections not working

VERIFIED FIXED

Status

()

P3
major
VERIFIED FIXED
18 years ago
18 years ago

People

(Reporter: 1212mozilla, Assigned: pollmann)

Tracking

({regression})

Trunk
x86
All
regression
Points:
---

Firefox Tracking Flags

(Not tracked)

Details

(Whiteboard: [dogfood+]fix in hand)

(Reporter)

Description

18 years ago
Selecting part of the text in a textarea or a textfield no longer works.  When
you select some of the text with the mouse, upon the release of the mouse
button, the enire contents gets selected.  If you double click on a word with
the mouse to select the word, the word gets highlighted for milliseconds before
the entire text gets highlighted.  If you hold down shift, and use the arrow
keys to select text, the entire text gets highlighted almost immediatly.

I discovered this with the most recent nightly build.  It is a problem on any
web site that has text input areas as well as in the mozilla menus such as the
bookmark manager.

Comment 1

18 years ago
everything gets auto-selected on mouseup. It's impossible to correct any typos
this way, you think you're about to delete a word but wind up deleting
everything you've written. Confirming and raising severity.

Build 2000090721
Severity: normal → major
Status: UNCONFIRMED → NEW
Ever confirmed: true

Comment 2

18 years ago
Changing component - this is selection, not HTML element..
Assigning to akkana - new QA needed.
Assignee: clayton → akkana
Component: HTML Element → Selection

Comment 3

18 years ago
adding keyword
Keywords: regression

Comment 4

18 years ago
Note: Only the text one manually selected is actually copied to clipboard.
Even if the rest is marked selected, and typing now will delete all, it isn't
copied. This has caused me annoying data-loss several times today already.

Comment 5

18 years ago
*** Bug 51866 has been marked as a duplicate of this bug. ***

Comment 6

18 years ago
this is dogfood.
Keywords: dogfood

Comment 7

18 years ago
adding nsbeta3 keyword, seeing on win98 as well.
Keywords: nsbeta3
OS: Linux → All

Comment 8

18 years ago
This is being caused by pollmann's nsHTMLInputElement.cpp checkin (revision
1.139)

http://bonsai.mozilla.org/cvsview2.cgi?diff_mode=context&whitespace_mode=show&root=&subdir=mozilla/layout/html/content/src&command=DIFF_FRAMESET&root=&file=nsHTMLInputElement.cpp&rev1=1.138&rev2=1.139

Here's the stack that explains why:

#0  nsSelection::SelectAll (this=0x87c3850) at nsSelection.cpp:2075
#1  0x4158496e in nsTextInputSelectionImpl::SelectAll (this=0x87be238)
    at nsGfxTextControlFrame2.cpp:822
#2  0x4158b456 in nsGfxTextControlFrame2::SetProperty (this=0x86e17b4, 
    aPresContext=0x82cca48, aName=0x814d060, aValue=@0xbfffea58)
    at nsGfxTextControlFrame2.cpp:2341
#3  0x414b0e30 in nsHTMLInputElement::SelectAll (this=0x8791340, 
    aPresContext=0x82cca48) at nsHTMLInputElement.cpp:712
#4  0x414b2305 in nsHTMLInputElement::HandleDOMEvent (this=0x8791340, 
    aPresContext=0x82cca48, aEvent=0xbfffee04, aDOMEvent=0x0, aFlags=1, 
    aEventStatus=0xbfffee28) at nsHTMLInputElement.cpp:1036
#5  0x41582c29 in nsTextInputListener::NotifySelectionChanged (this=0x87e95e0, 
    aDoc=0x839bd84, aSel=0x87bf150, aReason=4)
    at nsGfxTextControlFrame2.cpp:335
#6  0x41728a6e in nsDOMSelection::NotifySelectionListeners (this=0x87bf150)
    at nsSelection.cpp:6665
#7  0x41718c71 in nsSelection::NotifySelectionListeners (this=0x87c3850, 
    aType=1) at nsSelection.cpp:2133
#8  0x417180d7 in nsSelection::SetMouseDownState (this=0x87c3850, aState=0)
    at nsSelection.cpp:1841
#9  0x41584e9c in nsTextInputSelectionImpl::SetMouseDownState (this=0x87be238, 
    aState=0) at nsGfxTextControlFrame2.cpp:928
#10 0x413feb5d in nsFrame::HandleRelease (this=0x86e1c38, 
    aPresContext=0x82cca48, aEvent=0xbffff3c8, aEventStatus=0xbffff2c4)
    at nsFrame.cpp:1486
#11 0x413fbab4 in nsFrame::HandleEvent (this=0x86e1c38, 
    aPresContext=0x82cca48, aEvent=0xbffff3c8, aEventStatus=0xbffff2c4)
    at nsFrame.cpp:774
#12 0x41439f22 in PresShell::HandleEventInternal (this=0x814d788, 
    aEvent=0xbffff3c8, aView=0x87bb4d0, aStatus=0xbffff2c4)
    at nsPresShell.cpp:4057
#13 0x41439a38 in PresShell::HandleEvent (this=0x814d788, aView=0x87bb4d0, 
    aEvent=0xbffff3c8, aEventStatus=0xbffff2c4, aForceHandle=1, 
    aHandled=@0xbffff268) at nsPresShell.cpp:3977
#14 0x41ce536b in ?? ()
   from
/home/kin/builds/mozilla.09_08_00/mozilla/dist/bin/components/libgkview.so
#15 0x41cf0125 in ?? ()
   from
/home/kin/builds/mozilla.09_08_00/mozilla/dist/bin/components/libgkview.so
#16 0x41ce49d4 in ?? ()
   from
/home/kin/builds/mozilla.09_08_00/mozilla/dist/bin/components/libgkview.so
#17 0x40c3bf38 in ?? ()
   from
/home/kin/builds/mozilla.09_08_00/mozilla/dist/bin/components/libwidget_gtk.so
#18 0x40c3bb7c in ?? ()
   from
/home/kin/builds/mozilla.09_08_00/mozilla/dist/bin/components/libwidget_gtk.so
#19 0x40c3bff0 in ?? ()
   from
/home/kin/builds/mozilla.09_08_00/mozilla/dist/bin/components/libwidget_gtk.so
(More stack frames follow...)
Assignee: akkana → pollmann

Comment 9

18 years ago
Switching QA Contact to blakeross@telocity.com since its a selection issue.
QA Contact: lorca → blakeross

Comment 10

18 years ago
*** Bug 51898 has been marked as a duplicate of this bug. ***
(Assignee)

Comment 11

18 years ago
Oops, didn't think about this nasty side effect of my checkin + the very recent
addition of select events firing when they should.  I'll have a fix in a flash. 
Thanks for the stack trace!
Status: NEW → ASSIGNED
(Assignee)

Comment 12

18 years ago
Got it, will check in after the pre-checkins plus some more intensive text input
selection tests to make sure nothing *else* regresses.  :)
Whiteboard: fix in hand

Comment 13

18 years ago
Putting on the dogfood-plus radar
Whiteboard: fix in hand → [dogfood+]fix in hand
(Assignee)

Comment 14

18 years ago
Fix checked in.  To verify, type something in the URL bar.  Select just a
portion of that URL.  The rest should not be selected automajically for you
anymore.

Sorry about the regression, thanks for the quick catch (and thanks for the
phonecall Simon).  :)
Status: ASSIGNED → RESOLVED
Last Resolved: 18 years ago
Resolution: --- → FIXED

Comment 15

18 years ago
Verifying fix, linux CVS from 090820. Thanks!
Status: RESOLVED → VERIFIED

Comment 16

18 years ago
*** Bug 51986 has been marked as a duplicate of this bug. ***

Comment 17

18 years ago
*** Bug 52009 has been marked as a duplicate of this bug. ***

Comment 18

18 years ago
*** Bug 52174 has been marked as a duplicate of this bug. ***

Comment 19

18 years ago
*** Bug 52288 has been marked as a duplicate of this bug. ***
*** Bug 52412 has been marked as a duplicate of this bug. ***
You need to log in before you can comment on or make changes to this bug.