Firefox OS Simulator 4.0 released

It’s a good day for Firefox OS developers as we are releasing version 4.0 of the Firefox OS Simulator to the masses. In particular, this release is a boon for those developers that want to make money using their app in the Marketplace.

What’s New in 4.0

4.0 Updated Simulator Dashboard
An overview shot of the revised Dashboard

New Connect Button

There is a new ‘Connect’ button for each app that opens a developer toolbox connected to that specific app. This means that you won’t have to search through messages in the Console or filter through scripts in the Debugger in order to find information specific to your app.

Testing Receipts for Paid Apps

There is now a dropdown menu in each app’s dashboard where you can select a receipt type. The simulator add-on will then download a test receipt from a Marketplace receipt service and reinstall the app using it. This way you can test receipt verification with the various types of receipts that you may require – valid, invalid, and refunded.

4.0 Updated Simulator Dashboard Buttons
The new Connect button, Refresh Button, and Receipts drop-down

Remote CSS Styling

If you connect to an app while using a Nightly or Aurora build of Firefox, there is a Style Editor tool you can use to edit the style sheets for your app. Changes are applied instantaneously.

4.0 Updated Simulator Live Style Editing
Live editing the Firefox OS Boilerplate app to have a less than charming red background

Simulated Touch Events

Gaia’s touch events simulation has been integrated such that interacting with the Simulator using a mouse now generates real touch events. This fixes a myriad of issues in core Gaia apps that assume touch interactions. It also means you can test third party apps that rely on touch events without needing to fall back to mouse events.

Hidden Feature: Shift-Ctrl/Cmd-R

When using the keyboard shortcut Ctrl-R (Cmd-R on Mac) to refresh an app, if you also hold down the Shift key, then the Simulator will clear persistent data such as AppCache, localStorage, sessionStorage, and IndexedDB while refreshing the app.

Check Out The Simulator Walkthrough

Still want to get into grittier details? Check out the simulator walkthrough to get a deep dive into the details of the Simulator, and the MDN documentation here.

Download and Install the Simulator

You can install or update the Simulator from the add-ons website.

Bugs? Feedback?

Leave general feedback in the comments below, we’re listening! If you encounter a bug we would be grateful if you could file it here.

About Angelina Fabbro

I'm a developer from Vancouver, BC Canada working at Mozilla as a Technical Evangelist and developer advocate for Firefox OS. I love JavaScript, web components, Node.js, mobile app development, and this cool place I hang out a lot called the world wide web. Oh, and let's not forget Firefox OS. In my spare time I take singing lessons, play Magic: The Gathering, teach people to program, and collaborate with scientists for better programmer-scientist engagement.

More articles by Angelina Fabbro…


8 comments

  1. Patrick H. Lauke

    On the subject of touch event simulation, am I right in thinking, though, that mouse events are still sent as normal, in a way that would not happen on a device?

    As an example, using the simulator, I can go to http://patrickhlauke.github.io/touch/tracker/mouse-tracker.html and just move my mouse around without clicking, and it reacts to the mouse movement … something that on a real device wouldn’t happen.

    Also, checking http://patrickhlauke.github.io/touch/tests/event-listener_show-delay.html there is no delay between touchend and click, but I assume on a real device there will be the classic 300ms unless the page is suppressing zooming ability (e.g. with user-scalable=no)?

    If this is the case, a feature request for the simulator from my part would be to more accurately simulate touch: actually suppressing/ignoring the mouse events and only simulating touch events (so for instance, just moving the mouse pointer over the simulator without any buttons clicked should result in no events being fired at all, as it would be equivalent to no finger touching the screen on a real device).

    July 11th, 2013 at 15:30

    1. Nick Desaulniers

      Patrick, sounds like you have some excellent test cases and knowledge of touch events on the web. Would you mind filing an issue for each discrepancy you run into in our issue tracker so we could keep track of progress on them? It would really help us, and all future developers on the platform! Thanks!

      July 11th, 2013 at 15:53

  2. Steve

    I installed this on Mac and have connected a KEON device via USB… should a push button show up automatically? or has that feature been dropped or require extra config?

    July 11th, 2013 at 18:17

    1. Robert Nyman [Editor]

      Remote debugging has to be enabled on the device, via
      Settings > Device information > More Information > Developer > Remote debugging.

      July 12th, 2013 at 00:24

      1. Steve

        Thanks Robert… but in my case that has already been set. Anything else special needed?

        July 12th, 2013 at 03:20

  3. Steve

    Ah wait ignore that last reply… after a full device power down and restart the push button showed up! – I’m all good now. ;-)

    July 12th, 2013 at 03:22

    1. Robert Nyman [Editor]

      Glad it worked out! Shouldn’t necessarily a restart, but hey, as long as it works. :-)

      July 12th, 2013 at 05:41

  4. Ravensun

    Hello
    Please change resize of toolbars in web browser. If I want browse with “landscape” and want to login on my favorite page, I see nothing, because when virtual keyboard is during logining enable all window of webpage is toooooooooo small, because in web browser toolbars and adress bar are tooooooo large. Change it, please.
    BTW: sorry my mother language is Czech so my english is not so good. I am sorry.

    July 12th, 2013 at 05:00

Comments are closed for this article.