We are migrating CKEditor issue tracking to GitHub. Please, use GitHub to report any new issues.

The former tracking system (this website) will still be available in the read-only mode. All issues reported in the past will still be available publicly and can be referenced.

Important: we decided not to transfer all the tickets to GitHub, as many of them are not reproducible anymore or simply no longer requested by the community. If the issue you are interested in, can be still reproduced in the latest version of CKEditor, feel free to report it again on GitHub. At the same time please note that issues reported on this website are still taken into consideration when picking up candidates for next milestones.

Disable scrollbar of editor parent while dialog is active

Description

It would be nice to have again what effectively was a feature before 2.6. In other words, it would be nicer if somehow the vertical scroll bar of the main browser window could be disabled while a dialog is active. This is because the mouse wheel can now scroll away the whole dialog (and editor window) after a scroll bar within a dialog reaches its limit and the parent page containing the editor instance is taller than the browser window. (a little bit annoying) This of course couldn't happen from a popup.

The following:

window.document.body.style.overflow='hidden';

could work for IE, but unfortunately not FF. FF scrolls to the top before disabling the scroll bar. I'm hoping you can think of a more elegant solution.

Another slight flaw for only FF. Button state for whatever dialog you open remains in hover over state after the dialog has closed. It'll correct itself after it's been hovered over again, but isn't right on dialog close. This doesn't happen without the patch.

The compatMode thing was a mistake, as I didn't remember the FCKTools.IsStrictMode() check at the moment I coded the patch. But that can be easily corrected.

The selection removal issue is a much bigger obstacle though, because this is a browser bug. I couldn't really think of any simple workaround for that, except for porting the save/restore selection logic (i.e. FCKSelection.Save(), FCKSelection.Restore(), etc.) for IE to Firefox. That approach would has its own problems however - e.g. restoring control selections in Firefox would be difficult (if not impossible).

It seems there's no short term workaround for Firefox's selection clearing bug. Also I've noticed that Safari on Mac doesn't immediately restore the scrollbar after dialog close - it would only appear again if the user scrolled with his mouse wheel.

I'm proposing another patch which would add the clear scrollbar feature to IE and Opera only. For the other browsers, I'll file a bug report to them and wait for them to be fixed first. Also, FCKTools.IsStrictMode() is used instead of checking document.compatMode.

After some discussions with Martin on IRC today, we found out that this problem can be fixed by using "position:fixed" in the dialog, instead of "position:absolute". It works well for Firefox, Safari, Opera and IE7.

Only IE6- would still present the current behavior, and we have decided to not include further code in the dialog system just to handle that browser. After all, this issue is a small annoyance, but don't make it impossible to use the editor.