gn:act_toLayoutClick
- Description
- Action used to change displayed root layout to desired target.
- Each time this action is executed, it adds the new layout to the layout stack.
- Action returns
- boolean
Action signatures
Change displayed layout as action
[gn:act_toLayoutClick]|[layout,skipStack]
Parameter Description layout
target which will be displayed on the screen Can be
- hardcoded id of target root layout
GnDropDown
which has "local" data source from@array/someArray
with@array/someArray_value
,
someArray_value
should contain id’s of root layouts for screens without@+id/prefix
- (this can be used on i.e.
gn:act_setItemSelect
of dropdown when value is changed to go to a different screen or in other scenarios)
- (this can be used on i.e.
skipStack
(optional)if "skipStack" is set the current screen will not be added to the stack of screens. The stack represents a collection of screens we passed through. This means that if we leave the screen with the "skipStack" option and then we press back we will skip the previous screen and return to the first screen which IS on the stack.
Example
@+id/screen1
- layout
- ⤷
[gn:act_toLayoutClick]|[@+id/screen1]
- ⤷
[gn:act_toLayoutClick]|[@+id/screen1,skipStack]
- ⤷
Change displayed layout as widget parameter
gn:act_toLayoutClick="target"
Parameter Description layout
target which will be displayed on the screen Can be
- hardcoded id of target root layout
GnDropDown
which has "local" datasource from@array/someArray
with@array/someArray_value
,
someArray_value
should contain id’s of root layouts for screens without@+id/prefix
- (this can be used on i.e.
gn:act_setItemSelect
of dropdown when value is changed to go to different screen or in other scenarios)
- (this can be used on i.e.
Example
<Button android:id="@+id/btnMenuNewObject" android:layout_width="fill_parent" android:layout_height="wrap_content" android:text="@string/btnMenuNewObject" gn:act_toLayoutClick="@+id/add_new_object" />