Search code examples
firefox-osgeckogaia

Configure differents resolution in mobile device


I am running Firefox OS on my Samsung S2. I want to test my app with 240x320 resolution and 120dpi. Is there any way to configure the resolution to 240x320 on my S2 phone?

While compiling Gecko or loading it or Gaia, I can tell the resolution, and apps will take that much area and the other part of screen is empty. I read somewhere that we can give "b2g -screen 320x480@160 -profile" in the desktop version of Firefox OS and run apps in lower resolutions. I want to do that on the S2 phone. Is there any way to do this?

Thanks for help.


Solution

  • Dirty hack, but yeah:

    • Make sure you can debug certified apps
    • Open the App Manager and debug the System app
    • Go to the styles tab and add the following to wrapper.css

    CSS:

    .appWindow {
        width: 240px !important;
        height: 320px !important;
    }
    

    And all new apps will also open in just 240x320 space.