Closed
Bug 32481
Opened 25 years ago
Closed 25 years ago
document.getSelection() needs to be implemented
Categories
(Core :: DOM: Core & HTML, enhancement, P3)
Core
DOM: Core & HTML
Tracking
()
RESOLVED
FIXED
M16
People
(Reporter: german, Assigned: jst)
References
Details
Attachments
(1 file)
(deleted),
patch
|
Details | Diff | Splinter Review |
in 4.x the JS function document.getSelection() returned the currently selected
text in a window. While this was a Netscape-only feature many websites make use
of it. This does not currently work in Mozilla. This would be great thing to
have for Mozilla.
If this will not be implemented, the resolution of this bug should be a note
added the developer release notes. It should include how this feature could be
accomplished in a different way (using DOM or XPCom maybe?)
Feel free to change the component/foward to other owner if JS Engine is the
wrong one.
Updated•25 years ago
|
Keywords: 4xp
Summary: [4.x P] document.getSelection() no longer supported → document.getSelection() no longer supported
Comment 1•25 years ago
|
||
This would be a DOM 4xp enhancement. Reassigning to joki for now.
Although we terminated the Layer DOM API in particular, it would be nice if we
could provide as much backward compatibility as possible for other Nav4
extensions where it's possible to do so without violating standards or incurring
major development costs.
This would should be prioritized as less important than implementing and
debugging the W3C standards, but ideally something we'd like to get in for
beta2. Is there an easy way to implement this by invoking the DOM2 code for
getting the current selection?
Assignee: rogerl → joki
Summary: document.getSelection() no longer supported → document.getSelection() needs to be implemented
Assignee | ||
Comment 2•25 years ago
|
||
Assignee | ||
Comment 3•25 years ago
|
||
The patch I just attached makes document.getSelection() work in mozilla very
much the same way it works in NS 4.x. Apparently the patch removes a lot of
useful debuggin code that is used by the editor so we'll probably haveto change
the patch to work better together with the editor before checkin this in.
Cc:ing akkana and myself.
Comment 4•25 years ago
|
||
cc self.
Comment 6•25 years ago
|
||
reassign to jst; reset component
Assignee: joki → jst
Component: Javascript Engine → DOM Level 0
Target Milestone: --- → M16
Assignee | ||
Comment 7•25 years ago
|
||
This is finally done, document.getSelection() returns the selected text as a
string, and it puts a message in the console saying the document.getSelection()
is depricated, use window.getSelection() in stead. window.getSelection() is also
implemented but that returns a selection object in stead of a string.
Marking FIXED.
Status: NEW → RESOLVED
Closed: 25 years ago
Resolution: --- → FIXED
You need to log in
before you can comment on or make changes to this bug.
Description
•