GBC 1.00.50

GBC 1.00.50 was released on December 14th 2018.

This page provides information about new features, as well as changes you need to take care of when migrating your customization to this version.

Universal Rendering

Customization built on top of GBC 1.00.50 may be used to render applications in Genero 3.20 native clients (GDC, GMA, GMI) thanks to the Universal Rendering.

Window close icon

THe Window close icon is now only visible if a close action is present on the window. When a modal window is displayed, there will not be close icon on the top blue chrome bar to avoid duplicates.

Widget creation best practices

To create a widget, you have to use widget factory like this:

var button = cls.WidgetFactory.createWidget("Button", opts);

opts is a object which contains some parameters for the widget constructor. One of these option is recommended: opts.appHash which contains the current application id. This option is used by the GBC core to detect memory leaks.

You can also get all the build parameters of a widget by using WidgetBase.getBuildParameters()

The most simple way to build a widget from another widget is to use this syntax:

var button = cls.WidgetFactory.createWidget("Button", this.getBuildParameters());

Widget mouse management

GBC now handles all mouse click events and dispatches them to widget. Simply override WidgetBase.manageMouseClick(domEvent) and this function should be automatically called when a click is done on the widget.

manageMouseClick: function(domEvent) {
  // Add code to execute when mouse click is handled
  // domEvent parameter is the DOM js event
  return true; // if return true, event is bubbled to parent DOM widget
}