Opened 16 years ago

Closed 16 years ago

#2043 closed Task (fixed)

The FCKDebug code should not be included in the compressed files

Reported by: Frederico Caldeira Knabben Owned by: Frederico Caldeira Knabben
Priority: Normal Milestone: FCKeditor 2.6.2
Component: General Version:
Keywords: Confirmed Review+ Cc:

Description

We don't need anything from FCKDebug when normally using the editor. We should be able so to avoid including its code inside the compressed files to save some bytes from it. The solution would be loading fckdebug.js by request, only if debugging is enabled.

Our code may have some debugging calls laying around, so the compressed files should still contain the debugging functions, but those should be empty. We could use @Packager.Remove.Start and @Packager.Remove.End to easily achieve that.

Attachments (2)

2043.patch (2.1 KB) - added by Martin Kou 16 years ago.
2043_2.patch (5.9 KB) - added by Frederico Caldeira Knabben 16 years ago.

Download all attachments as: .zip

Change History (7)

Changed 16 years ago by Martin Kou

Attachment: 2043.patch added

comment:1 Changed 16 years ago by Martin Kou

Keywords: Review? added
Owner: set to Martin Kou
Status: newassigned

comment:2 Changed 16 years ago by Frederico Caldeira Knabben

Keywords: Review- added; Review? removed
Owner: changed from Martin Kou to Frederico Caldeira Knabben
Status: assignednew

I had a different idea actually. I still wanted to make it possible to debug with the distributed code, even when running the compressed scripts. The proposed patch instead completely remove the debug code from the distribution, and also don't include it at all in the compressed files, which may case runtime bugs if any FCKDebug call remained in the code.

All this is quite difficult to explain in words, so I'll just attach a new patch for it.

Changed 16 years ago by Frederico Caldeira Knabben

Attachment: 2043_2.patch added

comment:3 Changed 16 years ago by Frederico Caldeira Knabben

Keywords: Review? added; Review- removed
Status: newassigned

I've figured out that the Packager.Remove.Start idea was not good. The proposed patch adds a new empty file instead.

I've also taken the opportunity to rewrite the FCKDebug object definition in fckdebug.js. No code changes, just the declaration format.

comment:4 Changed 16 years ago by Martin Kou

Keywords: Review+ added; Review? removed

comment:5 Changed 16 years ago by Frederico Caldeira Knabben

Resolution: fixed
Status: assignedclosed

Fixed with [2069]. Click here for more info about our SVN system.

Note: See TracTickets for help on using tickets.
© 2003 – 2022, CKSource sp. z o.o. sp.k. All rights reserved. | Terms of use | Privacy policy