Enable mobile version for small windows as well

Closes #475
This commit is contained in:
Igor Zhukov 2014-09-25 13:39:33 +04:00
parent 926469c945
commit 68b33f2268

View File

@ -99,7 +99,9 @@
switch (layout) { switch (layout) {
case 'mobile': Config.Mobile = true; break; case 'mobile': Config.Mobile = true; break;
case 'desktop': Config.Mobile = false; break; case 'desktop': Config.Mobile = false; break;
default: Config.Mobile = Config.Navigator.mobile; break; default:
Config.Mobile = Config.Navigator.mobile || $(window).width() < 480;
break;
} }
$('head').append( $('head').append(
'<link rel="stylesheet" href="css/' + (Config.Mobile ? 'mobile.css' : 'desktop.css') + '" />' '<link rel="stylesheet" href="css/' + (Config.Mobile ? 'mobile.css' : 'desktop.css') + '" />'