Enhancement
Major
Detail
Major
Detail
Detail
#26854
Tab delete of a legacy tabbar is not recorded
Deleting tabs of a tabbar within a "legacy" tab is not recorded in the application by the tl:ScriptingRecorder.
If a new tab is created in the application, then three nested layouts are created:
- tab.template.xml: To configure the name of the tab, for example.
- contentLayout.template.xml: To configure the layout, e.g. the alignment of the tab content.
- The actual content of the tab
The tab.template.xml contains a tl:LayoutReference to a contentLayout.template.xml, which in turn has a LayoutReference to the content of the tab.
A "legacy" tab is not divided into three separate layouts. There, everything for the tab is in a single layout.
When a view is deleted, the parents of the deleted view are replaced and reloaded.
Technical Demo > Tests is a legacy tab. The content of the tab is a tabbar. If the user deletes a Technical Demo > Tests > Foo tab of this tabbar, the parents of the deleted tab are replaced. Since there is only one layout in the legacy Technical Demo > Tests tab, the legacy tab is the tab that needs to be replaced. As a result, the Technical Demo tabbar gets the Technical Demo > Tests child replaced. It will replace the child that is selected at the time. This will update the selection. This is recorded by ScriptRecorder and prevents the actual delete action from being recorded.
In Technical Demo > Components this is not the case. Components is not a legacy tab. If a tab is deleted within Components` the `contentLayout.template.xml is replaced as parent of the deleted tab Technical Demo > Components > Foo and reloaded. In particular, the children (e.g. tab.template.xml layout of the component tab) of the tabbar Technical Demo do not change.
Implementation
Pause recording while deleting views.
Tests
Run Script Recorder and record the following actions:
- Tab Foo in Technical Demo > Create Tests.
- Tab Technical Demo > Tests > Delete Foo
Play the recording and check if the deletion of the view was recorded by the script recorder.