Added custom code for high DPI devices