Developing new applications
From eyeOS Wiki
Developing Applications for eyeOS 1.0 is simple thanks to the eyeOS Toolkit, which is included in the system through the eyeWidgets library.
Contents |
Introduction to eyeOS Applications
eyeOS Applications common files
A fully functional eyeOS application needs only two files: app.eyecode to contain the visual part of the application (widgets), and events.eyecode to contain the functions that will be called (if they exist) when main widgets are clicked, hovered or interacted with in another way.
It is worth noting that an app without an events file (events.eyecode) may exist, but it is always recommended to use both the events.eyecode and app.eyecode files, because even with no events, events.eyecode can be useful to perform actions when the application is closing.
The eyeOS Toolkit
The eyeOS toolkit consists in a group of Widgets, which are PHP+AJAX classes prepared to receive instructions and communicate with the application. Making an application is as simple as choosing your widgets, grouping them through the addFriend method and adding events to them (e.g. what should the application do when a button is clicked).
The system will automatically call the events when they are fired, add the app to the Processes table so it can run in multiple instances (e.g. two or more opened documents in a text editor), and protect the app against external attacks.
Introduction to the widgets
A widget, as previously stated, is a Class that can be called from any part of the application. The upshot of this is the ability to create an instance of any widget in a new application allowing the design of graphical eyeOS applications quickly and easily. Some widget properties are shared between all the widgets but others are specific to each widget.
Creating the eyepackage
Once you have your app, you can create an eyePackage, so you will be able to distribute it in an installable way. You can find instructions for creating an eyepackage here and instructions for installing eyepackages here.
References
To check the full reference about Widgets, Services and Libraries please check the Developers Reference Index.
Examples
Hello World app
As a first example, you can see the Hello World app, a basic app which displays a label and has a textbox/button to edit the label's text trought the addFriend interface.

