Opened 16 years ago
Closed 16 years ago
#3448 closed Bug (fixed)
Images aren't selectable in Safari
Reported by: | Alfonso Martínez de Lizarrondo | Owned by: | Garry Yao |
---|---|---|---|
Priority: | Normal | Milestone: | CKEditor 3.0 |
Component: | General | Version: | SVN (CKEditor) - OLD |
Keywords: | Confirmed Review+ | Cc: |
Description
There's some specific code in V2 to handle this in fck_gecko.js (can't find right now the original ticket)
this.EditorDocument.addEventListener( 'mousedown', function( ev ) { var element = ev.srcElement ; if ( element.nodeName.IEquals( 'IMG', 'HR', 'INPUT', 'TEXTAREA', 'SELECT' ) ) { FCKSelection.SelectNode( element ) ; } }, true ) ; this.EditorDocument.addEventListener( 'mouseup', function( ev ) { if ( ev.srcElement.nodeName.IEquals( 'INPUT', 'TEXTAREA', 'SELECT' ) ) ev.preventDefault() }, true ) ; this.EditorDocument.addEventListener( 'click', function( ev ) { if ( ev.srcElement.nodeName.IEquals( 'INPUT', 'TEXTAREA', 'SELECT' ) ) ev.preventDefault() }, true ) ;
Also the last functions take care of disabling the default behavior of those elements.
Attachments (3)
Change History (12)
comment:1 Changed 16 years ago by
Keywords: | Confirmed added |
---|---|
Milestone: | → CKEditor 3.0 |
comment:2 Changed 16 years ago by
Owner: | set to Garry Yao |
---|---|
Status: | new → assigned |
Changed 16 years ago by
Attachment: | 3348.patch added |
---|
comment:3 Changed 16 years ago by
Keywords: | Review? added |
---|
comment:4 follow-up: 6 Changed 16 years ago by
Keywords: | Review? removed |
---|
The fix should also impact all other none-IE browser.
Changed 16 years ago by
Attachment: | 3448_2.patch added |
---|
comment:5 Changed 16 years ago by
Keywords: | Review? added |
---|
comment:6 Changed 16 years ago by
Keywords: | Review- added; Review? removed |
---|
This patch is breaking things on Firefox. I mean, the images selection is broken with it.
Other than that, this implementation is different from the solution we have in V2. That would be ok, if it would work properly. But, it makes it impossible to drag images now.
Please make a full test with all interested elements in all browsers.
Changed 16 years ago by
Attachment: | 3448_3.patch added |
---|
comment:7 Changed 16 years ago by
Keywords: | Review? added; Review- removed |
---|
My fault, I didn't take D&D into considering with the initial willing to simplify the hack here.
Sadly under Firefox, certain form controls e.g. 'checkbox' and 'radio' is still unselectable afer this patch, since these elements doesn't fire 'click'/'mousedown' at all, I guess we can hardly do anything with it due to this browser bug.
comment:8 Changed 16 years ago by
Keywords: | Review+ added; Review? removed |
---|
comment:9 Changed 16 years ago by
Resolution: | → fixed |
---|---|
Status: | assigned → closed |
Not sure if we need to have a directory in dtd for these control type element.