News:

Bored?  Looking to kill some time?  Want to chat with other SMF users?  Join us in IRC chat or Discord

Main Menu

IE8 and the jumping scrollbar

Started by Mr. Jinx, June 30, 2010, 02:03:01 PM

Previous topic - Next topic

Antechinus

Quote from: Mr. Jinx on July 31, 2010, 11:00:50 AM
This should solve the jumping scrollbar while typing / editting a message?
I tried it, but didn't see any improvement.

No, that is the fix for the layout issue with BBC lists when using compatibility mode. Compat mode is the fix for the jumpy scrollbar. :)


Quote from: Masterd on July 31, 2010, 11:34:08 AM
Quote from: Antechinus on June 30, 2010, 07:06:24 PM
Doesn't work any more. They changed IE8 and that code apparently screws things up now. I used to use it on my site and found that it wasn't working after a while.

Yes, but there is special mode for emulating IE7 in IE8. 

I know. That's compatibility mode, as already mentioned.

Mr. Jinx

#21
I finally found a good work-around. Someone posted it at the bugtracker, so it was there all the time:

In GenericControls.template.php
Find:
<textarea class="editor" name="', $editor_id, '" id="', $editor_id, '" rows="', $editor_context['rows'], '" cols="', $editor_context['columns'], '" onselect="storeCaret(this);" onclick="storeCaret(this);" onkeyup="storeCaret(this);" onchange="storeCaret(this);" tabindex="', $context['tabindex']++, '" style="', $context['browser']['is_ie8'] ? 'max-width: ' . $editor_context['width'] . '; min-width: ' . $editor_context['width'] : 'width: ' . $editor_context['width'], '; height: ', $editor_context['height'], ';', isset($context['post_error']['no_message']) || isset($context['post_error']['long_message']) ? 'border: 1px solid red;' : '', '">', $editor_context['value'], '</textarea>

Replace with:
<textarea class="editor" name="', $editor_id, '" id="', $editor_id, '" rows="', $editor_context['rows'], '" cols="', $editor_context['columns'], '" onselect="storeCaret(this);" onclick="storeCaret(this);" onkeyup="storeCaret(this);" onchange="storeCaret(this);" tabindex="', $context['tabindex']++, '" style="', ($context['browser']['is_ie8'] ? 'width: 700px; max-width: ' . $editor_context['width'] . '; min-width:' . $editor_context['width'] : 'width: ' . $editor_context['width']) , '; height: ', $editor_context['height'], ';', isset($context['post_error']['no_message']) || isset($context['post_error']['long_message']) ? 'border: 1px solid red;' : '', '">', $editor_context['value'], '</textarea>

Works for me, no more jumping scrollbar in IE8 finally!!
Tested with SMF 2.0 RC3 and the default core theme.

searchgr


Antechinus

Quote from: Mr. Jinx on August 01, 2010, 09:56:55 AMWorks for me, no more jumping scrollbar in IE8 finally!!

Were you using the wysiwyg editor or the standard bbc editor?

Mr. Jinx

I tried it with the standard bbc editor. I don't know how this works with the wysiwyg editor, but if there are problems with that it should also be possible to fix.

Basicly what you have to do is set a fixed width for the textbox. IE8 have problems when you use a percentage.

ps: This fix worked for me on SMF 2.0 RC3 with the default core theme.

Jscripts

See my thread (linked below) for the beginning of a proper fix for this

http://www.simplemachines.org/community/index.php?topic=397316.0

(mods, merge the threads if you reckon that is better)

JimM

Marked as solved.  Members can follow the above link for the additional information.
Jim "JimM" Moore
Former Support Specialist

Advertisement: