Sorry for the late reply! Although, it’s a bit difficult to test it right away, I guess this is caused by Respond.js which most probably applies the desktop styles in IE8 after the domready event. So, I would suggest to just exclude IE7/8 like this:
if (!window.respond) {
var $mainMenu = $('#main-menu'),
smObj = $mainMenu.data('smartmenus');
if (smObj.isCollapsible()) {
$mainMenu.smartmenus('itemActivate', $mainMenu.find('a.current').eq(-1));
}
}
This means that the menu will not be expanded just for IE7/8 mobile users (if there are any of those at all nowadays).