[Webkit-unassigned] [Bug 16301] New: Gmail: Gmail: Canceling an Edit Link dialog applies a link to the first line of selected text
bugzilla-daemon at webkit.org
bugzilla-daemon at webkit.org
Tue Dec 4 20:19:24 PST 2007
http://bugs.webkit.org/show_bug.cgi?id=16301
Summary: Gmail: Gmail: Canceling an Edit Link dialog applies a
link to the first line of selected text
Product: WebKit
Version: 525+ (Nightly build)
Platform: Macintosh
OS/Version: Mac OS X 10.4
Status: NEW
Keywords: InRadar
Severity: Normal
Priority: P2
Component: HTML Editing
AssignedTo: webkit-unassigned at lists.webkit.org
ReportedBy: justin.garcia at apple.com
In GMail, when I create two paragraphs of text, select them, click Edit Link,
and then cancel the Edit Link dialogue, the first paragraph is made into a
link.
When the Edit Link dialogue appears, GMail creates a link from the selection
with document.execCommand("CreateLink", ...), and then when I cancel the
dialogue, GMaill tries to remove the link by removing the last anchor in the
selection. This won't always unlink the entire selection because we sometimes
create multiple anchor elements during CreateLink to preserve the structure of
the selection. For example imagine selecting 'foo' and 'bar' below:
foo<ul><li>bar</li><li>baz</li></ul>
and performing CreateLink. WebKit will create two anchor elements since there
is no way to insert only one that contains the entire selection but does not
require splitting the list.
You could fix this issue by calling document.execCommand("Unlink") on the
selection if the user cancels out of the Edit Link dialogue.
<rdar://problem/5616266> Gmail: Clicking Cancel in Edit Link dialog applies a
link to the first line of selected text
--
Configure bugmail: http://bugs.webkit.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug, or are watching the assignee.
More information about the webkit-unassigned
mailing list