Jump to content

Recommended Posts

  • Administrators
Posted

Download:
The distributive is available by request only.

Release date:

10 April 2022


Warning 🚨

Properties TfgCollectionView.SelectionColor, SelectionColorNameΒ and SelectionModeΒ were moved to new SelectionOptions property. At the same time, the old runtime access to them is still preserved.

New ✨

TfgGoogleSignInAuthenticationClient

The new component TfgGoogleSignInAuthenticationClientΒ was added. It allows to identify user via "Google Sign in"Β service. The component is also cross-platform. However the component is implemented only for AndroidΒ platform at this moment.

TfgCollectionView - manual selection displaying

The manual selection displaying was added in TfgCollectionView. The new property TfgCollectionView.SelectionOptions.DisplayingMode allows to specify way for displaying selection:

  • Auto - regular mode by default. The component takes care about displaying selection via changing item's background color.
  • Manual - manual mode. The component doesn't display selection. It notifies user about displaying/resetting item's selection via new event OnUpdateItemSelectionAppearance.

In case of manual displaying selection, you should select or reset selection appearance in the OnUpdateItemSelectionAppearanceΒ event. This event is called every time the list needs to update the state of an item. Among the arguments of the event, information about:

  • AItem - Item wrapper for working with nested controls.
  • IsSelected - Is selected item or not.
  • Initiator - Who is initiator refreshing selection appearance. If you want to add animations to the selection process of an element, then focus on this flag. This flag equlas "User" when the user changes the selection manually.

The new demo sample was added: "Components" -> "TfgCollectionView" -> "Manual displaying selection".

TfgControlEnumerators

Two enumerators are now available for traversing the component tree with the ability to manage the traversal. Both enumerators are available in the TfgControlEnumerators class.

  • TfgControlEnumerators.Enum - Root -> First..Last child
  • TfgControlEnumerators.ReverseEnum - Root -> Last..First child

For example, iterating over all `TfgEdit` might look like this:

TfgControlEnumerators.Enum(Form,
Β  procedure (const AChild: TfgControl; var AAction: TfgEnumControlsAction)
Β  begin
Β  Β  if AChild is TfgEdit then
Β  Β  Β  TfgLog.Debug(AChild.ToString);
Β  end);

In addition to the usual bypass, it is possible to do a controlled bypass. For example, searching for an input field:

TfgControlEnumerators.Enum(Form,
Β  procedure (const AChild: TfgControl; var AAction: TfgEnumControlsAction)
Β  begin
Β  Β  if AChild is TfgEdit then
Β  Β  begin
Β  Β  Β  TfgLog.Debug('Edit: ' + AChild.ToString);
Β  Β  Β  AAction := TfgEnumControlsAction.Stop;
Β  Β  end
Β  Β  else
Β  Β  Β  AAction := TfgEnumControlsAction.Continue;
Β  end);

The `AAction` parameter of an anonymous function allows specify the further direction of the component traversal action:

  • Continue - Go to next control;
  • Discard - Go to sibling component (don't go deep);
  • Stop - Stop.

Components icons

We have added new component icons for all components in "FGX: Standard" and "FGX: Layout" groups.

Improvements πŸ™Œ

TfgFormManager

  • The form manager TfgFormManagerΒ was redesigned. This class fully tracks the lifetime of all forms in FGX Native. Now all public methods do not take into account embedded form-frames, as before.
  • Added a new demo project showing an example of working with authentication clients (TfgAppleIdAuthenticationClient, TfgFacebookLoginAuthenticationClient😞 "Authentication" -> "Authentication clients".

Other

The key event processing logic was redesigned. Now the key event is dispatched across all forms/frames, starting from the one closest to the user. Previously, depending on the moment of creation and embedding of the form, the order of processing button events could be violated.

Bug Fixes πŸ›

  • Like 1
Γ—
Γ—
  • Create New...