changed orientation query to device specific query