Opened 16 years ago
Closed 16 years ago
#2512 closed Bug (worksforme)
IE8 beta2, contents of dialogs don't fill the width of the container
Reported by: | Alfonso Martínez de Lizarrondo | Owned by: | Alfonso Martínez de Lizarrondo |
---|---|---|---|
Priority: | Normal | Milestone: | |
Component: | UI : Dialogs | Version: | FCKeditor 2.6 Beta |
Keywords: | Confirmed IE8 HasPatch | Cc: |
Description
Sometimes works, and sometimes fails. And sometimes suddenly changes from one situation to the other while the dialog is open.
Check screenshot.
Attachments (3)
Change History (16)
Changed 16 years ago by
Attachment: | ie8 dialog.png added |
---|
comment:1 Changed 16 years ago by
It's really easy to trigger the bug, just hover the close button (top right) of the dialog and the content shrinks.
comment:2 Changed 16 years ago by
Keywords: | Confirmed added |
---|---|
Version: | FCKeditor 2.6.3 → FCKeditor 2.6 Beta |
comment:4 Changed 16 years ago by
Resolution: | fixed |
---|---|
Status: | closed → reopened |
I don't know what happened the other day, but the problem still exists.
comment:5 Changed 16 years ago by
as a possible temporary workaround I tried <meta http-equiv="X-UA-Compatible" content="IE=EmulateIE7" /> or <meta http-equiv="X-UA-Compatible" content="IE=7" /> but they don't seem to affect the dialog; or am I misunderstanding their purpose (clicking the compatibility view button does show the dialogs correctly)
comment:6 Changed 16 years ago by
Two reasons seem to cause this:
- changing the background image of the closeButton when hovering it, the CSS rule #closeButton:hover
- and visualizing the ok button, the SetOkButton command. (I tried to use display:none and display: block, but this didn't work either.)
The first case can perhaps be solved by having a 16x16 px ison solely for the close button instead of a clipped strip. Didn't test this though as I have choosen for the easy evident solution, removing the hover style.
The ok button cause can be overcome by setting the dialog's size again after the ok button is visualized:
if (oEditor.FCKBrowserInfo.IsIE) { dialog.SetAutoSize(true); }
Or if this result in undesired size, you can set it manually:
if (oEditor.FCKBrowserInfo.IsIE) { dialog.Sizer.ResizeDialog(widthPxValue, heightPxValue); }
comment:7 Changed 16 years ago by
hmmm seemingly you have to use SetAutoSize anyhow, also when you want to resize manually. Else the problem will remain. So do:
if (oEditor.FCKBrowserInfo.IsIE) { dialog.SetAutoSize(true); dialog.Sizer.ResizeDialog(widthPxValue, heightPxValue); }
comment:8 Changed 16 years ago by
that appeared to not work properly when reopening the dialog.
By canceling out piece by piece of the dialog's CSS if found out that when the .contents CSS rule was removed, the problem disappeared. And when I put a width in there then too the problem was gone. Then I tried to set the width automatically in function InnerDialogLoaded:
if (FCKBrowserInfo.IsIE) $('contents').style.width = $('contents').offsetWidth + 'px';
But this resulted in a transparent empty dialog on some computers. I assumed that that was because the offsetWidth was not yet known so I built in a check on that:
if (FCKBrowserInfo.IsIE) { setContentsWidth = function(){ if ($('contents').offsetWidth > 0) $('contents').style.width = $('contents').offsetWidth + 'px'; else setTimeout(setContentsWidth, 50); }; setContentsWidth(); }
But still the dialog sometimes showed transparent. So although this did work on some computers, others showed a transparent dialog.
Setting the value to a fixed size did work, but that's only useful per plugin of course:
dialog.$('contents').style.width = '500px';
comment:9 Changed 16 years ago by
I've created a simplified testcase and filed https://connect.microsoft.com/IE/feedback/ViewFeedback.aspx?FeedbackID=419515 as this is an IE8 bug.
comment:10 Changed 16 years ago by
Owner: | set to Alfonso Martínez de Lizarrondo |
---|---|
Status: | reopened → new |
If the bug isn't fixed in the final IE8 release, this patch takes care of it using the X-UA-Compatible header, but I'm not asking for review.
comment:11 Changed 16 years ago by
Keywords: | HasPatch added |
---|
comment:12 Changed 16 years ago by
Good news: Microsoft has stated that the internal builds have fixed this bug, so this patch won't be needed.
I'll leave it open until the new build is released to make this easier to find and avoid dups.
comment:13 Changed 16 years ago by
Resolution: | → worksforme |
---|---|
Status: | new → closed |
The final release of IE8 works OK.
screenshot