Keon and Peak: Two Firefox OS smartphones tested
Browser Reloaded
A single program runs on the hardware described here, and that is the browser. The phone apps the user perceives as applications are technically sites that you open by clicking on a link. However, these are not static HTML pages but web applications. Thanks to many new Internet standards, the differences between native desktop programs are even more blurred now than was the case with the first generation of Ajax applications (Figure 8). Because it also works offline, the client-side JavaScript run-time environment is particularly in demand, but you can also use server-side programming.
The technologies attributed to HTML5 provide graphical and multimedia features that were impossible to implement without plugins in HTML4: Free-form drawing in real time (Canvas), animations (CSS3, SVG), sound without plugins ("audio" tag), and even OpenGL-based 3D graphics (WebGL). Modern browsers also store data sets locally (local storage, Files API) that far exceed the size of a cookie.
With IndexedDB, they can even provide a simple NoSQL database. Cache manifests instruct the browser to keep resources from the Internet even after terminating the online connection. Additionally, WebSockets and server-sent events finally implement true, two-way communication between client and server. Web workers launch background threads that do not block the GUI.
Regardless of whether these new APIs are mature enough to use on public websites, they are definitely available for apps in Firefox OS.
Table 2 lists the Mozilla documentation for the aforementioned technologies.
Table 2
New Web Technologies in Firefox
Hardware
Web applications that you expect to behave like normal Android or iOS apps need regular access to the hardware of the mobile device. The W3C Geolocation API [7] that lets a browser access the current GPS coordinates is a start, but obviously not enough: The phone apps need access to the cellular network status, display lighting, and battery status.
Hardware access is mainly controlled by Mozilla's Firefox OS focused Web API (Figure 9) [8]. A manifest [9] requests the permissions that the user can grant or deny a particular domain (application) [10].
Some rights are always reserved for locally installed apps (packaged apps), and some even only for privileged apps from the Mozilla App Store. They receive this status after a review by the store operator. Firefox assigns packaged apps to a pseudo-random domain locally during installation; this domain handles the rights management of the browser as for normal web pages.
Look and Feel
Certified apps (i.e., Firefox OS system applications) reside at the top level. They are the only apps given critical authorizations, such as the ability to dial a phone number. Again, these are web applications whose rights the browser manages in line with the guidelines of the Web API [8].
Despite the use of advanced HTML5 techniques, they do not feel like apps (Figure 10) while the programs run in a browser window. The Open Web Apps standard [11] lets you hide all of the browser elements. At the same time, a start icon appears in the Start menu of the Gaia GUI.
In Firefox OS, the starter icons end up on a home screen that looks no different from that of other mobile systems (Figure 11). The aforementioned app manifest governs the building of elements like the starter icon. Each web page can link apps with Firefox OS via a JavaScript interface [12].
Buy this article as PDF
(incl. VAT)
Buy Linux Magazine
Subscribe to our Linux Newsletters
Find Linux and Open Source Jobs
Subscribe to our ADMIN Newsletters
Support Our Work
Linux Magazine content is made possible with support from readers like you. Please consider contributing when you’ve found an article to be beneficial.
News
-
Armbian 24.11 Released with Expanded Hardware Support
If you've been waiting for Armbian to support OrangePi 5 Max and Radxa ROCK 5B+, the wait is over.
-
SUSE Renames Several Products for Better Name Recognition
SUSE has been a very powerful player in the European market, but it knows it must branch out to gain serious traction. Will a name change do the trick?
-
ESET Discovers New Linux Malware
WolfsBane is an all-in-one malware that has hit the Linux operating system and includes a dropper, a launcher, and a backdoor.
-
New Linux Kernel Patch Allows Forcing a CPU Mitigation
Even when CPU mitigations can consume precious CPU cycles, it might not be a bad idea to allow users to enable them, even if your machine isn't vulnerable.
-
Red Hat Enterprise Linux 9.5 Released
Notify your friends, loved ones, and colleagues that the latest version of RHEL is available with plenty of enhancements.
-
Linux Sees Massive Performance Increase from a Single Line of Code
With one line of code, Intel was able to increase the performance of the Linux kernel by 4,000 percent.
-
Fedora KDE Approved as an Official Spin
If you prefer the Plasma desktop environment and the Fedora distribution, you're in luck because there's now an official spin that is listed on the same level as the Fedora Workstation edition.
-
New Steam Client Ups the Ante for Linux
The latest release from Steam has some pretty cool tricks up its sleeve.
-
Gnome OS Transitioning Toward a General-Purpose Distro
If you're looking for the perfectly vanilla take on the Gnome desktop, Gnome OS might be for you.
-
Fedora 41 Released with New Features
If you're a Fedora fan or just looking for a Linux distribution to help you migrate from Windows, Fedora 41 might be just the ticket.