Fix bug that classes "mobile portrait" was apply to desktop

Classes "mobile portrait" no more applying. Function device.landskape
now throws exception if window.orientation is undefined