Closed Bug 21534 Opened 25 years ago Closed 25 years ago

using ^k keybinding in text field causes javascript error

Categories

(Core :: Layout: Form Controls, defect, P3)

x86
Linux
defect

Tracking

()

VERIFIED FIXED

People

(Reporter: blizzard, Assigned: akkzilla)

Details

Attachments

(1 file)

In any text field on unix, doing a ^k in a text field causes a javascript error:

Selection controller interface didn't work!
###!!! ASSERTION:
NS_ENSURE_TRUE(NS_SUCCEEDED(editor->DeleteSelection(nsIEditor::eToEndOfLine)))
failed: '(!((editor->DeleteSelection(nsIEditor::eToEndOfLine)) & 0x80000000))',
file nsEditorController.cpp, line 308
###!!! Break: at file nsEditorController.cpp, line 308
JavaScript Error: uncaught exception: [Exception... "Component returned failure
code: 0x80004005 (NS_ERROR_FAILURE) [nsIController.doCommand]"  nsresult:
"0x80004005 (NS_ERROR_FAILURE)"  location: "JS frame :: <unknown filename> ::
onkeypress :: line 0"  data: no]
Assignee: karnaze → buster
Reassigning to Steve.
Assignee: buster → akkana
assigning to akkana, who I think implemented the keybinding, and cc'ing joe, who
wrote the underlying deletion code.  Removing vidur from the cc list because I
don't think he cares.
Assignee: akkana → mjudge
This is a bug with the selection controller implementation -- WordMove and
IntraLineMove don't work yet.  Mike knows about it and is working on it.
Target Milestone: M13
setting to m13
Assignee: mjudge → akkana
I'm taking this bug, and have found a fix.  The problem is that selection won't
handle moving when batching is on, as it is for the delete selection
transaction.  A solution is to move the selection-motion outside the batching,
and do it in nsHTMLEditor::DeleteSelection rather than in
nsEditor::CreateTxnForDeleteSelection.  I'll attach a patch, and will get Mike
to look at it tomorrow and tell me whether this is the right fix.
Status: NEW → ASSIGNED
Target Milestone: M13 → M12
Marking M12 -- this is part of Mike's selection controller stuff, which is PDT+,
and the fix for this part is simple.
Fixed!
Status: ASSIGNED → RESOLVED
Closed: 25 years ago
Resolution: --- → FIXED
I guess it would help to check the "Fixed" box, too. :-)
Updating QA contact.
QA Contact: ckritzer → bsharma
Verified build 2001080708 os:linix7.1
Status: RESOLVED → VERIFIED
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: