Windows and Web integration through Thinfinity® jsRO (Javascript Remote Objects) – Introduction

Framework integration to web with JsRo

Thinfinity VirtualUI is a web-enabling SDK that allows developers to take Windows-based applications to the web. For more details about running Win apps on a browser, just click here.
When just running the original app within a browser is not enough, you need integration capabilities.

Unlock the power of VirtualUI with jsRO

Thinfinity VirtualUI’s biggest strengths is, without a doubt, its Thinfinity jsRO framework. Once the app was published, the urge of going beyond simple cosmetic changes usually appears, and one may wish to combine the application with native web resources, such as personalized web searches, multimedia resources, specialized information and data, and the like.
Some other times data just needs to be visually arranged in a different pattern from how it is presented to the user by the original application. Or the interface needs to be replaced or enhanced to better accommodate the device on which it is being accessed, for adequate functionality and integration.
Javascript Remote Objects (jsRO) is a framework designed to facilitate these and many other possible scenarios, by allowing bidirectional communication between a web page or application and a Windows application. But, most importantly, to make that blending with the greatest possible transparency.
The key point is that jsRO enables the creation of objects in a Windows application that can be replicated on the browser as native Javascript objects. Every pair of objects keep in sync with each other on both ends of the communication and behaves as the same entity. This synchronization ensures bi-directional interaction and therefore immediately replicating changes in the jsRO objects’ properties, both on the browser and the Windows application.
Web integration: jsRO 00 Comunication Model
This communication is made possible by two components: a dll library (Thinfinity VirtualUI SDK) that has to be added to the Windows application, and a Javascript library (Thinfinity jsRo) that must be added to the web page. By adding a few more lines of code to the Windows application, jsRO objects are ready to be created and published on a browser.
jsRO 00 Model Creation And Exposition
The diagram above shows the sequence of how a jsRO object is first created in the Windows application, then propagated, and finally presented on the browser, ready to be used in Javascript. From this point forward, any changes made on any of the objects created will be reflected accordingly on its counterpart.

jsRO objects architecture

The jsRO model is based on the creation of an object in the Windows application and its replication as a Javascript object in the browser. Both objects are connected and synchronized, thus enabling a dialogue between the Windows application and the website via Javascript.
A jsRO object can have properties, methods, and events: the properties allow for data synchronization through both application and browser sides; the methods make possible the remote calling of application code; and the events help us to fire, from the Windows application, messages to the browser that could to be caught from javascript callbacks.

Object Properties

The jsRO object properties are synchronized on both the application and the browser sides. When a property value changes on one end it is spread to the other, firing an event handler that lets you take an action if necessary.

Remote methods

When a remote method is called on the browser side, it method handler callback is called on the application. Additionally, the returned result value can be processed by a javascript callback.

Remote events

Remote events allow developers to submit non-visual changes from the application to the javascript side. When the application fires an event, it is transmitted to the browser, enabling the javascript to receive and process it.
jsRO 00 Events

Hopefully, this is enough to get you started. In the next posts, we will learn how to create a jsRO object in our program to expose application’s data in the browser.
Full Javascript Remote Objects (jsRO) Guide

Leave a comment

Privacy Preferences
This website uses cookies to improve your experience while you navigate through the website. Out of these, the cookies that are categorized as necessary are stored on your browser as they are essential for the working of basic functionalities of the website. We also use third-party cookies that help us analyze and understand how you use this website. These cookies will be stored in your browser only with your consent. You also have the option to opt-out of these cookies. But opting out of some of these cookies may affect your browsing experience.