CallOptions are used to specify at runtime the transitions, behavior, and position in a call to a particular panel.
The Type gives control over how the call stack is affected when a call is made and also defines what happens to the execution of the event that makes the call to the panel.
By default the behavior is as follows:
The panel being called appears, stays in the call stack, and the caller waits for it to return in order to continue the execution of the event.
Using the "call type" you can call a panel as a Popup, call a panel contextually (Callout), or call it replacing the current panel in the stack.
To do this, you need to set the Type property of the CallOptions object, whose values are defined in the enumerated domain called CallType.
The syntax to change the default behavior at runtime is:
<object name>.CallOptions.Type = CallType.<call type name>
This is the default behavior, the called panel appears in the same space as the caller and the caller waits for its return to continue execution.
The called panel replaces the caller in the call stack -this will save memory space-. It means that when you call a panel using this call type, the call terminates the execution of the current event (since the panel that is executing the event is removed from the stack). A call of this type must be the last line of the caller event.
The size of the popup can be changed with the following parameters from the CallOptions (these parameters only apply when the Type is Popup or Callout):
<object name>.CallOptions.TargetSize = CallTargetSize.<Panel Size Type>
The values of PanelSizeType can be:
- Default (Platform Default)
Also, a custom size can be defined by setting the values for Target Height and Width as follows:
CallOptions.TargetHeight = "dips or percentage of the parent height"
CallOptions.TargetWidth = "dips or percentage of the parent width"
NOTE: Target property does not apply when CallType = Popup.
As of GeneXus 17, the Popup option when using iPhone with iOS 13 or above can have a Small or Medium Target Size (they behave in tha same way, with the popup not covering the whole screen, but allowing to see the application bar of the panel bellow).
In previous GeneXus versions or older iOS versions, the Popup is always shown with a Large Target Size, covering the entire screen.
When using this call type, the call can be canceled by touching on any item outside called panel interface. The call to the panel is not modal.
This call type is fully supported in iPad only.
The Callout Type is not implemented in Android, it behaves like the Popup option in that platform.
As of GeneXus 17, the Callout option when using iPhone is equivalent to a Popup with Small size in iOS 13 and above. In older GeneXus versions or older iOS versions, it is equivalent to a full-screen Popup.