Opened 11 years ago

Closed 11 years ago

#1648 closed Bug (fixed)

resizing handles of dragresizetable plugin are created in the fckeditor.html frame

Reported by: Alfonso Martínez de Lizarrondo Owned by: Alfonso Martínez de Lizarrondo
Priority: Normal Milestone: FCKeditor 2.6
Component: General Version:
Keywords: Review+ Cc:

Description

Due to https://bugzilla.mozilla.org/show_bug.cgi?id=130078 that means that the created elements are behind the editing div and aren't visible if we are running in chrome: (write area)

The solution seems to be to use the FCK.EditorDocument to create and position those elements.

Attachments (2)

1648.patch (4.2 KB) - added by Alfonso Martínez de Lizarrondo 11 years ago.
proposal
1648_2.patch (4.0 KB) - added by Alfonso Martínez de Lizarrondo 11 years ago.
updated patch

Download all attachments as: .zip

Change History (8)

Changed 11 years ago by Alfonso Martínez de Lizarrondo

Attachment: 1648.patch added

proposal

comment:1 Changed 11 years ago by Alfonso Martínez de Lizarrondo

The proposed patch just factorizes some calls in a way that it's possible to change the behavior of the plugin easily to create the divs in the edited frame. in fact the AfterSetHTML function could be removed and _avoidStyles could be left as an empty function.

Later I just have to call

FCK.Events.AttachEvent( "OnAfterSetHTML", FCKDragTableHandler.AfterSetHTML ) ;
FCKDragTableHandler._GetIframeOffset = function() { return {x:0, y:0}; };
FCKDragTableHandler._GetTablePosition = function( w, table) { return FCKTools.GetDocumentPosition(w, table ) ; };

and that way the code will work only on the edited frame.

The drawback is that the created divs can be affected by the page styles, so doing this for the general core could be troublesome, but just the suggested changes (minus the .AfterSetHTML and leaving _avoidStyles as a dummy will make it possible to include the plugin in Write Area easily.

Thoughts? other approaches?

comment:2 Changed 11 years ago by Alfonso Martínez de Lizarrondo

Keywords: Review? added

comment:3 Changed 11 years ago by Martin Kou

The plugin works ok after the patch, but it seems to me the "AfterSetHTML()" function added in the patch is not being called?

Changed 11 years ago by Alfonso Martínez de Lizarrondo

Attachment: 1648_2.patch added

updated patch

comment:4 Changed 11 years ago by Alfonso Martínez de Lizarrondo

Owner: set to Alfonso Martínez de Lizarrondo

You're right.

That function isn't needed in this code, it should be created by the external code that will adjust the other functions.

comment:5 Changed 11 years ago by Martin Kou

Keywords: Review+ added; Review? removed

comment:6 Changed 11 years ago by Alfonso Martínez de Lizarrondo

Milestone: FCKeditor 2.6
Resolution: fixed
Status: newclosed

Fixed with [1365]

Note: See TracTickets for help on using tickets.
© 2003 – 2019 CKSource – Frederico Knabben. All rights reserved. | Terms of use | Privacy policy